Skip to content

Commit

Permalink
Allow passing --use-local-cdk to prerelease publish (#31716)
Browse files Browse the repository at this point in the history
  • Loading branch information
erohmensing committed Oct 24, 2023
1 parent 3738987 commit 1336b4e
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 1 deletion.
1 change: 1 addition & 0 deletions airbyte-ci/connectors/pipelines/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -408,6 +408,7 @@ This command runs the Python tests for a airbyte-ci poetry package.
## Changelog
| Version | PR | Description |
| ------- | ---------------------------------------------------------- | --------------------------------------------------------------------------------------------------------- |
| 2.4.0 | [#31716](https://github.com/airbytehq/airbyte/pull/31716) | Enable pre-release publish with local CDK.
| 2.3.1 | [#31748](https://github.com/airbytehq/airbyte/pull/31748) | Use AsyncClick library instead of base Click. |
| 2.3.0 | [#31699](https://github.com/airbytehq/airbyte/pull/31699) | Support optional concurrent CAT execution. |
| 2.2.6 | [#31752](https://github.com/airbytehq/airbyte/pull/31752) | Only authenticate when secrets are available.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ async def publish(
pull_request=ctx.obj.get("pull_request"),
s3_build_cache_access_key_id=ctx.obj.get("s3_build_cache_access_key_id"),
s3_build_cache_secret_key=ctx.obj.get("s3_build_cache_secret_key"),
use_local_cdk=ctx.obj.get("use_local_cdk"),
)
for connector in ctx.obj["selected_connectors_with_modified_files"]
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ def __init__(
pull_request: PullRequest = None,
s3_build_cache_access_key_id: Optional[str] = None,
s3_build_cache_secret_key: Optional[str] = None,
use_local_cdk: Optional[bool] = False,
):
self.pre_release = pre_release
self.spec_cache_bucket_name = spec_cache_bucket_name
Expand All @@ -50,6 +51,9 @@ def __init__(
pipeline_name = f"Publish {connector.technical_name}"
pipeline_name = pipeline_name + " (pre-release)" if pre_release else pipeline_name

if use_local_cdk and not self.pre_release:
raise click.UsageError("Publishing with the local CDK is only supported for pre-release publishing.")

super().__init__(
pipeline_name=pipeline_name,
connector=connector,
Expand All @@ -66,6 +70,7 @@ def __init__(
reporting_slack_channel=reporting_slack_channel,
ci_gcs_credentials=ci_gcs_credentials,
should_save_report=True,
use_local_cdk=use_local_cdk,
docker_hub_username=docker_hub_username,
docker_hub_password=docker_hub_password,
s3_build_cache_access_key_id=s3_build_cache_access_key_id,
Expand Down
2 changes: 1 addition & 1 deletion airbyte-ci/connectors/pipelines/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"

[tool.poetry]
name = "pipelines"
version = "2.3.1"
version = "2.4.0"
description = "Packaged maintained by the connector operations team to perform CI for connectors' pipelines"
authors = ["Airbyte <contact@airbyte.io>"]

Expand Down

0 comments on commit 1336b4e

Please sign in to comment.