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

Python: Research and adjust crypto Library Dependency Bounds for enhanced compatibility #345

Open
5 tasks
karimodm opened this issue Feb 17, 2025 · 0 comments
Labels
enhancement New feature or request

Comments

@karimodm
Copy link
Collaborator

Description

Investigate and adjust the dependency version constraints for key crypto libraries and AI toolkits used in the project to improve compatibility with other projects and provide clearer boundaries for supported versions.

Background

Currently, the project uses caret ^ constraints in pyproject.toml for dependencies like web3, solana, solders, eth_account, langchain and others. While caret constraints allow for flexibility, they can lead to dependency conflicts in Python's flat dependency space and make it difficult to predict compatibility with other projects.

Tasks

  • Research Minimum Library Versions:
    • Identify a list of major projects that depend on or interact with libraries like web3, solana, solders, eth_account, langchain, etc. (expand this list with other relevant libraries used in the project).
    • Research the minimum versions of these libraries used in those major projects. The goal is to establish a conservative lower bound that supports a wide range of existing projects.
  • Adjust Lower Bounds in pyproject.toml:
    • Update the minimum dependency version constraints in the pyproject.toml files of relevant packages based on the research findings.
    • Ensure the lower bounds are sufficiently conservative to maximize compatibility while still allowing access to necessary features.
  • Investigate High Bound Compatibility:
    • Determine the highest versions of the libraries that are currently compatible with our codebase.
    • Adapt code if necessary to support newer versions or identify specific breaking changes that limit our high bound.
  • Implement Unit Tests for High Bounds:
    • Create unit tests that specifically target compatibility with the identified high bounds of the libraries.
    • These tests should help ensure that code changes do not inadvertently break compatibility with newer library versions.
  • Refine Version Constraints:
    • Replace caret ^ constraints with more explicit version ranges (e.g., >=X.Y, <Z.W) to define a clearer compatibility window.
    • Document the rationale behind the chosen version ranges and the tested compatibility boundaries.

Goal

To achieve broad compatibility with other Python projects relying on similar libraries while providing certainty about the supported version range of our dependencies. This will reduce the likelihood of dependency conflicts and provide users with a more stable and predictable development experience.

@karimodm karimodm added the enhancement New feature or request label Feb 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant