diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 117fffa4..e3b1d367 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -9,10 +9,10 @@ jobs: strategy: matrix: python-version: - - "3.7" - "3.8" - "3.9" - "3.10" + - "3.11" fail-fast: false steps: - uses: actions/checkout@v4 @@ -33,8 +33,7 @@ jobs: env: PREFECT_SERVER_DATABASE_CONNECTION_URL: "sqlite+aiosqlite:///./collection-tests.db" run: | - coverage run --branch -m pytest tests -vv - coverage report + pytest --cov=prefect_gcp --no-cov-on-fail --cov-report=term-missing --cov-branch tests -n auto -vv - name: Run mkdocs build run: | diff --git a/CHANGELOG.md b/CHANGELOG.md index 8d7db04a..a7325317 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -19,6 +19,26 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Security +## 0.5.1 + +Released October 12th, 2023. + +### Changed + +- Updated workers to respect default command from base worker configuration - [#216](https://github.com/PrefectHQ/prefect-gcp/pull/216) + +## 0.5.0 + +Released October 5th, 2023. + +### Fixed + +- Empty logging in `list_folders` and `list_blobs` - [#214](https://github.com/PrefectHQ/prefect-gcp/pull/214) + +### Added + +- Conditional imports to support operating with `pydantic>2` installed - [#215](https://github.com/PrefectHQ/prefect-gcp/pull/215) + ## 0.4.7 Released September 22nd, 2023. diff --git a/README.md b/README.md index f6e4a418..b8ac648e 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,6 @@ -# Coordinate and use GCP in your dataflow with `prefect-gcp` +# `prefect-gcp`

- -
PyPI @@ -18,7 +16,7 @@

-The `prefect-gcp` collection makes it easy to leverage the capabilities of Google Cloud Platform (GCP) in your flows, featuring support for Vertex AI, Cloud Run, BigQuery, Cloud Storage, and Secret Manager. +`prefect-gcp` makes it easy to leverage the capabilities of Google Cloud Platform (GCP) in your flows, featuring support for Vertex AI, Cloud Run, BigQuery, Cloud Storage, and Secret Manager. Visit the full docs [here](https://PrefectHQ.github.io/prefect-gcp). diff --git a/docs/img/favicon.ico b/docs/img/favicon.ico index c4b42158..159c4152 100644 Binary files a/docs/img/favicon.ico and b/docs/img/favicon.ico differ diff --git a/docs/img/prefect-logo-mark-solid-white-500.png b/docs/img/prefect-logo-mark-solid-white-500.png deleted file mode 100644 index f83aa6ef..00000000 Binary files a/docs/img/prefect-logo-mark-solid-white-500.png and /dev/null differ diff --git a/docs/img/prefect-logo-mark.png b/docs/img/prefect-logo-mark.png new file mode 100644 index 00000000..0d696821 Binary files /dev/null and b/docs/img/prefect-logo-mark.png differ diff --git a/docs/index.md b/docs/index.md index 889fb525..715a9a23 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,24 +1,22 @@ -# Coordinate and use GCP in your dataflow with `prefect-gcp` +# `prefect-gcp`

- -
- PyPI + PyPI - + - + - +
- + - +

-The `prefect-gcp` collection makes it easy to leverage the capabilities of Google Cloud Platform (GCP) in your flows, featuring support for Vertex AI, Cloud Run, BigQuery, Cloud Storage, and Secret Manager. +`prefect-gcp` makes it easy to leverage the capabilities of Google Cloud Platform (GCP) in your flows, featuring support for Vertex AI, Cloud Run, BigQuery, Cloud Storage, and Secret Manager. ## Getting Started diff --git a/docs/stylesheets/extra.css b/docs/stylesheets/extra.css index 11a02095..662cca0c 100644 --- a/docs/stylesheets/extra.css +++ b/docs/stylesheets/extra.css @@ -1,9 +1,9 @@ /* theme */ :root > * { /* theme */ - --md-primary-fg-color: #115AF4; - --md-primary-fg-color--light: #115AF4; - --md-primary-fg-color--dark: #115AF4; + --md-primary-fg-color: #26272B; + --md-primary-fg-color--light: #26272B; + --md-primary-fg-color--dark: #26272B; } /* Table formatting */ @@ -72,7 +72,7 @@ to force column width */ /* dark mode slate theme */ /* dark mode code overrides */ [data-md-color-scheme="slate"] { - --md-code-bg-color: #252a33; + --md-code-bg-color: #1c1d20; --md-code-fg-color: #eee; --md-code-hl-color: #3b3d54; --md-code-hl-name-color: #eee; @@ -100,15 +100,15 @@ to force column width */ /* dark mode collection catalog overrides */ [data-md-color-scheme="slate"] .collection-item { - background-color: #3b3d54; + background-color: #26272B; } /* dark mode recipe collection overrides */ [data-md-color-scheme="slate"] .recipe-item { - background-color: #3b3d54; + background-color: #26272B; } /* dark mode API doc overrides */ [data-md-color-scheme="slate"] .prefect-table th { - background-color: #3b3d54; + background-color: #26272B; } \ No newline at end of file diff --git a/mkdocs.yml b/mkdocs.yml index 5f45af38..2fc94655 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -28,7 +28,7 @@ theme: icon: repo: fontawesome/brands/github logo: - img/prefect-logo-mark-solid-white-500.png + img/prefect-logo-mark.png font: text: Inter code: Source Code Pro diff --git a/prefect_gcp/workers/cloud_run.py b/prefect_gcp/workers/cloud_run.py index e3824d9b..01ab1e39 100644 --- a/prefect_gcp/workers/cloud_run.py +++ b/prefect_gcp/workers/cloud_run.py @@ -364,11 +364,7 @@ def _populate_or_format_command(self): if command is None: self.job_body["spec"]["template"]["spec"]["template"]["spec"][ "containers" - ][0]["command"] = [ - "python", - "-m", - "prefect.engine", - ] + ][0]["command"] = shlex.split(self._base_flow_run_command()) elif isinstance(command, str): self.job_body["spec"]["template"]["spec"]["template"]["spec"][ "containers" diff --git a/prefect_gcp/workers/vertex.py b/prefect_gcp/workers/vertex.py index cbb12e0f..4a384e0f 100644 --- a/prefect_gcp/workers/vertex.py +++ b/prefect_gcp/workers/vertex.py @@ -311,11 +311,9 @@ def _inject_formatted_command(self): existing_command = worker_pool_specs[0]["container_spec"].get("command") if existing_command is None: - worker_pool_specs[0]["container_spec"]["command"] = [ - "python", - "-m", - "prefect.engine", - ] + worker_pool_specs[0]["container_spec"]["command"] = shlex.split( + self._base_flow_run_command() + ) elif isinstance(existing_command, str): worker_pool_specs[0]["container_spec"]["command"] = shlex.split( existing_command diff --git a/requirements-dev.txt b/requirements-dev.txt index a04a0319..581c0c91 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -1,17 +1,19 @@ -pandas -pyarrow -pytest black +coverage flake8 -mypy +interrogate +isort mkdocs +mkdocs-gen-files mkdocs-material mkdocstrings[python] -isort -pre-commit -pytest-asyncio mock; python_version < '3.8' -mkdocs-gen-files -interrogate -coverage +mypy +pandas pillow +pre-commit +pyarrow +pytest +pytest-asyncio +pytest-cov +pytest-xdist