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

cusip._alphabet is too restrictive: prevents matching valid CUSIPs #337

Closed
thomkav opened this issue Oct 16, 2022 · 2 comments
Closed

cusip._alphabet is too restrictive: prevents matching valid CUSIPs #337

thomkav opened this issue Oct 16, 2022 · 2 comments

Comments

@thomkav
Copy link

thomkav commented Oct 16, 2022

The cusip module's is_valid function returns false for a CUSIP that I would expect would pass, as I found it on a real Fidelity statement (see screenshot of document sample).

cusip.is_valid(`FDIC99425`)
>> False

I believe this is because cusip._alphabet does not permit "I" or "O":

cusip._alphabet
>> '0123456789ABCDEFGH JKLMN PQRSTUVWXYZ*@#'

Screen Shot 2022-10-16 at 11 50 45 AM

I checked cusip.com and I didn't find anything indicating that those two characters were not allowed.

@arthurdejong
Copy link
Owner

Thanks for pointing this out. It's been fixed in 1364e19

@thomkav
Copy link
Author

thomkav commented Feb 3, 2023

A long awaited thanks @arthurdejong !

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