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

Should Artifact eq/hash be based on the Artifact spec? #9

Open
ravwojdyla opened this issue Jul 13, 2021 · 0 comments
Open

Should Artifact eq/hash be based on the Artifact spec? #9

ravwojdyla opened this issue Jul 13, 2021 · 0 comments
Labels
documentation Improvements or additions to documentation enhancement New feature or request question Further information is requested

Comments

@ravwojdyla
Copy link
Contributor

ravwojdyla commented Jul 13, 2021

pydantic models are not hashable by design. So far we have lived without the need to hash Artifacts. Equality is implemented by pydantic and is field based. This prevents the use of Artifact object in some use-cases: set, dict etc. Note that if we implement hash it should be consistent with the eq, which can be problematic. Something to think about.

Artifact spec: (id, version, parition)

@ravwojdyla ravwojdyla added documentation Improvements or additions to documentation enhancement New feature or request question Further information is requested labels Jul 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant