| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 1e202d0 commit d2c39ec
33 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1,31 @@ | |||
| 1 | + # This workflow is triggered when a GitHub release is created. | ||
| 2 | + # It can also be run manually to re-publish to PyPI in case it failed for some reason. | ||
| 3 | + # You can run this workflow by navigating to https://www.github.com/digitalocean/genai-python/actions/workflows/publish-pypi.yml | ||
| 4 | + name: Publish PyPI | ||
| 5 | + on: | ||
| 6 | + workflow_dispatch: | ||
| 7 | + | ||
| 8 | + release: | ||
| 9 | + types: [published] | ||
| 10 | + | ||
| 11 | + jobs: | ||
| 12 | + publish: | ||
| 13 | + name: publish | ||
| 14 | + runs-on: ubuntu-latest | ||
| 15 | + | ||
| 16 | + steps: | ||
| 17 | + - uses: actions/checkout@v4 | ||
| 18 | + | ||
| 19 | + - name: Install Rye | ||
| 20 | + run: | | ||
| 21 | + curl -sSf https://rye.astral.sh/get | bash | ||
| 22 | + echo "$HOME/.rye/shims" >> $GITHUB_PATH | ||
| 23 | + env: | ||
| 24 | + RYE_VERSION: '0.44.0' | ||
| 25 | + RYE_INSTALL_OPTION: '--yes' | ||
| 26 | + | ||
| 27 | + - name: Publish to PyPI | ||
| 28 | + run: | | ||
| 29 | + bash ./bin/publish-pypi | ||
| 30 | + env: | ||
| 31 | + PYPI_TOKEN: ${{ secrets.DIGITALOCEAN_GENAI_SDK_PYPI_TOKEN || secrets.PYPI_TOKEN }} | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1,21 @@ | |||
| 1 | + name: Release Doctor | ||
| 2 | + on: | ||
| 3 | + pull_request: | ||
| 4 | + branches: | ||
| 5 | + - main | ||
| 6 | + workflow_dispatch: | ||
| 7 | + | ||
| 8 | + jobs: | ||
| 9 | + release_doctor: | ||
| 10 | + name: release doctor | ||
| 11 | + runs-on: ubuntu-latest | ||
| 12 | + if: github.repository == 'digitalocean/genai-python' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || startsWith(github.head_ref, 'release-please') || github.head_ref == 'next') | ||
| 13 | + | ||
| 14 | + steps: | ||
| 15 | + - uses: actions/checkout@v4 | ||
| 16 | + | ||
| 17 | + - name: Check release environment | ||
| 18 | + run: | | ||
| 19 | + bash ./bin/check-release-environment | ||
| 20 | + env: | ||
| 21 | + PYPI_TOKEN: ${{ secrets.DIGITALOCEAN_GENAI_SDK_PYPI_TOKEN || secrets.PYPI_TOKEN }} | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1,3 @@ | |||
| 1 | + { | ||
| 2 | + ".": "0.0.1-alpha.0" | ||
| 3 | + } | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,4 +1,4 @@ | |||
| 1 | 1 | configured_endpoints: 60 | |
| 2 | 2 | openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/digitalocean%2Fdigitalocean-genai-sdk-17838dec38ee8475c4bf4695b8dc70fe42a8f4da8ae9ffd415dc895b6628a952.yml | |
| 3 | 3 | openapi_spec_hash: cfe5453e150989c8a9dbc9d7b4d1f76a | |
| 4 | - config_hash: 6a4a54166267ede5a1822b47ec8c540f | ||
| 4 | + config_hash: 70991672c5e8fe09c40fc600f422bc55 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -62,7 +62,7 @@ If you’d like to use the repository from source, you can either install from g | |||
| 62 | 62 | To install via git: | |
| 63 | 63 | ||
| 64 | 64 | ```sh | |
| 65 | - $ pip install git+ssh://git@github.com/stainless-sdks/digitalocean-genai-sdk-python.git | ||
| 65 | + $ pip install git+ssh://git@github.com/digitalocean/genai-python.git | ||
| 66 | 66 | ``` | |
| 67 | 67 | ||
| 68 | 68 | Alternatively, you can build from source and install the wheel file: | |
@@ -120,7 +120,7 @@ the changes aren't made through the automated pipeline, you may want to make rel | |||
| 120 | 120 | ||
| 121 | 121 | ### Publish with a GitHub workflow | |
| 122 | 122 | ||
| 123 | - You can release to package managers by using [the `Publish PyPI` GitHub action](https://www.github.com/stainless-sdks/digitalocean-genai-sdk-python/actions/workflows/publish-pypi.yml). This requires a setup organization or repository secret to be set up. | ||
| 123 | + You can release to package managers by using [the `Publish PyPI` GitHub action](https://www.github.com/digitalocean/genai-python/actions/workflows/publish-pypi.yml). This requires a setup organization or repository secret to be set up. | ||
| 124 | 124 | ||
| 125 | 125 | ### Publish manually | |
| 126 | 126 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -15,8 +15,8 @@ The REST API documentation can be found on [developers.digitalocean.com](https:/ | |||
| 15 | 15 | ## Installation | |
| 16 | 16 | ||
| 17 | 17 | ```sh | |
| 18 | - # install from this staging repo | ||
| 19 | - pip install git+ssh://git@github.com/stainless-sdks/digitalocean-genai-sdk-python.git | ||
| 18 | + # install from the production repo | ||
| 19 | + pip install git+ssh://git@github.com/digitalocean/genai-python.git | ||
| 20 | 20 | ``` | |
| 21 | 21 | ||
| 22 | 22 | > [!NOTE] | |
@@ -238,9 +238,9 @@ version = response.parse() # get the object that `agents.versions.list()` would | |||
| 238 | 238 | print(version.agent_versions) | |
| 239 | 239 | ``` | |
| 240 | 240 | ||
| 241 | - These methods return an [`APIResponse`](https://github.com/stainless-sdks/digitalocean-genai-sdk-python/tree/main/src/digitalocean_genai_sdk/_response.py) object. | ||
| 241 | + These methods return an [`APIResponse`](https://github.com/digitalocean/genai-python/tree/main/src/digitalocean_genai_sdk/_response.py) object. | ||
| 242 | 242 | ||
| 243 | - The async client returns an [`AsyncAPIResponse`](https://github.com/stainless-sdks/digitalocean-genai-sdk-python/tree/main/src/digitalocean_genai_sdk/_response.py) with the same structure, the only difference being `await`able methods for reading the response content. | ||
| 243 | + The async client returns an [`AsyncAPIResponse`](https://github.com/digitalocean/genai-python/tree/main/src/digitalocean_genai_sdk/_response.py) with the same structure, the only difference being `await`able methods for reading the response content. | ||
| 244 | 244 | ||
| 245 | 245 | #### `.with_streaming_response` | |
| 246 | 246 | ||
@@ -346,7 +346,7 @@ This package generally follows [SemVer](https://semver.org/spec/v2.0.0.html) con | |||
| 346 | 346 | ||
| 347 | 347 | We take backwards-compatibility seriously and work hard to ensure you can rely on a smooth upgrade experience. | |
| 348 | 348 | ||
| 349 | - We are keen for your feedback; please open an [issue](https://www.github.com/stainless-sdks/digitalocean-genai-sdk-python/issues) with questions, bugs, or suggestions. | ||
| 349 | + We are keen for your feedback; please open an [issue](https://www.github.com/digitalocean/genai-python/issues) with questions, bugs, or suggestions. | ||
| 350 | 350 | ||
| 351 | 351 | ### Determining the installed version | |
| 352 | 352 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1,21 @@ | |||
| 1 | + #!/usr/bin/env bash | ||
| 2 | + | ||
| 3 | + errors=() | ||
| 4 | + | ||
| 5 | + if [ -z "${PYPI_TOKEN}" ]; then | ||
| 6 | + errors+=("The DIGITALOCEAN_GENAI_SDK_PYPI_TOKEN secret has not been set. Please set it in either this repository's secrets or your organization secrets.") | ||
| 7 | + fi | ||
| 8 | + | ||
| 9 | + lenErrors=${#errors[@]} | ||
| 10 | + | ||
| 11 | + if [[ lenErrors -gt 0 ]]; then | ||
| 12 | + echo -e "Found the following errors in the release environment:\n" | ||
| 13 | + | ||
| 14 | + for error in "${errors[@]}"; do | ||
| 15 | + echo -e "- $error\n" | ||
| 16 | + done | ||
| 17 | + | ||
| 18 | + exit 1 | ||
| 19 | + fi | ||
| 20 | + | ||
| 21 | + echo "The environment is ready to push releases!" | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -34,8 +34,8 @@ classifiers = [ | |||
| 34 | 34 | ] | |
| 35 | 35 | ||
| 36 | 36 | [project.urls] | |
| 37 | - Homepage = "https://github.com/stainless-sdks/digitalocean-genai-sdk-python" | ||
| 38 | - Repository = "https://github.com/stainless-sdks/digitalocean-genai-sdk-python" | ||
| 37 | + Homepage = "https://github.com/digitalocean/genai-python" | ||
| 38 | + Repository = "https://github.com/digitalocean/genai-python" | ||
| 39 | 39 | ||
| 40 | 40 | ||
| 41 | 41 | [tool.rye] | |
@@ -121,7 +121,7 @@ path = "README.md" | |||
| 121 | 121 | [[tool.hatch.metadata.hooks.fancy-pypi-readme.substitutions]] | |
| 122 | 122 | # replace relative links with absolute links | |
| 123 | 123 | pattern = '\[(.+?)\]\(((?!https?://)\S+?)\)' | |
| 124 | - replacement = '[\1](https://github.com/stainless-sdks/digitalocean-genai-sdk-python/tree/main/\g<2>)' | ||
| 124 | + replacement = '[\1](https://github.com/digitalocean/genai-python/tree/main/\g<2>)' | ||
| 125 | 125 | ||
| 126 | 126 | [tool.pytest.ini_options] | |
| 127 | 127 | testpaths = ["tests"] | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1,66 @@ | |||
| 1 | + { | ||
| 2 | + "packages": { | ||
| 3 | + ".": {} | ||
| 4 | + }, | ||
| 5 | + "$schema": "https://raw.githubusercontent.com/stainless-api/release-please/main/schemas/config.json", | ||
| 6 | + "include-v-in-tag": true, | ||
| 7 | + "include-component-in-tag": false, | ||
| 8 | + "versioning": "prerelease", | ||
| 9 | + "prerelease": true, | ||
| 10 | + "bump-minor-pre-major": true, | ||
| 11 | + "bump-patch-for-minor-pre-major": false, | ||
| 12 | + "pull-request-header": "Automated Release PR", | ||
| 13 | + "pull-request-title-pattern": "release: ${version}", | ||
| 14 | + "changelog-sections": [ | ||
| 15 | + { | ||
| 16 | + "type": "feat", | ||
| 17 | + "section": "Features" | ||
| 18 | + }, | ||
| 19 | + { | ||
| 20 | + "type": "fix", | ||
| 21 | + "section": "Bug Fixes" | ||
| 22 | + }, | ||
| 23 | + { | ||
| 24 | + "type": "perf", | ||
| 25 | + "section": "Performance Improvements" | ||
| 26 | + }, | ||
| 27 | + { | ||
| 28 | + "type": "revert", | ||
| 29 | + "section": "Reverts" | ||
| 30 | + }, | ||
| 31 | + { | ||
| 32 | + "type": "chore", | ||
| 33 | + "section": "Chores" | ||
| 34 | + }, | ||
| 35 | + { | ||
| 36 | + "type": "docs", | ||
| 37 | + "section": "Documentation" | ||
| 38 | + }, | ||
| 39 | + { | ||
| 40 | + "type": "style", | ||
| 41 | + "section": "Styles" | ||
| 42 | + }, | ||
| 43 | + { | ||
| 44 | + "type": "refactor", | ||
| 45 | + "section": "Refactors" | ||
| 46 | + }, | ||
| 47 | + { | ||
| 48 | + "type": "test", | ||
| 49 | + "section": "Tests", | ||
| 50 | + "hidden": true | ||
| 51 | + }, | ||
| 52 | + { | ||
| 53 | + "type": "build", | ||
| 54 | + "section": "Build System" | ||
| 55 | + }, | ||
| 56 | + { | ||
| 57 | + "type": "ci", | ||
| 58 | + "section": "Continuous Integration", | ||
| 59 | + "hidden": true | ||
| 60 | + } | ||
| 61 | + ], | ||
| 62 | + "release-type": "python", | ||
| 63 | + "extra-files": [ | ||
| 64 | + "src/digitalocean_genai_sdk/_version.py" | ||
| 65 | + ] | ||
| 66 | + } | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,4 +1,4 @@ | |||
| 1 | 1 | # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. | |
| 2 | 2 | ||
| 3 | 3 | __title__ = "digitalocean_genai_sdk" | |
| 4 | - __version__ = "0.0.1-alpha.0" | ||
| 4 | + __version__ = "0.0.1-alpha.0" # x-release-please-version | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments