Skip to content

Commit 5058172

Browse files
Removing field deletions and id generation
1 parent d204372 commit 5058172

File tree

4 files changed

+6
-9
lines changed

4 files changed

+6
-9
lines changed

airbyte-config/init/src/main/resources/config/STANDARD_SOURCE_DEFINITION/36c891d9-4bd9-43ac-bad2-10e12756272c.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"sourceDefinitionId": "36c891d9-4bd9-43ac-bad2-10e12756272c",
33
"name": "HubSpot",
44
"dockerRepository": "airbyte/source-hubspot",
5-
"dockerImageTag": "0.1.29",
5+
"dockerImageTag": "0.1.30",
66
"documentationUrl": "https://docs.airbyte.io/integrations/sources/hubspot",
77
"icon": "hubspot.svg"
88
}

airbyte-config/init/src/main/resources/seed/source_definitions.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,7 @@
287287
- name: HubSpot
288288
sourceDefinitionId: 36c891d9-4bd9-43ac-bad2-10e12756272c
289289
dockerRepository: airbyte/source-hubspot
290-
dockerImageTag: 0.1.29
290+
dockerImageTag: 0.1.30
291291
documentationUrl: https://docs.airbyte.io/integrations/sources/hubspot
292292
icon: hubspot.svg
293293
sourceType: api

airbyte-integrations/connectors/source-hubspot/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,5 +34,5 @@ COPY source_hubspot ./source_hubspot
3434
ENV AIRBYTE_ENTRYPOINT "python /airbyte/integration_code/main.py"
3535
ENTRYPOINT ["python", "/airbyte/integration_code/main.py"]
3636

37-
LABEL io.airbyte.version=0.1.29
37+
LABEL io.airbyte.version=0.1.30
3838
LABEL io.airbyte.name=airbyte/source-hubspot

airbyte-integrations/connectors/source-hubspot/source_hubspot/api.py

+3-6
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
from functools import lru_cache, partial
1111
from http import HTTPStatus
1212
from typing import Any, Callable, Iterable, Iterator, List, Mapping, MutableMapping, Optional, Tuple, Union
13-
from uuid import uuid4
1413

1514
import backoff
1615
import pendulum as pendulum
@@ -716,8 +715,9 @@ class FormSubmissionStream(Stream):
716715
def _transform(self, records: Iterable) -> Iterable:
717716
for record in super()._transform(records):
718717
keys = record.keys()
719-
if "id" not in keys:
720-
record["id"] = uuid4()
718+
719+
# There's no updatedAt field in the submission however forms fetched by using this field,
720+
# so it has to be added to the submissions otherwise it would fail when calling _filter_old_records
721721
if "updatedAt" not in keys:
722722
record["updatedAt"] = record["submittedAt"]
723723

@@ -726,9 +726,6 @@ def _transform(self, records: Iterable) -> Iterable:
726726
def list(self, fields) -> Iterable:
727727
for form in self.read(getter=partial(self._api.get, url="/marketing/v3/forms")):
728728
for submission in self.read(getter=partial(self._api.get, url=f"{self.url}/{form['id']}")):
729-
del submission["id"]
730-
del submission["updatedAt"]
731-
732729
submission["formId"] = form["id"]
733730
yield submission
734731

0 commit comments

Comments
 (0)