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

🎉 New Source: SpaceX API [low-code cdk] #18311

Merged
merged 23 commits into from
Nov 4, 2022

Conversation

btkcodedev
Copy link
Collaborator

@btkcodedev btkcodedev commented Oct 21, 2022

What

Developing new connector for the source: SpaceX API
New data source with couple of endpoints will be definitely useful

Resolves:
🎉 New Source: SpaceX API

How

Developed using low-code cdk

Recommended reading order

  1. spec.yaml
  2. spacexapi.yaml
  3. schemas/launches.json

🚨 User Impact 🚨

  • No breaking changes, Just addition of new source
New Connector: Source SpaceX API

Community member or Airbyter

  • Community member? Grant edit access to maintainers (instructions)
  • 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
    • Connector's bootstrap.md
    • docs/integrations/<source or destination>/<name>.md including changelog. See changelog example
    • docs/integrations/README.md
    • airbyte-integrations/builds.md
  • PR name follows PR naming conventions

Tests

Integration & Acceptance Full Test Results

image

@CLAassistant
Copy link

CLAassistant commented Oct 21, 2022

CLA assistant check
All committers have signed the CLA.

@github-actions github-actions bot added the area/connectors Connector related issues label Oct 21, 2022
@btkcodedev
Copy link
Collaborator Author

btkcodedev commented Oct 21, 2022

Hello maintainers. I am actually a newbie,
In need of help to proceed.

Unit test output are failing with 3 errors. Need feedback and help:
I've tested with one endpoint 'launches/latest'. And connection is succeeded and data is read.
But the test are failing with config.json and catalog_config.json
The API didn't use any auth, but i pass some dummy api key in header for future enhancements
I really can't understand about what is failing in acceptance test. I've corrected the schema and crosschecked everything.

NEED HELP

Edit: Problem solved

@marcosmarxm
Copy link
Member

