Skip to content

Replace assert() calls with if/else/raise <Exception>() #28

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

Closed
hugodahl opened this issue May 1, 2021 · 6 comments
Closed

Replace assert() calls with if/else/raise <Exception>() #28

hugodahl opened this issue May 1, 2021 · 6 comments
Assignees
Labels
good first issue Good for newcomers

Comments

@hugodahl
Copy link
Contributor

hugodahl commented May 1, 2021

Per a conversation in the FXAS21002C library on issue #21, checking for conditions and raising an exception is preferable over calling assert(). This is preferable for a number of reasons, including memory usage.

@jposada202020 jposada202020 added the good first issue Good for newcomers label May 1, 2021
@syedmalimustafa
Copy link
Contributor

Can I take this?

@jposada202020
Copy link
Contributor

@alimustafashah Thanks for your interest, for sure thank you very much, that would be really appreciated. thanks :)

@syedmalimustafa
Copy link
Contributor

Can you assign the task to me?

@jposada202020
Copy link
Contributor

@alimustafashah if this is your first time contributing to CP
Teh following information could be helpful
code is reviewed by the CI so ths learning guide is very useful https://learn.adafruit.com/improve-your-code-with-pylint
If will facilitate things if you use pre-commit:
pre-commit run --all-files
And in case you change any documentation, in the docs directory built the documentation locally
sphinx-build -E -W -b html . _build/html

Thanks :)

@syedmalimustafa
Copy link
Contributor

Thanks for sharing!

jposada202020 added a commit that referenced this issue May 25, 2021
#28 Replaced assert() calls with if/else/raise <Exception>()
@jposada202020
Copy link
Contributor

Solved by #30

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

3 participants