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

🐛 Source Github: log the error message for streams that are restricted for OAuth #9868

Merged
merged 7 commits into from
Feb 2, 2022

Conversation

bazarnov
Copy link
Collaborator

@bazarnov bazarnov commented Jan 28, 2022

What

Resolving On-Call: https://github.com/airbytehq/oncall/issues/117

How

  • added the Full Error message with the description about what caused the 403 Forbidden for certain streams, like Teams
  • added more scopes for OAuth Flow implementation for source-github (GitHubOAuthFlow.java)
  • added config_oauth into SAT tests + created new secret for that, this part wasn't tested before

🚨 User Impact 🚨

Users must update the connector version up to 0.2.16, in some cases users should proceed the re-authentication for their GitHub connector, check the Note bellow.

Note:

Re-authenticate the connector is required if:

  • for all users who has the issues with 403 Forbidden for certain streams, on versions < 0.2.16 using Airbyte-Cloud.

Otherwise:

  • no action required

Pre-merge Checklist

Expand the relevant checklist and delete the others.

Updating a connector

#### Community member or Airbyter

  • Secrets in the connector's spec are annotated with airbyte_secret
  • Unit & integration tests added and passing. Community members, please provide proof of success locally e.g: screenshot or copy-paste unit, integration, and acceptance test output. To run acceptance tests for a Python connector, follow instructions in the README. For java connectors run ./gradlew :airbyte-integrations:connectors:<name>:integrationTest.
  • Code reviews completed
  • Documentation updated
    • Connector's README.md
    • Changelog updated in docs/integrations/<source or destination>/<name>.md including changelog. See changelog example
  • PR name follows PR naming conventions

Airbyter

If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.

  • Create a non-forked branch based on this PR and test the below items on it
  • Build is successful
  • Credentials added to Github CI. Instructions.
  • /test connector=connectors/<name> command is passing.
  • New Connector version released on Dockerhub by running the /publish command described here
  • After the new connector version is published, connector version bumped in the seed directory as described here
  • Seed specs have been re-generated by building the platform and committing the changes to the seed spec files, as described here

@bazarnov bazarnov self-assigned this Jan 28, 2022
@github-actions github-actions bot added the area/connectors Connector related issues label Jan 28, 2022
@airbytehq airbytehq deleted a comment from codecov bot Jan 28, 2022
@octavia-squidington-iii octavia-squidington-iii temporarily deployed to more-secrets January 28, 2022 12:50 Inactive
@ChristopheDuong
Copy link
Contributor

All configurations with previously configured github source would have to re-auth for new scopes?

@bazarnov
Copy link
Collaborator Author

All configurations with previously configured github source would have to re-auth for new scopes?

Not necessary:

  • if sync was successful previously, or if the PAT is used as authentication option.

Necessary

  • for all users who has the issues with 403 Forbidden for certain streams, on versions < 0.2.16 using Airbyte-Cloud.

@codecov

This comment has been minimized.

@bazarnov bazarnov temporarily deployed to more-secrets January 29, 2022 08:15 Inactive
@bazarnov
Copy link
Collaborator Author

bazarnov commented Jan 29, 2022

/test connector=connectors/source-github

