Skip to content

Validate the ZoneId of the DateTime with ZoneId #959

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jul 7, 2022

Conversation

bigmontz
Copy link
Contributor

@bigmontz bigmontz commented Jul 1, 2022

The validation of the DateTime was only being done in the new patched protocol while unpacking the struct. This changes force any new DateTime with ZoneID to have a valid ZoneId.

This changes also treats struct unpacking errors and defers the occurred to the moment the object is manipulate. For instance, a DateTime with invalid ZoneId returned in a Record will not break the records consumption until any code try to interacts with the broken DateTime.

bigmontz added 3 commits July 1, 2022 16:41
The validation of the DateTime was only being done in the new patched driver while unpacking the struct. This changes force any new DateTime with ZoneID to have a valid ZoneId.

This changes also treats struct unpacking errors and deffers the occurred to the moment the object is manipulate. For instance, a DateTime with invalid ZoneId returned in a Record
will not break the records consumption until any code try to interacts with the broken DateTime.
@bigmontz bigmontz merged commit ac6c406 into neo4j:4.4 Jul 7, 2022
@bigmontz bigmontz deleted the 4.4-treat-struct-construction-errors branch July 7, 2022 14:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants