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

Rename enum exception #1317

Merged
merged 2 commits into from
Nov 15, 2021
Merged

Rename enum exception #1317

merged 2 commits into from
Nov 15, 2021

Conversation

patrick91
Copy link
Member

Update enum's exception to be consistent with ObjectIsNotClassError

@botberry
Copy link
Member

botberry commented Oct 7, 2021

Thanks for adding the RELEASE.md file!

Here's a preview of the changelog:


This release renames an internal exception from NotAnEnum to ObjectIsNotAnEnumError.


Here's the preview release card for twitter:

Here's the tweet text:

🆕 Release (next) is out! Thanks to Patrick Arminio for the PR 👏

Get it here 👉 https://github.com/strawberry-graphql/strawberry/releases/tag/(next)

@codecov
Copy link

codecov bot commented Oct 7, 2021

Codecov Report

Merging #1317 (2583d39) into main (541c81e) will increase coverage by 0.06%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main    #1317      +/-   ##
==========================================
+ Coverage   98.07%   98.13%   +0.06%     
==========================================
  Files         105      113       +8     
  Lines        3786     3963     +177     
  Branches      532      569      +37     
==========================================
+ Hits         3713     3889     +176     
+ Misses         41       40       -1     
- Partials       32       34       +2     

@@ -4,7 +4,7 @@

from strawberry.type import StrawberryType

from .exceptions import NotAnEnum
from .exceptions import ObjectIsNotAnEnum
Copy link
Member

Choose a reason for hiding this comment

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

If you want to be consistent so maybe you should put the Error suffix at the end like ObjectIsNotClassError or if you are not happy with it remove it from both?

Copy link
Member Author

Choose a reason for hiding this comment

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

updated :)

Copy link
Member

@BryceBeagle BryceBeagle left a comment

Choose a reason for hiding this comment

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

Still needs RELEASE.md

@patrick91
Copy link
Member Author

patrick91 commented Oct 23, 2021

@BryceBeagle I marked this as a patch as the exception is thrown before schema creation, so this is not really a breaking change I'd say

;;

@patrick91 patrick91 merged commit 661dfcc into main Nov 15, 2021
@patrick91 patrick91 deleted the rename/enum-expection branch November 15, 2021 18:46
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.

4 participants