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 Instagram: Unpin CDK #36314

Merged
merged 5 commits into from
Mar 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

import pendulum
import pytest
from airbyte_cdk.models import AirbyteMessage, ConfiguredAirbyteCatalog, Type
from airbyte_cdk.models import AirbyteMessage, AirbyteStateBlob, ConfiguredAirbyteCatalog, Type
from source_instagram.source import SourceInstagram


Expand All @@ -34,10 +34,14 @@ def test_incremental_streams(self, configured_catalog, config, state):
assert len(records) <= 60 - 10 - 5, "UserInsights should have less records returned when non empty STATE provided"

assert states, "insights should produce states"
for state in states:
assert "user_insights" in state.state.data
assert isinstance(state.state.data["user_insights"], dict)
assert len(state.state.data["user_insights"].keys()) == 2
for state_msg in states:
stream_name, stream_state, state_keys_count = (state_msg.state.stream.stream_descriptor.name,
state_msg.state.stream.stream_state,
len(state_msg.state.stream.stream_state.dict()))

assert stream_name == "user_insights", f"each state message should reference 'user_insights' stream, got {stream_name} instead"
assert isinstance(stream_state, AirbyteStateBlob), f"Stream state should be type AirbyteStateBlob, got {type(stream_state)} instead"
assert state_keys_count == 2, f"Stream state should contain 2 partition keys, got {state_keys_count} instead"

@staticmethod
def slice_catalog(catalog: ConfiguredAirbyteCatalog, predicate: Callable[[str], bool]) -> ConfiguredAirbyteCatalog:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ data:
connectorSubtype: api
connectorType: source
definitionId: 6acf6b55-4f1e-4fca-944e-1a3caef8aba8
dockerImageTag: 3.0.4
dockerImageTag: 3.0.5
dockerRepository: airbyte/source-instagram
githubIssueLabel: source-instagram
icon: instagram.svg
Expand Down
68 changes: 34 additions & 34 deletions airbyte-integrations/connectors/source-instagram/poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ requires = [ "poetry-core>=1.0.0",]
build-backend = "poetry.core.masonry.api"

[tool.poetry]
version = "3.0.4"
version = "3.0.5"
name = "source-instagram"
description = "Source implementation for Instagram."
authors = [ "Airbyte <contact@airbyte.io>",]
Expand All @@ -18,7 +18,7 @@ include = "source_instagram"
[tool.poetry.dependencies]
python = "^3.9,<3.12"
facebook-business = "==18.0.5"
airbyte-cdk = "==0.58.8"
airbyte-cdk = "^0"
cached-property = "==1.5.2"

[tool.poetry.scripts]
Expand Down
1 change: 1 addition & 0 deletions docs/integrations/sources/instagram.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ Instagram limits the number of requests that can be made at a time. See Facebook

| Version | Date | Pull Request | Subject |
|:--------|:-----------|:---------------------------------------------------------|:--------------------------------------------------------------------------------------------------------------------------|
| 3.0.5 | 2024-03-20 | [36314](https://github.com/airbytehq/airbyte/pull/36314) | Unpin CDK version |
| 3.0.4 | 2024-03-07 | [35875](https://github.com/airbytehq/airbyte/pull/35875) | Remove `total_interactions` from the `MediaInsights` queries. |
| 3.0.3 | 2024-02-12 | [35177](https://github.com/airbytehq/airbyte/pull/35177) | Manage dependencies with Poetry. |
| 3.0.2 | 2024-01-15 | [34254](https://github.com/airbytehq/airbyte/pull/34254) | prepare for airbyte-lib |
Expand Down
Loading