Contributing to MCP Server¶
We welcome contributions to the MCP Server project! By contributing, you agree to abide by our Code of Conduct.
Please take a moment to review this document to ensure a smooth and effective contribution process.
How to Contribute¶
Reporting Bugs¶
If you find a bug, please help us by reporting it. A good bug report makes it easier for us to track and fix the issue. Please include:
- A clear and concise title.
- A detailed description of the bug.
- Steps to reproduce the behavior.
- Expected versus actual behavior.
- Any relevant logs or error messages.
Suggesting Enhancements¶
We love new ideas! If you have a suggestion for an enhancement or a new feature, please open an issue and describe it in detail. Include:
- A clear and concise title.
- A detailed description of the proposed enhancement.
- Any mockups or examples that help illustrate your idea.
Pull Requests¶
- Fork the Repository: Start by forking the
mcp-server
repository to your GitHub account. - Clone Your Fork: Clone your forked repository to your local machine.
- Create a New Branch: Create a new branch for your feature or bug fix. Use a descriptive name.
- Set up Your Development Environment: Ensure you have Python 3.11+ and Docker installed.
- Set up Pre-Commit Hooks: This repository uses
pre-commit
to automatically run linters and formatters before each commit. -
Make Your Changes: Implement your feature or bug fix. Remember to:
- Adhere to existing code style and conventions.
- Write clear, concise, and well-documented code.
- Add or update tests for your changes.
- Ensure all existing tests pass.
-
Run Tests: Before committing, ensure all tests pass.
- Commit Your Changes: When you commit, the pre-commit hooks will automatically run and may fix formatting issues. If they fail, you'll need to stage the changes and commit again.
- Push to Your Fork:
- Create a Pull Request: Go to the original
mcp-server
repository on GitHub and create a new pull request from your forked branch.- Provide a clear title and description for your pull request.
- Reference any related issues.
Code Style and Conventions¶
- Python: Follow PEP 8 guidelines. We use
ruff
for linting andblack
for formatting. - Docstrings: Use Google-style docstrings for all functions, classes, and modules.
- Type Hinting: Use type hints for all function arguments and return values where appropriate.
Documentation Style¶
All documentation is written in Markdown and generated using MkDocs with the Material theme. Please ensure:
- Clear and descriptive headings.
- Use admonitions for important information (e.g.,
!!! note
,!!! warning
). - Specify the language for code blocks (e.g.,
python`,
bash`). - Add new pages to the
nav
section ofmkdocs.yml
if you create new documentation files.
Git Commit Messages¶
We follow the Conventional Commits specification for commit messages. This helps with automated changelog generation and understanding the nature of changes.
Examples: * feat: Add user authentication module
* fix: Correct off-by-one error in pagination
* docs: Update README with installation instructions
* chore: Update dependencies
Versioning¶
The project version is managed through Git tags. When creating a release, an annotated tag (e.g., v1.0.0
) should be used.
License¶
By contributing to this project, you agree that your contributions will be licensed under the Apache License 2.0. See the LICENSE file for more details.
Need Help?¶
If you have any questions or need assistance, feel free to open an issue or reach out to the maintainers.
Thank you for contributing!