Skip to content

Commit

Permalink
Merge pull request #1270 from estuary/fix/python_packages
Browse files Browse the repository at this point in the history
fix: Python packages broke when introducing `source-hubspot`, this fixes all python packages
  • Loading branch information
dyaffe authored Feb 16, 2024
2 parents 3e06e50 + d92eb2d commit 2a593c6
Show file tree
Hide file tree
Showing 35 changed files with 7 additions and 6 deletions.
1 change: 0 additions & 1 deletion python/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ WORKDIR /connector
COPY --from=builder /builder/connector ./$CONNECTOR_NAME
COPY --from=builder /builder/python ./python

ENV PYTHONPATH="/connector/$CONNECTOR_NAME"
# Arg substitution in CMD doesn't seem to work
ENV CONNECTOR_NAME=$CONNECTOR_NAME
CMD python -m $CONNECTOR_NAME
Empty file added source-hubspot/__init__.py
Empty file.
2 changes: 1 addition & 1 deletion source-hubspot/__main__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import urllib
from flow_sdk import shim_airbyte_cdk
from source_hubspot import SourceHubspot
from .source_hubspot import SourceHubspot

scopes = [
"forms",
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 3 additions & 1 deletion source-hubspot/source_hubspot/source.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,15 @@

import logging
from itertools import chain
from pathlib import Path
from typing import Any, List, Mapping, Optional, Tuple

import requests
from airbyte_cdk.logger import AirbyteLogger
from airbyte_cdk.sources import AbstractSource
from airbyte_cdk.sources.streams import Stream
from requests import HTTPError
from source_hubspot.streams import (
from .streams import (
API,
Campaigns,
Companies,
Expand Down Expand Up @@ -45,6 +46,7 @@
)



class SourceHubspot(AbstractSource):
logger = logging.getLogger('hubspot')

Expand Down
6 changes: 3 additions & 3 deletions source-hubspot/source_hubspot/streams.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
from airbyte_cdk.sources.streams.http.requests_native_auth import Oauth2Authenticator, TokenAuthenticator
from airbyte_cdk.sources.utils.transform import TransformConfig, TypeTransformer
from requests import HTTPError, codes
from source_hubspot.constants import OAUTH_CREDENTIALS, PRIVATE_APP_CREDENTIALS
from source_hubspot.errors import HubspotAccessDenied, HubspotInvalidAuth, HubspotRateLimited, HubspotTimeout, InvalidStartDateConfigError
from source_hubspot.helpers import APIv1Property, APIv3Property, GroupByKey, IRecordPostProcessor, IURLPropertyRepresentation, StoreAsIs
from .constants import OAUTH_CREDENTIALS, PRIVATE_APP_CREDENTIALS
from .errors import HubspotAccessDenied, HubspotInvalidAuth, HubspotRateLimited, HubspotTimeout, InvalidStartDateConfigError
from .helpers import APIv1Property, APIv3Property, GroupByKey, IRecordPostProcessor, IURLPropertyRepresentation, StoreAsIs

# we got this when provided API Token has incorrect format
CLOUDFLARE_ORIGIN_DNS_ERROR = 530
Expand Down
File renamed without changes.

0 comments on commit 2a593c6

Please sign in to comment.