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

w2n needs better error handling, idempotency #7

Closed
relwell opened this issue Aug 7, 2016 · 2 comments
Closed

w2n needs better error handling, idempotency #7

relwell opened this issue Aug 7, 2016 · 2 comments
Assignees

Comments

@relwell
Copy link

relwell commented Aug 7, 2016

Please refer to the following line:

https://github.com/akshaynagpal/w2n/blob/master/word2number/w2n.py#L74

There should be a keyword argument to determine whether or not to raise an error or return the same value that was passed to the function.

This function should also be able to accommodate passing a numeric value and returning it without transforming it.

Currently, it's in somewhat the worst of all possible states, since we would actually need to perform text matching to determine whether an error was encountered. If I wanted to perform text matching, I would implement this library myself.

@akshaynagpal
Copy link
Owner

@relwell Thanks for pointing it out, I will keep this in mind while drafting the next release. Also, you can contribute too, by making the changes you've pointed out, and submitting a PR. Cheers!

@relwell
Copy link
Author

relwell commented May 10, 2017

Cleaning out my open issues.

@relwell relwell closed this as completed May 10, 2017
@akshaynagpal akshaynagpal reopened this May 16, 2017
@akshaynagpal akshaynagpal self-assigned this May 16, 2017
akshaynagpal added a commit that referenced this issue May 17, 2017
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

No branches or pull requests

2 participants