olivmath / merkly

🌳 The simple and easy implementation of Merkle Tree
https://pypi.org/project/merkly
MIT License
43 stars 10 forks source link

Fix: Compatibility with Pedantic 2.x #67

Open olivmath opened 4 days ago

olivmath commented 4 days ago

Describe the bug

When trying to add the merkly package to the project using Poetry, a dependency conflict occurs between merkly and eth-ape.

To Reproduce (Example)

I try it:

$ merkly-use-case poetry add merkly
Using version ^1.0.2 for merkly

Updating dependencies
Resolving dependencies... (0.2s)

Because no versions of merkly match >1.0.2,<2.0.0
 and merkly (1.0.2) depends on pydantic (>=1.10.2,<2.0.0), merkly (>=1.0.2,<2.0.0) requires pydantic (>=1.10.2,<2.0.0).
And because eth-ape (0.8.15) depends on pydantic (>=2.6.4,<3)
 and no versions of eth-ape match >0.8.15,<0.9.0, merkly (>=1.0.2,<2.0.0) is incompatible with eth-ape (>=0.8.15,<0.9.0).
So, because merkly-use-case depends on both eth-ape (^0.8.15) and merkly (^1.0.2), version solving failed.

To successfully add merkly to the project without conflicts.

Explanation

The error occurs due to conflicting dependencies:

  1. merkly (1.0.2) requires pydantic version >=1.10.2 and <2.0.0
  2. eth-ape (0.8.15) requires pydantic version >=2.6.4 and <3

These requirements are incompatible because:

Poetry's dependency resolver cannot find a combination of package versions that satisfies both these requirements simultaneously.

Screenshots

Environment (please complete the following information):