Closed payton closed 2 years ago
@sbihel, thanks for the comments! Everything actionable is addressed.
Haven't heard of poetry - neat!
Formatting: poetry run black
Tests: poetry run nosetests
I had some time so I did some things myself, hope you don't mind. Mainly, I completed the tests and fixed a couple of things.
You will need to run
git submodule update --init
poetry update
poetry run pytest
I suppose what's left to do is:
SignatureType
for now, we are only focused on EIP-191 for now;Haha! As the maintainer, you have full veto power - I support whatever decisions fit best for you.
I've gone ahead and updated the README with some initial examples.
Re: "we can remove the SignatureType
for now, we are only focused on EIP-191 for now;":
Perhaps it makes sense to just leave it in since the impact on flow is minimal? I'll mark that step as done but feel free to remove if you wish.
Re: add CI: This looks promising (will leave that to you): https://github.com/marketplace/actions/python-poetry-action
Remaining steps:
Oh nice. I see you got siwe
on pypi 👍
I see you got siwe on pypi
Yes, I thought we should probably reserve the name :ninja:
I am going to merge this PR and publish as v0.1. Contract wallets support is not that urgent. And I'll add the CI in another branch.
Thank you :slightly_smiling_face:
Summary
This sets up the project foundation along with including my own initial implementation based on https://github.com/spruceid/siwe
Core functionality of the SiweMessage class exists but general tests are needed along with EIP-1271 support.
Layout
siwe.py
: Main SiweMessage class. Most/all interactions will be with this module.parsed.py
: Contains two ParsedMessage classes: RegExp and ABNF.defs.py
: Regular expressions for RegExpParsedMessage in parsed.py.grammars/
: Directory containing ABNF grammars for RFC 3339, RFC 5234, and EIP 4361Next Steps
I've included several TODO tags and will create issues for pending tasks in case members of the community wish to contribute.
Misc