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

Removed error catching on invalid attributes #1432

Merged
merged 1 commit into from
Mar 21, 2023

Conversation

stollr
Copy link
Contributor

@stollr stollr commented Mar 21, 2023

The error catching in the AttributeAnnotationFactory made it hard to find the reason for "ignored" attributes. This change addresses the issues #1267 and #1162.

Instead of catching errors of non existing attribute classes, the existence of the class is checked before the attribute is tried to instantiate. This reveals invalid attribute definitions, but still errors for unknown attributes won't be shown.

The error catching made it hard to find the reason for "ignored" attributes. This change addresses the issues zircote#1267 and zircote#1162.

Instead of catching errors of non existing attribute classes, the existence of the class is checked before the attribute is tried to instantiate. This reveals invalid attribute definitions, but there won't be shown errors for attributes whose class definitions do not exist.
Copy link
Collaborator

@DerManoMann DerManoMann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably more in line with line #57 where newInstance() also isn't wrapped in a try/catch

@DerManoMann DerManoMann merged commit a009c24 into zircote:master Mar 21, 2023
@DerManoMann
Copy link
Collaborator

Thanks @Naitsirch

@stollr
Copy link
Contributor Author

stollr commented Mar 22, 2023

You're welcome. Thanks for reviewing and merging 👍

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