Skip to content
This repository has been archived by the owner on Jan 13, 2023. It is now read-only.

Refactor copy-pasted securityLevel filters #176

Closed
todofixthis opened this issue Apr 18, 2018 · 1 comment
Closed

Refactor copy-pasted securityLevel filters #176

todofixthis opened this issue Apr 18, 2018 · 1 comment

Comments

@todofixthis
Copy link
Contributor

There's a lot of copy-pasted code for validating securityLevel in certain command filters:

'securityLevel': f.Type(int) | f.Min(1) | f.Max(3) | f.Optional(default=AddressGenerator.DEFAULT_SECURITY_LEVEL),

We could convert this into a filter macro in iota/filters.py to ensure consistency. As a bonus, we could also remove a bunch of duplicate unit tests.

@todofixthis
Copy link
Contributor Author

Scheduled for release: 2.0.6

marko-k0 pushed a commit to marko-k0/iota.lib.py that referenced this issue Jul 28, 2018
marko-k0 pushed a commit to marko-k0/iota.lib.py that referenced this issue Jul 28, 2018
…y-level-filter

[iotaledger#176] Added `SecurityLevel` filter macro.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant