Skip to content

Latest commit

 

History

History
160 lines (103 loc) · 5.57 KB

File metadata and controls

160 lines (103 loc) · 5.57 KB

Contributing Guidelines

Thank you for your interest in contributing to our project. Whether it's a bug report, new feature, correction, or additional documentation, we greatly value feedback and contributions from our community.

Please read through this document before submitting any issues or pull requests to ensure we have all the necessary information to effectively respond to your bug report or contribution.

Reporting Bugs/Feature Requests

We welcome you to use the Bug Reports file to report bugs or Feature Requests to suggest features.

For a list of known bugs and feature requests:

When filing an issue, please check for already tracked items

Please try to include as much information as you can. Details like these are incredibly useful:

  • A reproducible test case or series of steps
  • The version of our code being used (commit ID)
  • Any modifications you've made relevant to the bug
  • Anything unusual about your environment or deployment

Development Environment

This project uses uv_build as the build backend and uv for development workflow management.

Setting Up Your Development Environment

  1. Install uv:

    pip install uv
  2. Create a virtual environment and install development dependencies:

    uv venv
    source .venv/bin/activate  # On Windows: .venv\Scripts\activate
    uv pip install -e ".[dev]" --prerelease=allow
  3. Set up pre-commit hooks:

    pre-commit install -t pre-commit -t commit-msg

    This will automatically run formatters and convention commit checks on your code before each commit.

  4. Run code formatters manually:

    python scripts/format.py
  5. Run linters:

    python scripts/lint.py
  6. Run unit tests:

    python scripts/test.py
  7. Run integration tests:

    python scripts/test_integ.py
  8. Build the package:

    uv build

Pre-commit Hooks

We use pre-commit to automatically run quality checks before each commit. The hook will run formatting, linting, and tests when you make a commit, ensuring code consistency.

The pre-commit hook is installed with:

pre-commit install

You can also run the hooks manually on all files:

pre-commit run --all-files

Code Formatting and Style Guidelines

We use the following tools to ensure code quality:

  1. ruff - For formatting and linting
  2. mypy - For static type checking

These tools are configured in the pyproject.toml file. Please ensure your code passes all linting and type checks before submitting a pull request:

# Run all checks
python scripts/format.py
python scripts/lint.py

If you're using an IDE like VS Code or PyCharm, consider configuring it to use these tools automatically.

For additional details on styling, please see our dedicated Style Guide.

Contributing via Pull Requests

Contributions via pull requests are much appreciated. Before sending us a pull request, please ensure that:

  1. You are working against the latest source on the main branch.
  2. You check existing open, and recently merged, pull requests to make sure someone else hasn't addressed the problem already.
  3. You open an issue to discuss any significant work - we would hate for your time to be wasted.

To send us a pull request, please:

  1. Create a branch.
  2. Modify the source; please focus on the specific change you are contributing. If you also reformat all the code, it will be hard for us to focus on your change.
  3. Format your code using python scripts/format.py.
  4. Run linting checks with python scripts/lint.py.
  5. Ensure local tests pass with python scripts/test.py and python scripts/test_integ.py.
  6. Commit to your branch using clear commit messages following the Conventional Commits specification.
  7. Send us a pull request, answering any default questions in the pull request interface.
  8. Pay attention to any automated CI failures reported in the pull request, and stay involved in the conversation.

Finding contributions to work on

Looking at the existing issues is a great way to find something to contribute to.

You can check:

  • Our known bugs list in Bug Reports for issues that need fixing
  • Feature requests in Feature Requests for new functionality to implement

Code of Conduct

This project has adopted the Amazon Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opensource-codeofconduct@amazon.com with any additional questions or comments.

Security issue notifications

If you discover a potential security issue in this project we ask that you notify AWS/Amazon Security via our vulnerability reporting page. Please do not create a public github issue.

Licensing

See the LICENSE file for our project's licensing. We will ask you to confirm the licensing of your contribution.