Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

connector builder FE should consume a versioned artifact of declarative_component_schema.yaml #21830

Closed
c-p-b opened this issue Jan 25, 2023 · 4 comments · Fixed by #22422
Closed
Assignees
Labels

Comments

@c-p-b
Copy link
Contributor

c-p-b commented Jan 25, 2023

Tell us about the problem you're trying to solve

Currently the platform frontend build needs a file called declarative_component_schema.yaml to build. This lives in the connector sdk subfolder. This hard dependency should be updated to consume a pinned version of that schema instead.

Describe the solution you’d like

A version of the file already gets published as part of the airbyte-cdk pypi package. We could simply update the frontend build to download a pinned version of that pypi package, extract the tar, and go grab the yaml file in the subfolder - rather than referencing the hardcoded file

Describe the alternative you’ve considered or used

We also consider putting this file in the "shared" code that is shared between connectors and platform. However, this approach should be discouraged because we are in the middle of decoupling and removing as many hard dependencies as possible in shared code.

Additional context

This was discovered as part of a larger effort of refactoring the split between airbyte platform and airbyte connectors. However, Alex G. noted it probably should be done under any circumstance because currently it's possible that the server can use a different version from the webapp.

@timroes
Copy link
Contributor

timroes commented Jan 25, 2023

Cc @flash1293 @lmossman for information

@flash1293
Copy link
Contributor

Agree with the described solution! I took a quick look at this and it should be really simple to add the loading to the existing generate-client script in the webapp package.json loading it in a pre-determined location like this:

curl -L https://pypi.python.org/packages/source/a/airbyte-cdk/airbyte-cdk-${version}.tar.gz | tar -xzO airbyte-cdk-${version}/airbyte_cdk/sources/declarative/declarative_component_schema.yaml > build/lowcode_manifest.yaml

Ideally we also find a way to always keep this in sync with the version in the connector builder server:

install_requires=["airbyte-cdk==0.23", "fastapi", "uvicorn"],

@flash1293
Copy link
Contributor

Grooming note:

  • Make sure this version is in sync with what the connector builder server does

@c-p-b
Copy link
Contributor Author

c-p-b commented Feb 7, 2023

Thank you guys for the quick turnaround on this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants