You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
cocalc-api/test: fix edge cases in api and improve testing
This commit updates the conftest.py test fixtures to properly support both
account-scoped and project-scoped API keys during testing.
The validate_api_key_config fixture now:
- First attempts to detect scope via hub.system.test() (account-scoped keys)
- Falls back to project.system.test() if hub fails (project-scoped keys)
- Reports both errors if both endpoints fail, for better debugging
Also clarifies that the hub endpoint's system.test() is for account-scoped
keys only, with clear comments directing project-scoped key users to the
project endpoint.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
3.**Bridge**: `hubBridge()` routes to conat subject
@@ -172,7 +174,6 @@ CoCalc is organized as a monorepo with key packages:
172
174
- Prefix git commits with the package and general area. e.g. 'frontend/latex: ...' if it concerns latex editor changes in the packages/frontend/... code.
173
175
- When pushing a new branch to Github, track it upstream. e.g. `git push --set-upstream origin feature-foo` for branch "feature-foo".
174
176
175
-
176
177
## React-intl / Internationalization (i18n)
177
178
178
179
CoCalc uses react-intl for internationalization with SimpleLocalize as the translation platform.
@@ -234,7 +235,10 @@ Same flow as above, but **before 3. i18n:upload**, delete the key. Only new keys
234
235
235
236
## Overview
236
237
237
-
The `python/cocalc-api/` directory contains a Python client library for the CoCalc API, published as the `cocalc-api` package on PyPI.
238
+
The `python/cocalc-api/` directory contains a uv-based Python client library for the CoCalc API, published as the `cocalc-api` package on PyPI.
239
+
240
+
It also contains a test framework (`python/cocalc-api/tests/README.md`) and an MCP client (`python/cocalc-api/src/cocalc_api/mcp/README.md`).
241
+
For convenience, a `python/cocalc-api/Makefile` exists.
238
242
239
243
## Client-Server Architecture Investigation
240
244
@@ -248,54 +252,21 @@ The `python/cocalc-api/` directory contains a Python client library for the CoCa
0 commit comments