|
1 | | -# Contributing to `agentclientprotocol/python-sdk` |
| 1 | +# Contributing |
2 | 2 |
|
3 | | -Contributions are welcome, and they are greatly appreciated! |
4 | | -Every little bit helps, and credit will always be given. |
| 3 | +Thanks for helping improve the Agent Client Protocol Python SDK! This guide mirrors the concise tone of the README/index so you can skim it quickly and get back to building. |
5 | 4 |
|
6 | | -You can contribute in many ways: |
| 5 | +## Ways to help |
7 | 6 |
|
8 | | -# Types of Contributions |
| 7 | +- **Report bugs** — file an issue with repro steps, OS + Python versions, and any environment toggles. |
| 8 | +- **Improve docs/examples** — clarify workflows, add integration notes, or document a new transport. |
| 9 | +- **Fix issues** — search for `bug` / `help wanted` labels or tackle anything that affects your integration. |
| 10 | +- **Propose features** — describe the use case, API shape, and constraints so we can scope the work together. |
9 | 11 |
|
10 | | -## Report Bugs |
| 12 | +## Filing great issues |
11 | 13 |
|
12 | | -Report bugs at https://github.com/agentclientprotocol/python-sdk/issues |
| 14 | +When reporting a bug or requesting a feature, include: |
13 | 15 |
|
14 | | -If you are reporting a bug, please include: |
| 16 | +- The ACP schema / SDK version you’re using. |
| 17 | +- How to reproduce the behaviour (commands, inputs, expected vs. actual). |
| 18 | +- Logs or payload snippets when available (scrub secrets). |
15 | 19 |
|
16 | | -- Your operating system name and version. |
17 | | -- Any details about your local setup that might be helpful in troubleshooting. |
18 | | -- Detailed steps to reproduce the bug. |
| 20 | +## Local workflow |
19 | 21 |
|
20 | | -## Fix Bugs |
| 22 | +1. **Fork & clone ** your GitHub fork: `git clone [email protected]:<you>/python-sdk.git`. |
| 23 | +2. **Bootstrap tooling** inside the repo root: `make install`. This provisions `uv`, syncs deps, and installs pre-commit hooks. |
| 24 | +3. **Create a topic branch:** `git checkout -b feat-my-improvement`. |
| 25 | +4. **Develop + document:** |
| 26 | + - Keep code typed (Python 3.10+), prefer generated models/helpers over dicts. |
| 27 | + - Update docs/examples when user-facing behaviour shifts. |
| 28 | +5. **Run the test gauntlet:** |
| 29 | + ```bash |
| 30 | + make check # formatting, lint, type analysis, deps |
| 31 | + make test # pytest + doctests |
| 32 | + ``` |
| 33 | + Optional: `ACP_ENABLE_GEMINI_TESTS=1 make test` when you have the Gemini CLI available. |
| 34 | +6. **(Optional) Cross-Python smoke:** `tox` if you want the same matrix CI runs. |
| 35 | +7. **Commit + push:** `git commit -m "feat: add better tool call helper"` followed by `git push origin <branch>`. |
21 | 36 |
|
22 | | -Look through the GitHub issues for bugs. |
23 | | -Anything tagged with "bug" and "help wanted" is open to whoever wants to implement a fix for it. |
| 37 | +## Pull request checklist |
24 | 38 |
|
25 | | -## Implement Features |
| 39 | +- [ ] PR title follows Conventional Commits. |
| 40 | +- [ ] Tests cover the new behaviour (or the reason they’re not needed is documented). |
| 41 | +- [ ] `make check` / `make test` output is attached or referenced. |
| 42 | +- [ ] Docs and examples reflect user-visible changes. |
| 43 | +- [ ] Any schema regeneration (`make gen-all`) is called out explicitly. |
26 | 44 |
|
27 | | -Look through the GitHub issues for features. |
28 | | -Anything tagged with "enhancement" and "help wanted" is open to whoever wants to implement it. |
| 45 | +## Need help? |
29 | 46 |
|
30 | | -## Write Documentation |
31 | | - |
32 | | -This project could always use more documentation, whether as part of the official docs, in docstrings, or even on the web in blog posts, articles, and such. |
33 | | - |
34 | | -## Submit Feedback |
35 | | - |
36 | | -The best way to send feedback is to file an issue at https://github.com/agentclientprotocol/python-sdk/issues. |
37 | | - |
38 | | -If you are proposing a new feature: |
39 | | - |
40 | | -- Explain in detail how it would work. |
41 | | -- Keep the scope as narrow as possible, to make it easier to implement. |
42 | | -- Remember that this is a volunteer-driven project, and that contributions |
43 | | - are welcome :) |
44 | | - |
45 | | -# Get Started! |
46 | | - |
47 | | -Ready to contribute? Here's how to set up the project for local development. |
48 | | -Please note this documentation assumes you already have `uv` and `Git` installed and ready to go. |
49 | | - |
50 | | -1. Fork the `agentclientprotocol/python-sdk` repo on GitHub. |
51 | | - |
52 | | -2. Clone your fork locally: |
53 | | - |
54 | | -```bash |
55 | | -cd <directory_in_which_repo_should_be_created> |
56 | | -git clone [email protected]:YOUR_NAME/python-sdk.git |
57 | | -``` |
58 | | - |
59 | | -3. Now we need to install the environment. Navigate into the directory |
60 | | - |
61 | | -```bash |
62 | | -cd python-sdk |
63 | | -``` |
64 | | - |
65 | | -Then, install and activate the environment with: |
66 | | - |
67 | | -```bash |
68 | | -uv sync |
69 | | -``` |
70 | | - |
71 | | -4. Install pre-commit to run linters/formatters at commit time: |
72 | | - |
73 | | -```bash |
74 | | -uv run pre-commit install |
75 | | -``` |
76 | | - |
77 | | -5. Create a branch for local development: |
78 | | - |
79 | | -```bash |
80 | | -git checkout -b name-of-your-bugfix-or-feature |
81 | | -``` |
82 | | - |
83 | | -Now you can make your changes locally. |
84 | | - |
85 | | -6. Don't forget to add test cases for your added functionality to the `tests` directory. |
86 | | - |
87 | | -7. When you're done making changes, check that your changes pass the formatting tests. |
88 | | - |
89 | | -```bash |
90 | | -make check |
91 | | -``` |
92 | | - |
93 | | -Now, validate that all unit tests are passing: |
94 | | - |
95 | | -```bash |
96 | | -make test |
97 | | -``` |
98 | | - |
99 | | -9. Before raising a pull request you should also run tox. |
100 | | - This will run the tests across different versions of Python: |
101 | | - |
102 | | -```bash |
103 | | -tox |
104 | | -``` |
105 | | - |
106 | | -This requires you to have multiple versions of python installed. |
107 | | -This step is also triggered in the CI/CD pipeline, so you could also choose to skip this step locally. |
108 | | - |
109 | | -10. Commit your changes and push your branch to GitHub: |
110 | | - |
111 | | -```bash |
112 | | -git add . |
113 | | -git commit -m "Your detailed description of your changes." |
114 | | -git push origin name-of-your-bugfix-or-feature |
115 | | -``` |
116 | | - |
117 | | -11. Submit a pull request through the GitHub website. |
118 | | - |
119 | | -# Pull Request Guidelines |
120 | | - |
121 | | -Before you submit a pull request, check that it meets these guidelines: |
122 | | - |
123 | | -1. The pull request should include tests. |
124 | | - |
125 | | -2. If the pull request adds functionality, the docs should be updated. |
126 | | - Put your new functionality into a function with a docstring, and add the feature to the list in `README.md`. |
| 47 | +Open a discussion or ping us in the ACP Zulip if you’re stuck on design decisions, transport quirks, or schema questions. We’d rather collaborate early than rework later. |
0 commit comments