🕑 connectors/source-github https://github.com/airbytehq/airbyte/actions/runs/1765317943
✅ connectors/source-github https://github.com/airbytehq/airbyte/actions/runs/1765317943
Python tests coverage:

	 ---------- coverage: platform linux, python 3.8.10-final-0 -----------
	 Name                                                 Stmts   Miss  Cover
	 ------------------------------------------------------------------------
	 source_acceptance_test/__init__.py                       2      0   100%
	 source_acceptance_test/base.py                          10      4    60%
	 source_acceptance_test/config.py                        74      6    92%
	 source_acceptance_test/conftest.py                     109    109     0%
	 source_acceptance_test/plugin.py                        47     47     0%
	 source_acceptance_test/tests/__init__.py                 4      0   100%
	 source_acceptance_test/tests/test_core.py              275    106    61%
	 source_acceptance_test/tests/test_full_refresh.py       52      2    96%
	 source_acceptance_test/tests/test_incremental.py        69     38    45%
	 source_acceptance_test/utils/__init__.py                 6      0   100%
	 source_acceptance_test/utils/asserts.py                 37      2    95%
	 source_acceptance_test/utils/common.py                  70     17    76%
	 source_acceptance_test/utils/compare.py                 62     23    63%
	 source_acceptance_test/utils/connector_runner.py       110     48    56%
	 source_acceptance_test/utils/json_schema_helper.py     105     13    88%
	 ------------------------------------------------------------------------
	 TOTAL                                                 1032    415    60%
	 ---------- coverage: platform linux, python 3.8.10-final-0 -----------
	 Name                        Stmts   Miss  Cover
	 -----------------------------------------------
	 source_github/__init__.py       2      0   100%
	 source_github/source.py        78     35    55%
	 source_github/streams.py      373    164    56%
	 -----------------------------------------------
	 TOTAL                         453    199    56%

@octavia-squidington-iii octavia-squidington-iii temporarily deployed to more-secrets January 29, 2022 08:40 Inactive
Copy link
Contributor

@antixar antixar left a comment

Choose a reason for hiding this comment

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

Please try to check my assumption

@bazarnov
Copy link
Collaborator Author

bazarnov commented Feb 2, 2022

/test connector=connectors/source-github

🕑 connectors/source-github https://github.com/airbytehq/airbyte/actions/runs/1783148698
✅ connectors/source-github https://github.com/airbytehq/airbyte/actions/runs/1783148698
Python tests coverage:

	 Name                                                 Stmts   Miss  Cover
	 ------------------------------------------------------------------------
	 source_acceptance_test/__init__.py                       2      0   100%
	 source_acceptance_test/base.py                          10      4    60%
	 source_acceptance_test/config.py                        74      6    92%
	 source_acceptance_test/tests/__init__.py                 4      0   100%
	 source_acceptance_test/tests/test_core.py              275    106    61%
	 source_acceptance_test/tests/test_full_refresh.py       52      2    96%
	 source_acceptance_test/tests/test_incremental.py        69     38    45%
	 source_acceptance_test/utils/__init__.py                 6      0   100%
	 source_acceptance_test/utils/asserts.py                 37      2    95%
	 source_acceptance_test/utils/common.py                  70     17    76%
	 source_acceptance_test/utils/compare.py                 62     23    63%
	 source_acceptance_test/utils/connector_runner.py       110     48    56%
	 source_acceptance_test/utils/json_schema_helper.py     105     13    88%
	 ------------------------------------------------------------------------
	 TOTAL                                                  876    259    70%
	 Name                        Stmts   Miss  Cover
	 -----------------------------------------------
	 source_github/__init__.py       2      0   100%
	 source_github/source.py        78     35    55%
	 source_github/streams.py      373    164    56%
	 -----------------------------------------------
	 TOTAL                         453    199    56%

@bazarnov bazarnov temporarily deployed to more-secrets February 2, 2022 09:39 Inactive
@octavia-squidington-iii octavia-squidington-iii temporarily deployed to more-secrets February 2, 2022 09:41 Inactive
@bazarnov
Copy link
Collaborator Author

bazarnov commented Feb 2, 2022

/publish connector=connectors/source-github

🕑 connectors/source-github https://github.com/airbytehq/airbyte/actions/runs/1783272842
✅ connectors/source-github https://github.com/airbytehq/airbyte/actions/runs/1783272842

@octavia-squidington-iii octavia-squidington-iii temporarily deployed to more-secrets February 2, 2022 10:12 Inactive
@bazarnov bazarnov temporarily deployed to more-secrets February 2, 2022 10:57 Inactive
@bazarnov bazarnov temporarily deployed to more-secrets February 2, 2022 11:21 Inactive
@bazarnov bazarnov temporarily deployed to more-secrets February 2, 2022 11:37 Inactive
@bazarnov bazarnov merged commit 981df9c into master Feb 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/connectors Connector related issues
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants