Skip to content
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

fix(tags): resolve issue with study.additional_data.patch attribute reading #1944

Merged
merged 2 commits into from
Feb 23, 2024

Conversation

laurent-laporte-pro
Copy link
Contributor

Pull Request Description

This pull request resolves an issue encountered when reading the study.additional_data.patch attribute in cases where
the study lacks an additional_data instance.
The additional_data attribute is designed to be optional, but an error occurred when attempting to access it without
ensuring its presence.

Problem Origin

The anomaly originated during the implementation phase of managing tags within the database,
instead of retrieving the list of tags from a designated file "patch.json".

Solution

The code now appropriately checks for the existence of the additional_data instance before attempting to access its
attributes.

  • Now, the "patch.json" file is read if the additional_data attribute is missing.
  • If additional_data is present, the study.additional_data.patch attribute is read as expected.

Testing

Comprehensive testing has been performed to validate the effectiveness of the implemented solution.

Related pull requests

@laurent-laporte-pro laurent-laporte-pro added the bug Something isn't working label Feb 23, 2024
@laurent-laporte-pro laurent-laporte-pro added this to the v2.17 milestone Feb 23, 2024
@laurent-laporte-pro laurent-laporte-pro self-assigned this Feb 23, 2024
@laurent-laporte-pro laurent-laporte-pro merged commit 84462c7 into dev Feb 23, 2024
7 checks passed
@laurent-laporte-pro laurent-laporte-pro deleted the bugfix/1254-correct-patch-reading branch February 23, 2024 14:59
skamril pushed a commit that referenced this pull request Feb 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working size/L
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants