python-sdk-dev
The Python SDK's development module.
Installation
dagger install github.com/zongruxie4/dagger/sdk/python/dev@23ba14eb605a5cef9cbe5a9bca1730f4af7f4ce0Entrypoint
Return Type
PythonSdkDev !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| source | Directory | - | Directory with sources |
| container | Container | null | Base container |
Example
Function PythonSdkDev.Constructor is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.Constructor is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.Constructor is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.Constructor is not accessible from the python-sdk-dev moduleTypes
PythonSdkDevDocs 🔗
Manage the reference documentation (Sphinx).
build() 🔗
Build the documentation.
Return Type
Directory ! Example
Function PythonSdkDevDocs.build is not accessible from the python-sdk-dev moduleFunction PythonSdkDevDocs.build is not accessible from the python-sdk-dev moduleFunction PythonSdkDevDocs.build is not accessible from the python-sdk-dev moduleFunction PythonSdkDevDocs.build is not accessible from the python-sdk-dev modulepreview() 🔗
Build and preview the documentation in the browser.
Return Type
Service !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| bind | Integer ! | 8000 | The port to bind the web preview for the built docs |
Example
Function PythonSdkDevDocs.preview is not accessible from the python-sdk-dev moduleFunction PythonSdkDevDocs.preview is not accessible from the python-sdk-dev moduleFunction PythonSdkDevDocs.preview is not accessible from the python-sdk-dev moduleFunction PythonSdkDevDocs.preview is not accessible from the python-sdk-dev modulePythonSdkDevTestSuite 🔗
Run the test suite.
default() 🔗
Run python tests.
Return Type
Container ! Example
Function PythonSdkDevTestSuite.default is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.default is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.default is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.default is not accessible from the python-sdk-dev moduleprovision() 🔗
Test provisioning.
This publishes a cli binary in an ephemeral http server and checks if the SDK can download, extract and run it.
Return Type
Container !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| cliBin | File ! | - | Dagger binary to use for test |
| runnerHost | String | null | _EXPERIMENTAL_DAGGER_RUNNER_HOST value |
Example
Function PythonSdkDevTestSuite.provision is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.provision is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.provision is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.provision is not accessible from the python-sdk-dev modulerun() 🔗
Run the pytest command.
Return Type
Container !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| args | [String ! ] ! | - | Arguments to pass to pytest |
Example
Function PythonSdkDevTestSuite.run is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.run is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.run is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.run is not accessible from the python-sdk-dev moduleunit() 🔗
Run unit tests.
Return Type
Container ! Example
Function PythonSdkDevTestSuite.unit is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.unit is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.unit is not accessible from the python-sdk-dev moduleFunction PythonSdkDevTestSuite.unit is not accessible from the python-sdk-dev modulePythonSdkDev 🔗
The Python SDK’s development module.
container() 🔗
Container to run commands in
Return Type
Container ! Example
Function PythonSdkDev.container is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.container is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.container is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.container is not accessible from the python-sdk-dev modulebuild() 🔗
Build the Python SDK client library package for distribution.
Return Type
Container !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| version | String ! | "0.0.0" | The version for the distribution package |
Example
Function PythonSdkDev.build is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.build is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.build is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.build is not accessible from the python-sdk-dev moduledocs() 🔗
Preview the reference documentation.
Return Type
PythonSdkDevDocs ! Example
Function PythonSdkDev.docs is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.docs is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.docs is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.docs is not accessible from the python-sdk-dev moduleformat() 🔗
Format source files.
Return Type
Directory !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| paths | [String ! ] ! | [] | List of files or directories to check |
Example
Function PythonSdkDev.format is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.format is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.format is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.format is not accessible from the python-sdk-dev modulegenerate() 🔗
Generate the client bindings for the core API.
Return Type
Changeset !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| introspectionJson | File ! | - | Result of the introspection query |
Example
Function PythonSdkDev.generate is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.generate is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.generate is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.generate is not accessible from the python-sdk-dev modulelint() 🔗
Check for linting errors.
Return Type
String !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| paths | [String ! ] | null | List of files or directories to check |
Example
Function PythonSdkDev.lint is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.lint is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.lint is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.lint is not accessible from the python-sdk-dev modulepublish() 🔗
Publish Python SDK client library to PyPI.
Return Type
Container !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| token | Secret ! | - | The token for the upload |
| version | String ! | "0.0.0" | The version for the distribution package to publish |
| url | String ! | "" | The URL of the upload endpoint (empty means PyPI) |
Example
Function PythonSdkDev.publish is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.publish is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.publish is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.publish is not accessible from the python-sdk-dev modulesupportedVersions() 🔗
Supported Python versions.
Return Type
[String ! ] ! Example
Function PythonSdkDev.supportedVersions is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.supportedVersions is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.supportedVersions is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.supportedVersions is not accessible from the python-sdk-dev moduletest() 🔗
Run the test suite.
Return Type
PythonSdkDevTestSuite !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| version | String | null | Python version to test against |
| disableNestedExec | Boolean ! | false | Disable nested execution for the test runs |
Example
Function PythonSdkDev.test is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.test is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.test is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.test is not accessible from the python-sdk-dev moduletestPublish() 🔗
Test the publishing of the Python SDK client library to TestPyPI.
Return Type
Container !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| token | Secret ! | - | TestPyPI token |
| version | String ! | "0.0.0" | The version for the distribution package to publish |
Example
Function PythonSdkDev.testPublish is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.testPublish is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.testPublish is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.testPublish is not accessible from the python-sdk-dev moduletestVersions() 🔗
Run the test suite for all supported versions.
Return Type
[PythonSdkDevTestSuite ! ] ! Example
Function PythonSdkDev.testVersions is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.testVersions is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.testVersions is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.testVersions is not accessible from the python-sdk-dev moduletypecheck() 🔗
Run the type checker (mypy).
Return Type
String ! Example
Function PythonSdkDev.typecheck is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.typecheck is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.typecheck is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.typecheck is not accessible from the python-sdk-dev modulewithContainer() 🔗
Replace container.
Return Type
PythonSdkDev !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| ctr | Container ! | - | An OCI-compatible container, also known as a Docker container. |
Example
Function PythonSdkDev.withContainer is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.withContainer is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.withContainer is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.withContainer is not accessible from the python-sdk-dev modulewithDirectory() 🔗
Mount a directory on the base container.
Return Type
PythonSdkDev !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| source | Directory ! | - | The directory to add |
Example
Function PythonSdkDev.withDirectory is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.withDirectory is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.withDirectory is not accessible from the python-sdk-dev moduleFunction PythonSdkDev.withDirectory is not accessible from the python-sdk-dev module