Repository navigation
Error codes: give each engine subclass of a listed exception a code or a recorded reason (27.1.1) - #544
Open
tae898 wants to merge 1 commit into
Open
Error codes: give each engine subclass of a listed exception a code or a recorded reason (27.1.1)#544tae898 wants to merge 1 commit into
tae898 wants to merge 1 commit into
Conversation
…rd why it stays unknown The table compares Java class names exactly, so a subclass of a listed class came out as unknown. Rows now name the subclasses with a hint that fits, and a test reads the class files of the wheel's jars and fails on an engine subclass that has neither a row nor a recorded reason.
Collaborator
Author
|
Decided on 2026-11-30, as the current decision and open to change: this stays out of 26.12.1 and moves to 27.1.1, with #507. I set the milestone. It rests on what the change does: callers get a new |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
The table of error codes compares Java class names exactly, so a subclass of a listed engine exception came out as
unknown, with no hint. Each such subclass now has a row with a hint that fits, or a recorded reason to stayunknown. The jars of engine 26.12.1-SNAPSHOT hold more of them than the issue lists, including some belowIllegalArgumentException.Please do not merge yet. I still have to decide whether this goes into 26.12.1.
unknownunless a message rule caught it)CommandSemanticException,NonBooleanPatternExpressionException,FeatureNotImplementedExceptionsyntax_errorRecordVetoedExceptionvalidationDatabaseIsReopeningExceptiondatabase_closedRefusedBeforePublishingException,QuorumNotReachedException,ReplicationQueueFullException,ServerIsNotTheLeaderException,RetryLaterException,WALVersionGapExceptionconflictEquivalentIndexExceptionalready_exists, with its own hintConstraintDropFailedException,IndexDropFailedExceptionschemaType$InconvertibleValueException,ValueOutOfRangeException,InvalidPropertyTypeExceptiontype_mismatchDatabaseAlreadyExistsException(server)database_existsThe ones that stay
unknown, each with its reason, are inSTAYS_UNKNOWNintests/test_error_codes_subclasses.py.What changes for a caller: these errors get a
code, ahint, and a subclass ofArcadeDBError, sostr(e)now starts with[code] hint. Code that comparese.code == "unknown"for one of them sees the new code. Which errorsrun_in_transactionretries does not change.The new test reads the class files of the jars in the JVM wheel. It fails when a newer engine adds a subclass of a listed class that nobody has decided on, so a nightly or pull request run against a new snapshot can turn red for that reason alone. Anonymous classes are left out.
Related issues
Closes #507
Performance changes
None claimed. The table is only read when an error is built.
Docs
how-to/errors.adoc: the new rows, and a sentence on exact class names and on whichconflicta retry may not fix.Checklist
mainthe new test file gave 6 failed and 2 passed)uvx pre-commit run --files <changed files>passes