Thank you for your interest in contributing to the Shioaji MCP Server! This document provides guidelines and instructions for contributing to this project.
Please be respectful and considerate of others when contributing to this project. We aim to foster an inclusive and welcoming community.
- Fork the repository on GitHub
- Clone your fork to your local machine
- Set up the development environment as described in the README.md
# Clone your fork
git clone https://github.com/your-username/shioaji-mcp.git
cd shioaji-mcp
# Install development dependencies
uv sync --extra test --extra lint
# Set up environment variables
cp .env.example .env
# Edit .env and fill in your API credentials-
Create a new branch for your feature or bugfix:
git checkout -b feature/your-feature-name # or git checkout -b fix/issue-description -
Make your changes and ensure they follow the project's coding standards
-
Write or update tests for your changes
-
Run tests to ensure everything works:
uv run pytest
-
Check code quality:
uv run ruff check src/ tests/ uv run ruff format src/ tests/
-
Commit your changes with a clear and descriptive commit message:
git commit -m "Add feature: description of your feature" # or git commit -m "Fix: description of the bug you fixed"
-
Push to your fork:
git push origin feature/your-feature-name
-
Create a Pull Request from your fork to the main repository
When submitting a pull request, please:
- Reference any related issues in your PR description
- Describe your changes in detail
- Include screenshots or examples if applicable
- Update documentation if necessary
- Ensure all tests pass and code quality checks succeed
- Keep your PR focused on a single topic to make review easier
We use pytest for testing. Please ensure your code includes appropriate tests:
# Run all tests
uv run pytest
# Run tests with coverage
uv run pytest --cov=src/shioaji_mcpWe follow these coding standards:
- Use ruff for linting and formatting
- Follow PEP 8 style guidelines
- Use type hints where appropriate
- Write docstrings for functions and classes
- Keep line length to 88 characters or less
Please update documentation when making changes:
- Update docstrings for modified functions and classes
- Update the README.md if necessary
- Update or create examples if applicable
For Docker-related changes:
# Build the Docker image
docker build -t shioaji-mcp-dev .
# Test the Docker image
docker run --rm -i --platform=linux/amd64 \
-e SHIOAJI_API_KEY=test_key \
-e SHIOAJI_SECRET_KEY=test_secret \
shioaji-mcp-devFor maintainers, to create a new release:
- Update the version in
pyproject.toml - Create a new tag:
git tag vX.Y.Z git push origin vX.Y.Z
- The GitHub Actions workflow will automatically build and publish the Docker image to GHCR
If you need help with contributing, please:
- Check the documentation and examples
- Look for similar issues that might have been resolved
- Open a new issue with a clear description of your problem
Thank you for contributing to the Shioaji MCP Server!