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 server: Fail on failing tests #21198

Merged
merged 5 commits into from
Jan 12, 2023

Conversation

flash1293
Copy link
Contributor

@flash1293 flash1293 commented Jan 10, 2023

Fixes #21197

By making sure the error from the python -m pytest command bubbles up correctly.

@flash1293 flash1293 temporarily deployed to more-secrets January 10, 2023 11:38 — with GitHub Actions Inactive
@flash1293 flash1293 temporarily deployed to more-secrets January 10, 2023 11:38 — with GitHub Actions Inactive
@flash1293 flash1293 temporarily deployed to more-secrets January 10, 2023 15:23 — with GitHub Actions Inactive
@flash1293 flash1293 temporarily deployed to more-secrets January 10, 2023 15:23 — with GitHub Actions Inactive
@flash1293 flash1293 marked this pull request as ready for review January 10, 2023 18:08
@flash1293 flash1293 requested a review from lmossman January 11, 2023 09:09
Copy link
Contributor

@lmossman lmossman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change LGTM.

But since the tests are currently failing, does that mean merging this will break CI? If so then we will need to fix those tests before merging this.
It seems like the tests are passing on the PR so I guess that is not the case? Was a fix already merged for the issue in the ticket that was causing the 8 test failures?

When I run the airbyte-connector-builder-server:airbytePythonDockerApply command on this branch, this is the output that I get:

==================================== ERRORS ====================================
_____ ERROR collecting connector_builder/impl/test_low_code_cdk_adapter.py _____
ImportError while importing test module '/home/unit_tests/connector_builder/impl/test_low_code_cdk_adapter.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/local/lib/python3.9/importlib/__init__.py:127: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
unit_tests/connector_builder/impl/test_low_code_cdk_adapter.py:13: in <module>
    from airbyte_cdk.sources.declarative.parsers.undefined_reference_exception import UndefinedReferenceException
E   ModuleNotFoundError: No module named 'airbyte_cdk.sources.declarative.parsers.undefined_reference_exception'
=========================== short test summary info ============================
ERROR unit_tests/connector_builder/impl/test_low_code_cdk_adapter.py
!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!
=============================== 1 error in 1.41s ===============================

> Task :airbyte-connector-builder-server:airbytePythonDockerApply FAILED

@flash1293
Copy link
Contributor Author

The unit tests should have been fixed by #21107 , maybe this is a new problem that came in in between. Looking into this.

@flash1293
Copy link
Contributor Author

Seems like there was a bad version of airbyte-cdk published (0.19) - pinning it to 0.18.1 for the connector-builder-server makes the build work on this PR. Let's wait for this to be resolved before merging this PR.

@flash1293 flash1293 temporarily deployed to more-secrets January 12, 2023 10:02 — with GitHub Actions Inactive
@flash1293 flash1293 temporarily deployed to more-secrets January 12, 2023 10:03 — with GitHub Actions Inactive
@flash1293
Copy link
Contributor Author

An import path changed slightly, fixed that. Merging on green build.

@flash1293 flash1293 enabled auto-merge (squash) January 12, 2023 12:11
@flash1293 flash1293 temporarily deployed to more-secrets January 12, 2023 12:12 — with GitHub Actions Inactive
@flash1293 flash1293 temporarily deployed to more-secrets January 12, 2023 12:12 — with GitHub Actions Inactive
@flash1293 flash1293 merged commit 5b46c65 into master Jan 12, 2023
@flash1293 flash1293 deleted the flash1293/fail-on-failing-unit-test branch January 12, 2023 12:48
jbfbell pushed a commit that referenced this pull request Jan 13, 2023
* fail on failing command

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

Successfully merging this pull request may close these issues.

Connector builder server: Build does not fail on failing unit tests
2 participants