Skip to content

box: fix setting box error name#11747

Merged
locker merged 1 commit intotarantool:masterfrom
nshy:gh-10708-fix-setting-error-name
Aug 25, 2025
Merged

box: fix setting box error name#11747
locker merged 1 commit intotarantool:masterfrom
nshy:gh-10708-fix-setting-error-name

Conversation

@nshy
Copy link
Contributor

@nshy nshy commented Aug 11, 2025

Currently we fail to set box error name is some cases. Error name is error payload with key name.

Closes #10708

@nshy nshy requested a review from a team as a code owner August 11, 2025 08:48
@nshy nshy force-pushed the gh-10708-fix-setting-error-name branch from f69b81c to 2eb721b Compare August 11, 2025 09:49
@coveralls
Copy link

coveralls commented Aug 11, 2025

Coverage Status

coverage: 87.582% (-0.02%) from 87.6%
when pulling ad929b9 on nshy:gh-10708-fix-setting-error-name
into 34a5717
on tarantool:master
.

@nshy nshy requested a review from locker August 11, 2025 10:07
@locker locker assigned nshy and unassigned locker Aug 11, 2025
@nshy nshy force-pushed the gh-10708-fix-setting-error-name branch 2 times, most recently from 80dc5fb to 44da324 Compare August 12, 2025 09:36
@nshy nshy assigned locker and unassigned nshy Aug 12, 2025
@locker locker assigned nshy and unassigned locker Aug 12, 2025
@nshy nshy force-pushed the gh-10708-fix-setting-error-name branch from 44da324 to 9ac03ed Compare August 13, 2025 11:42
@nshy nshy added the full-ci Enables all tests for a pull request label Aug 13, 2025
@nshy nshy force-pushed the gh-10708-fix-setting-error-name branch from 9ac03ed to bc4a93d Compare August 13, 2025 12:11
@nshy
Copy link
Contributor Author

nshy commented Aug 14, 2025

The PR depends on #11716 it terms of backporting.

@nshy nshy force-pushed the gh-10708-fix-setting-error-name branch from bc4a93d to 8b17cfe Compare August 20, 2025 07:22
@nshy
Copy link
Contributor Author

nshy commented Aug 20, 2025

Rebased on master.

Currently we fail to set box error name is some cases. Error name is
error payload with key `name`.

Let's cleanup error code a bit. As result the bug will be fixed.

1. Use `va_list` in error constructors so in order to remove error
   reinitialization in build functions.
2. Use ClientCode for building ER_UNSUPPORTED_INDEX_FEATURE. It is
   ClientError too.
3. Drop tnt_error() which has a single usage.
4. Drop logged error. It is just a ClientError that is logged when
   created.

Closes tarantool#10708

NO_DOC=bugfix
@nshy nshy force-pushed the gh-10708-fix-setting-error-name branch from 8b17cfe to ad929b9 Compare August 20, 2025 07:39
@nshy nshy assigned locker and unassigned nshy Aug 25, 2025
@locker locker merged commit a924d96 into tarantool:master Aug 25, 2025
42 of 43 checks passed
@locker
Copy link
Member

locker commented Aug 25, 2025

@nshy Please backport to 3.2, 3.3, and 3.4.

@nshy nshy deleted the gh-10708-fix-setting-error-name branch August 25, 2025 11:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

full-ci Enables all tests for a pull request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Error created with kv version of box.error has invalid name

4 participants