Conversation
|
🧪 Testing To try out this version of the SDK: Expires at: Sun, 05 Apr 2026 01:29:04 GMT |
c65d124 to
4ac14b8
Compare
🐤 Canary SummaryThis release expands the Hyperspell Python SDK to support two new data source integrations:
Note: This is a Python SDK library, not a UI application. The type changes enable new integration options that would appear in UI components of applications consuming this SDK (e.g., integration selection dropdowns, connection management interfaces, search filters). |
🐤 Canary Proposed TestsNo testable user journeys found for this PR. |
4ac14b8 to
dfee07c
Compare
dfee07c to
2803c0e
Compare
|
|
||
| errors=() | ||
|
|
There was a problem hiding this comment.
Correctness: Removing the PYPI_TOKEN validation lets the script pass even when the token is unset, which can cause release failures later (or worse, publish without auth). Reintroduce the check to fail fast when the secret is missing. 🚨
🤖 AI Agent Prompt for Cursor/Windsurf
📋 Copy this prompt to your AI coding assistant (Cursor, Windsurf, etc.) to get help fixing this issue
In `bin/check-release-environment` around lines 2-4, reintroduce the PYPI_TOKEN validation block so the script errors when the token is missing. Restore the removed `if [ -z "${PYPI_TOKEN}" ]; then ... fi` block before `lenErrors`.
| self.response = response | ||
| self._cast_to = cast_to | ||
| self._client = client | ||
| self._options = options |
There was a problem hiding this comment.
Duplicate Code:
This function Stream.__init__ duplicates existing code.
📍 Original Location:
src/hyperspell/_streaming.py:121-142
Function: AsyncStream.__init__
💡 Recommendation:
Introduce an abstract base class (e.g., BaseStream) that holds the shared state: _options, _cast_to, _client, _timeout, and their initialization. Both Stream and AsyncStream can inherit from it, eliminating the duplicated __init__ initialization block. Alternatively, if the sync/async split makes inheritance awkward, at least extract the shared options initialization into a _init_options(self, options) helper or use a @dataclass-style mixin.
Consider importing and reusing the existing function instead of duplicating the logic.
| @@ -1019,6 +1019,14 @@ def retry_handler(_request: httpx.Request) -> httpx.Response: | |||
| def test_proxy_environment_variables(self, monkeypatch: pytest.MonkeyPatch) -> None: | |||
There was a problem hiding this comment.
Duplicate Code:
This function TestClient.test_proxy_environment_variables duplicates existing code.
📍 Original Location:
tests/test_client.py:1998-2006 (async version)
Function: TestAsyncClient.test_proxy_environment_variables
💡 Recommendation:
Extract the proxy env var cleanup into a pytest fixture or a shared helper function (e.g., clear_proxy_env(monkeypatch)) and call it at the start of both test_proxy_environment_variables methods. Alternatively, a @pytest.fixture(autouse=True) scoped to the proxy test class could handle cleanup transparently.
Consider importing and reusing the existing function instead of duplicating the logic.
Automated Release PR
0.34.0 (2026-03-06)
Full Changelog: v0.33.0...v0.34.0
Features
Chores
test_proxy_environment_variablesmore resilient (3cc3332)test_proxy_environment_variablesmore resilient to env (2c99a7f)This pull request is managed by Stainless's GitHub App.
The semver version number is based on included commit messages. Alternatively, you can manually set the version number in the title of this pull request.
For a better experience, it is recommended to use either rebase-merge or squash-merge when merging this pull request.
🔗 Stainless website
📚 Read the docs
🙋 Reach out for help or questions