Thanks for the contribution @btkcodedev can you check your commit? There are some duplicate files.

},
"capsules": {
"type": "array",
"items": [
Copy link
Contributor

Choose a reason for hiding this comment

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

"items" must be an object instead of an array :)

Copy link
Collaborator Author

@btkcodedev btkcodedev Oct 22, 2022

Choose a reason for hiding this comment

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

@dainiussa Thanks for the help! Acceptance tests passed, Cheers!

@btkcodedev btkcodedev changed the title Init: New Source: SpaceX API 🎉 New Source: SpaceX API Oct 22, 2022
@btkcodedev
Copy link
Collaborator Author

btkcodedev commented Oct 22, 2022

🐛Update: fix: schema is updated and matched with incoming record spec
Thus acceptance tests are resulted in passed state

image

Thanks

@btkcodedev
Copy link
Collaborator Author

btkcodedev commented Oct 22, 2022

TODO:

  • Documentation:
    • README.md
    • bootstrap.md
    • docs/integrations/0/.md
    • airbyte-integrations/builds.md

@btkcodedev
Copy link
Collaborator Author

@marcosmarxm Done, Duplicates removed

@github-actions github-actions bot added the area/documentation Improvements or additions to documentation label Oct 22, 2022
@btkcodedev
Copy link
Collaborator Author

Hello maintainers,
Need the "build URL" for this connector.
Can somebody help with that.

All other things are done.
@marcosmarxm

@btkcodedev
Copy link
Collaborator Author

  • Ingested all endpoints
  • Launches config can now take options, id or keep it as null
  • Acceptance test gives pass result after all the changes to the connector
    image

@btkcodedev
Copy link
Collaborator Author

@marcosmarxm All requested changes done. If the changes are fine, please proceed for the build.

@btkcodedev btkcodedev requested review from marcosmarxm and removed request for dainiussa October 25, 2022 17:16
@marcosmarxm
Copy link
Member

Please check some left comments

$options:
name: "launches"
primary_key: "id"
path: "/launches/{{config['id'] or config['options'] or latest}}"
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@marcosmarxm Config['options] are now provided so that latest, past, upcoming options could be configured if required.

@btkcodedev
Copy link
Collaborator Author

@marcosmarxm Acceptance test is passing after all changes.
Requesting review from the community.

Thanks :)

@btkcodedev btkcodedev requested review from dainiussa and marcosmarxm and removed request for marcosmarxm and dainiussa October 27, 2022 01:42
@btkcodedev btkcodedev changed the title 🎉 New Source: SpaceX API 🎉 New Source: SpaceX API [low-code cdk] Oct 27, 2022
@marcosmarxm
Copy link
Member

marcosmarxm commented Nov 3, 2022

/test connector=connectors/source-spacex-api

🕑 connectors/source-spacex-api https://github.com/airbytehq/airbyte/actions/runs/3386628886
❌ connectors/source-spacex-api https://github.com/airbytehq/airbyte/actions/runs/3386628886
🐛 https://gradle.com/s/lpbgpjv6vx72q

Build Failed

Test summary info:

=========================== short test summary info ============================
FAILED test_core.py::TestDiscovery::test_primary_keys_exist_in_schema[inputs0]
SKIPPED [1] ../usr/local/lib/python3.9/site-packages/source_acceptance_test/plugin.py:63: Skipping TestIncremental.test_two_sequential_reads: not found in the config.
SKIPPED [1] ../usr/local/lib/python3.9/site-packages/source_acceptance_test/tests/test_core.py:51: The previous connector image could not be retrieved.
SKIPPED [1] ../usr/local/lib/python3.9/site-packages/source_acceptance_test/tests/test_core.py:229: The previous connector image could not be retrieved.
============ 1 failed, 23 passed, 3 skipped, 27 warnings in 36.30s =============

@marcosmarxm
Copy link
Member

@btkcodedev there is a test failing. I'll take a look tomorrow and publish the connector.

@marcosmarxm
Copy link
Member

marcosmarxm commented Nov 3, 2022

/test connector=connectors/source-spacex-api

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

	 Name                                                 Stmts   Miss  Cover   Missing
	 ----------------------------------------------------------------------------------
	 source_acceptance_test/base.py                          12      4    67%   16-19
	 source_acceptance_test/config.py                       133      3    98%   87, 93, 230
	 source_acceptance_test/conftest.py                     196     97    51%   35, 41-43, 48, 54, 60, 66, 72-74, 80-95, 100, 105-107, 113-115, 121-122, 127-128, 133, 139, 148-157, 163-168, 232, 238, 244-250, 258-263, 271-284, 289-295, 302-313, 320-336
	 source_acceptance_test/plugin.py                        69     25    64%   22-23, 31, 36, 120-140, 144-148
	 source_acceptance_test/tests/test_core.py              329    106    68%   39, 50-58, 63-70, 74-75, 79-80, 164, 202-219, 228-236, 240-245, 251, 284-289, 327-334, 377-379, 382, 447-455, 484-485, 491, 494, 530-540, 553-578
	 source_acceptance_test/tests/test_incremental.py       145     20    86%   21-23, 29-31, 36-43, 48-61, 224
	 source_acceptance_test/utils/asserts.py                 37      2    95%   57-58
	 source_acceptance_test/utils/common.py                  77     10    87%   15-16, 24-30, 64, 67
	 source_acceptance_test/utils/compare.py                 62     23    63%   21-51, 68, 97-99
	 source_acceptance_test/utils/config_migration.py        23     23     0%   5-37
	 source_acceptance_test/utils/connector_runner.py       112     50    55%   23-26, 32, 36, 39-68, 71-73, 76-78, 81-83, 86-88, 91-93, 96-114, 148-150
	 source_acceptance_test/utils/json_schema_helper.py     105     13    88%   30-31, 38, 41, 65-68, 96, 120, 190-192
	 ----------------------------------------------------------------------------------
	 TOTAL                                                 1479    376    75%

Build Passed

Test summary info:

=========================== short test summary info ============================
SKIPPED [1] ../usr/local/lib/python3.9/site-packages/source_acceptance_test/plugin.py:63: Skipping TestIncremental.test_two_sequential_reads: not found in the config.
SKIPPED [1] ../usr/local/lib/python3.9/site-packages/source_acceptance_test/tests/test_core.py:51: The previous connector image could not be retrieved.
SKIPPED [1] ../usr/local/lib/python3.9/site-packages/source_acceptance_test/tests/test_core.py:229: The previous connector image could not be retrieved.
================= 24 passed, 3 skipped, 27 warnings in 36.34s ==================

@marcosmarxm
Copy link
Member

marcosmarxm commented Nov 3, 2022

/publish connector=connectors/source-spacex-api

🕑 Publishing the following connectors:
connectors/source-spacex-api
https://github.com/airbytehq/airbyte/actions/runs/3390054454


Connector Did it publish? Were definitions generated?
connectors/source-spacex-api

if you have connectors that successfully published but failed definition generation, follow step 4 here ▶️

@marcosmarxm marcosmarxm merged commit 838aebe into airbytehq:master Nov 4, 2022
@btkcodedev
Copy link
Collaborator Author

Thanks @marcosmarxm, You're awesome.

@RealChrisSean
Copy link

Hello @btkcodedev can you please DM me your email for Paypal via slack :) Ty!

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.

7 participants