ingestr 0.13.88__py3-none-any.whl → 0.13.89__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of ingestr might be problematic. Click here for more details.
- ingestr/src/applovin/__init__.py +1 -1
- ingestr/src/asana_source/__init__.py +1 -1
- ingestr/src/buildinfo.py +1 -1
- ingestr/src/destinations.py +37 -2
- ingestr/src/filesystem/__init__.py +8 -3
- ingestr/src/salesforce/__init__.py +9 -8
- ingestr/src/sources.py +1 -0
- {ingestr-0.13.88.dist-info → ingestr-0.13.89.dist-info}/METADATA +2 -2
- {ingestr-0.13.88.dist-info → ingestr-0.13.89.dist-info}/RECORD +12 -12
- {ingestr-0.13.88.dist-info → ingestr-0.13.89.dist-info}/WHEEL +0 -0
- {ingestr-0.13.88.dist-info → ingestr-0.13.89.dist-info}/entry_points.txt +0 -0
- {ingestr-0.13.88.dist-info → ingestr-0.13.89.dist-info}/licenses/LICENSE.md +0 -0
ingestr/src/applovin/__init__.py
CHANGED
|
@@ -224,7 +224,7 @@ def resource(
|
|
|
224
224
|
def custom_report_from_spec(spec: str) -> EndpointResource:
|
|
225
225
|
parts = spec.split(":")
|
|
226
226
|
if len(parts) != 4:
|
|
227
|
-
raise InvalidCustomReportError()
|
|
227
|
+
raise InvalidCustomReportError()
|
|
228
228
|
|
|
229
229
|
_, endpoint, report, dims = parts
|
|
230
230
|
report_type = ReportType(report.strip())
|
ingestr/src/buildinfo.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
version = "v0.13.
|
|
1
|
+
version = "v0.13.89"
|
ingestr/src/destinations.py
CHANGED
|
@@ -25,7 +25,20 @@ from ingestr.src.loader import load_dlt_file
|
|
|
25
25
|
|
|
26
26
|
class GenericSqlDestination:
|
|
27
27
|
def dlt_run_params(self, uri: str, table: str, **kwargs) -> dict:
|
|
28
|
-
|
|
28
|
+
|
|
29
|
+
if uri.startswith("databricks://"):
|
|
30
|
+
p = urlparse(uri)
|
|
31
|
+
q = parse_qs(p.query)
|
|
32
|
+
schema = q.get("schema", [None])[0]
|
|
33
|
+
if not schema:
|
|
34
|
+
raise ValueError("Databricks requires schema in the URI.")
|
|
35
|
+
res = {
|
|
36
|
+
"dataset_name": schema,
|
|
37
|
+
"table_name": table,
|
|
38
|
+
}
|
|
39
|
+
return res
|
|
40
|
+
|
|
41
|
+
table_fields = table.split(".")
|
|
29
42
|
if len(table_fields) != 2:
|
|
30
43
|
raise ValueError("Table name must be in the format <schema>.<table>")
|
|
31
44
|
|
|
@@ -270,8 +283,30 @@ class MsSQLDestination(GenericSqlDestination):
|
|
|
270
283
|
|
|
271
284
|
class DatabricksDestination(GenericSqlDestination):
|
|
272
285
|
def dlt_dest(self, uri: str, **kwargs):
|
|
273
|
-
|
|
286
|
+
p = urlparse(uri)
|
|
287
|
+
q = parse_qs(p.query)
|
|
288
|
+
access_token = p.password
|
|
289
|
+
server_hostname = p.hostname
|
|
290
|
+
http_path = q.get("http_path", [None])[0]
|
|
291
|
+
catalog = q.get("catalog", [None])[0]
|
|
292
|
+
schema = q.get("schema", [None])[0]
|
|
293
|
+
|
|
294
|
+
|
|
295
|
+
creds = {
|
|
296
|
+
"access_token": access_token,
|
|
297
|
+
"server_hostname": server_hostname,
|
|
298
|
+
"http_path": http_path,
|
|
299
|
+
"catalog": catalog,
|
|
300
|
+
"schema": schema,
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
return dlt.destinations.databricks(
|
|
304
|
+
credentials=creds,
|
|
305
|
+
**kwargs,
|
|
306
|
+
)
|
|
307
|
+
|
|
274
308
|
|
|
309
|
+
|
|
275
310
|
|
|
276
311
|
class SynapseDestination(GenericSqlDestination):
|
|
277
312
|
def dlt_dest(self, uri: str, **kwargs):
|
|
@@ -37,9 +37,14 @@ def readers(
|
|
|
37
37
|
file_glob (str, optional): The filter to apply to the files in glob format. by default lists all files in bucket_url non-recursively
|
|
38
38
|
"""
|
|
39
39
|
filesystem_resource = filesystem(bucket_url, credentials, file_glob=file_glob)
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
40
|
+
|
|
41
|
+
# NOTE: incremental support is disabled until we can figure out
|
|
42
|
+
# how to support incremental loads per matching file, rather
|
|
43
|
+
# than a blanket threshold.
|
|
44
|
+
#
|
|
45
|
+
# filesystem_resource.apply_hints(
|
|
46
|
+
# incremental=dlt.sources.incremental("modification_date"),
|
|
47
|
+
# )
|
|
43
48
|
return (
|
|
44
49
|
filesystem_resource | dlt.transformer(name="read_csv")(_read_csv),
|
|
45
50
|
filesystem_resource | dlt.transformer(name="read_jsonl")(_read_jsonl),
|
|
@@ -13,6 +13,7 @@ def salesforce_source(
|
|
|
13
13
|
username: str,
|
|
14
14
|
password: str,
|
|
15
15
|
token: str,
|
|
16
|
+
domain: str,
|
|
16
17
|
) -> Iterable[DltResource]:
|
|
17
18
|
"""
|
|
18
19
|
Retrieves data from Salesforce using the Salesforce API.
|
|
@@ -26,7 +27,7 @@ def salesforce_source(
|
|
|
26
27
|
DltResource: Data resources from Salesforce.
|
|
27
28
|
"""
|
|
28
29
|
|
|
29
|
-
client = Salesforce(username, password, token)
|
|
30
|
+
client = Salesforce(username, password, token, domain=domain)
|
|
30
31
|
|
|
31
32
|
# define resources
|
|
32
33
|
@dlt.resource(write_disposition="replace")
|
|
@@ -37,7 +38,7 @@ def salesforce_source(
|
|
|
37
38
|
def user_role() -> Iterable[TDataItem]:
|
|
38
39
|
yield get_records(client, "UserRole")
|
|
39
40
|
|
|
40
|
-
@dlt.resource(write_disposition="merge")
|
|
41
|
+
@dlt.resource(write_disposition="merge", primary_key="id")
|
|
41
42
|
def opportunity(
|
|
42
43
|
last_timestamp: incremental[str] = dlt.sources.incremental(
|
|
43
44
|
"SystemModstamp", initial_value=None
|
|
@@ -47,7 +48,7 @@ def salesforce_source(
|
|
|
47
48
|
client, "Opportunity", last_timestamp.last_value, "SystemModstamp"
|
|
48
49
|
)
|
|
49
50
|
|
|
50
|
-
@dlt.resource(write_disposition="merge")
|
|
51
|
+
@dlt.resource(write_disposition="merge", primary_key="id")
|
|
51
52
|
def opportunity_line_item(
|
|
52
53
|
last_timestamp: incremental[str] = dlt.sources.incremental(
|
|
53
54
|
"SystemModstamp", initial_value=None
|
|
@@ -57,7 +58,7 @@ def salesforce_source(
|
|
|
57
58
|
client, "OpportunityLineItem", last_timestamp.last_value, "SystemModstamp"
|
|
58
59
|
)
|
|
59
60
|
|
|
60
|
-
@dlt.resource(write_disposition="merge")
|
|
61
|
+
@dlt.resource(write_disposition="merge", primary_key="id")
|
|
61
62
|
def opportunity_contact_role(
|
|
62
63
|
last_timestamp: incremental[str] = dlt.sources.incremental(
|
|
63
64
|
"SystemModstamp", initial_value=None
|
|
@@ -70,7 +71,7 @@ def salesforce_source(
|
|
|
70
71
|
"SystemModstamp",
|
|
71
72
|
)
|
|
72
73
|
|
|
73
|
-
@dlt.resource(write_disposition="merge")
|
|
74
|
+
@dlt.resource(write_disposition="merge", primary_key="id")
|
|
74
75
|
def account(
|
|
75
76
|
last_timestamp: incremental[str] = dlt.sources.incremental(
|
|
76
77
|
"LastModifiedDate", initial_value=None
|
|
@@ -92,7 +93,7 @@ def salesforce_source(
|
|
|
92
93
|
def campaign() -> Iterable[TDataItem]:
|
|
93
94
|
yield get_records(client, "Campaign")
|
|
94
95
|
|
|
95
|
-
@dlt.resource(write_disposition="merge")
|
|
96
|
+
@dlt.resource(write_disposition="merge", primary_key="id")
|
|
96
97
|
def campaign_member(
|
|
97
98
|
last_timestamp: incremental[str] = dlt.sources.incremental(
|
|
98
99
|
"SystemModstamp", initial_value=None
|
|
@@ -114,7 +115,7 @@ def salesforce_source(
|
|
|
114
115
|
def pricebook_entry() -> Iterable[TDataItem]:
|
|
115
116
|
yield get_records(client, "PricebookEntry")
|
|
116
117
|
|
|
117
|
-
@dlt.resource(write_disposition="merge")
|
|
118
|
+
@dlt.resource(write_disposition="merge", primary_key="id")
|
|
118
119
|
def task(
|
|
119
120
|
last_timestamp: incremental[str] = dlt.sources.incremental(
|
|
120
121
|
"SystemModstamp", initial_value=None
|
|
@@ -122,7 +123,7 @@ def salesforce_source(
|
|
|
122
123
|
) -> Iterable[TDataItem]:
|
|
123
124
|
yield get_records(client, "Task", last_timestamp.last_value, "SystemModstamp")
|
|
124
125
|
|
|
125
|
-
@dlt.resource(write_disposition="merge")
|
|
126
|
+
@dlt.resource(write_disposition="merge", primary_key="id")
|
|
126
127
|
def event(
|
|
127
128
|
last_timestamp: incremental[str] = dlt.sources.incremental(
|
|
128
129
|
"SystemModstamp", initial_value=None
|
ingestr/src/sources.py
CHANGED
|
@@ -2515,6 +2515,7 @@ class SalesforceSource:
|
|
|
2515
2515
|
"username": params.get("username", [None])[0],
|
|
2516
2516
|
"password": params.get("password", [None])[0],
|
|
2517
2517
|
"token": params.get("token", [None])[0],
|
|
2518
|
+
"domain": params.get("domain", [None])[0],
|
|
2518
2519
|
}
|
|
2519
2520
|
for k, v in creds.items():
|
|
2520
2521
|
if v is None:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: ingestr
|
|
3
|
-
Version: 0.13.
|
|
3
|
+
Version: 0.13.89
|
|
4
4
|
Summary: ingestr is a command-line application that ingests data from various sources and stores them in any database.
|
|
5
5
|
Project-URL: Homepage, https://github.com/bruin-data/ingestr
|
|
6
6
|
Project-URL: Issues, https://github.com/bruin-data/ingestr/issues
|
|
@@ -42,7 +42,7 @@ Requires-Dist: confluent-kafka==2.8.0
|
|
|
42
42
|
Requires-Dist: crate==2.0.0
|
|
43
43
|
Requires-Dist: cryptography==44.0.2
|
|
44
44
|
Requires-Dist: curlify==2.2.1
|
|
45
|
-
Requires-Dist: databricks-sql-connector==
|
|
45
|
+
Requires-Dist: databricks-sql-connector==4.0.5
|
|
46
46
|
Requires-Dist: databricks-sqlalchemy==1.0.2
|
|
47
47
|
Requires-Dist: dataclasses-json==0.6.7
|
|
48
48
|
Requires-Dist: decorator==5.2.1
|
|
@@ -2,8 +2,8 @@ ingestr/conftest.py,sha256=OE2yxeTCosS9CUFVuqNypm-2ftYvVBeeq7egm3878cI,1981
|
|
|
2
2
|
ingestr/main.py,sha256=qo0g3wCFl8a_1jUwXagX8L1Q8PKKQlTF7md9pfnzW0Y,27155
|
|
3
3
|
ingestr/src/.gitignore,sha256=8cX1AZTSI0TcdZFGTmS_oyBjpfCzhOEt0DdAo2dFIY8,203
|
|
4
4
|
ingestr/src/blob.py,sha256=UUWMjHUuoR9xP1XZQ6UANQmnMVyDx3d0X4-2FQC271I,2138
|
|
5
|
-
ingestr/src/buildinfo.py,sha256=
|
|
6
|
-
ingestr/src/destinations.py,sha256=
|
|
5
|
+
ingestr/src/buildinfo.py,sha256=YfKg385xjqfTlxcN3drjtO_64R31p1f28goiV70TrQY,21
|
|
6
|
+
ingestr/src/destinations.py,sha256=QNT2rm91cZmY1_Zyj4VnbI14qGmZOUQOQUg9xUTVVYs,23799
|
|
7
7
|
ingestr/src/errors.py,sha256=Ufs4_DfE77_E3vnA1fOQdi6cmuLVNm7_SbFLkL1XPGk,686
|
|
8
8
|
ingestr/src/factory.py,sha256=hC5E_XgrgTHMqwqPc6ihUYvRGTGMTzdPfQhrgPyD0tY,6945
|
|
9
9
|
ingestr/src/filters.py,sha256=0n0sNAVG_f-B_1r7lW5iNtw9z_G1bxWzPaiL1i6tnbU,1665
|
|
@@ -12,14 +12,14 @@ ingestr/src/loader.py,sha256=9NaWAyfkXdqAZSS-N72Iwo36Lbx4PyqIfaaH1dNdkFs,1712
|
|
|
12
12
|
ingestr/src/masking.py,sha256=VN0LdfvExhQ1bZMRylGtaBUIoH-vjuIUmRnYKwo3yiY,11358
|
|
13
13
|
ingestr/src/partition.py,sha256=BrIP6wFJvyR7Nus_3ElnfxknUXeCipK_E_bB8kZowfc,969
|
|
14
14
|
ingestr/src/resource.py,sha256=ZqmZxFQVGlF8rFPhBiUB08HES0yoTj8sZ--jKfaaVps,1164
|
|
15
|
-
ingestr/src/sources.py,sha256=
|
|
15
|
+
ingestr/src/sources.py,sha256=MM_-6ZmIwFLS_L4kBkwJJc0XDyjDyHUkxMMnQaRfuRA,125176
|
|
16
16
|
ingestr/src/table_definition.py,sha256=REbAbqdlmUMUuRh8nEQRreWjPVOQ5ZcfqGkScKdCrmk,390
|
|
17
17
|
ingestr/src/time.py,sha256=H_Fk2J4ShXyUM-EMY7MqCLZQhlnZMZvO952bmZPc4yE,254
|
|
18
18
|
ingestr/src/version.py,sha256=J_2xgZ0mKlvuHcjdKCx2nlioneLH0I47JiU_Slr_Nwc,189
|
|
19
19
|
ingestr/src/adjust/__init__.py,sha256=ULjtJqrNS6XDvUyGl0tjl12-tLyXlCgeFe2icTbtu3Q,3255
|
|
20
20
|
ingestr/src/adjust/adjust_helpers.py,sha256=IHSS94A7enOWkZ8cP5iW3RdYt0Xl3qZGAmDc1Xy4qkI,3802
|
|
21
21
|
ingestr/src/airtable/__init__.py,sha256=XzRsS39xszUlh_s7P1_zq5v8vLfjz3m-NtTPaa8TTZU,2818
|
|
22
|
-
ingestr/src/applovin/__init__.py,sha256=
|
|
22
|
+
ingestr/src/applovin/__init__.py,sha256=Y02ysL2vRiDoP3uN9ven2OVcH9zTd8PbmIjqIHds4zU,6985
|
|
23
23
|
ingestr/src/applovin_max/__init__.py,sha256=fxXqsIibJarp5NOGe08G964HftwLDymTtYS_LqPJht4,3315
|
|
24
24
|
ingestr/src/appsflyer/__init__.py,sha256=QoK-B3cYYMD3bqzQaLWNH6FkJyjRbzRkBF2n6urxubs,8071
|
|
25
25
|
ingestr/src/appsflyer/client.py,sha256=E6xPW4KlbBnQZ0K4eq2Xgb3AmGrtrzIX9bX8EnQr-D4,3615
|
|
@@ -29,7 +29,7 @@ ingestr/src/appstore/errors.py,sha256=KVpPWth5qlv6_QWEm3aJAt3cdf6miPJs0UDzxknx2M
|
|
|
29
29
|
ingestr/src/appstore/models.py,sha256=tW1JSATHBIxZ6a77-RTCBQptJk6iRC8fWcmx4NW7SVA,1716
|
|
30
30
|
ingestr/src/appstore/resources.py,sha256=DJxnNrBohVV0uSeruGV-N_e7UHSlhMhjhYNYdBuqECU,5375
|
|
31
31
|
ingestr/src/arrow/__init__.py,sha256=8fEntgHseKjFMiPQIzxYzw_raicNsEgnveLi1IzBca0,2848
|
|
32
|
-
ingestr/src/asana_source/__init__.py,sha256=
|
|
32
|
+
ingestr/src/asana_source/__init__.py,sha256=p9p89e62Qd3YmrrCCkIclswciSX51pBOMCuT7Ukeq2I,8184
|
|
33
33
|
ingestr/src/asana_source/helpers.py,sha256=PukcdDQWIGqnGxuuobbLw4hUy4-t6gxXg_XywR7Lg9M,375
|
|
34
34
|
ingestr/src/asana_source/settings.py,sha256=-2tpdkwh04RvLKFvwQodnFLYn9MaxOO1hsebGnDQMTU,2829
|
|
35
35
|
ingestr/src/attio/__init__.py,sha256=CLejJjp5vGkt6r18nfNNZ-Xjc1SZgQ5IlcBW5XFQR90,3243
|
|
@@ -47,7 +47,7 @@ ingestr/src/facebook_ads/exceptions.py,sha256=4Nlbc0Mv3i5g-9AoyT-n1PIa8IDi3VCTfE
|
|
|
47
47
|
ingestr/src/facebook_ads/helpers.py,sha256=c-WG008yU_zIdhFwljtqE2jfjVYuaVoNKldxcnJN3U4,9761
|
|
48
48
|
ingestr/src/facebook_ads/settings.py,sha256=Bsic8RcmH-NfEZ7r_NGospTCmwISK9XaMT5y2NZirtg,4938
|
|
49
49
|
ingestr/src/facebook_ads/utils.py,sha256=ES2ylPoW3j3fjp6OMUgp21n1cG1OktXsmWWMk5vBW_I,1590
|
|
50
|
-
ingestr/src/filesystem/__init__.py,sha256=
|
|
50
|
+
ingestr/src/filesystem/__init__.py,sha256=42YAOHQxZ7TkTXC1eeaLUJpjqJ3l7DH7C8j927pV4pc,4353
|
|
51
51
|
ingestr/src/filesystem/helpers.py,sha256=bg0muSHZr3hMa8H4jN2-LGWzI-SUoKlQNiWJ74-YYms,3211
|
|
52
52
|
ingestr/src/filesystem/readers.py,sha256=a0fKkaRpnAOGsXI3EBNYZa7x6tlmAOsgRzb883StY30,3987
|
|
53
53
|
ingestr/src/fluxx/__init__.py,sha256=Ei8BE0KAEzpadJT9RO5-8zMA7LvnIPhNPDKF4EyBcLo,328980
|
|
@@ -116,7 +116,7 @@ ingestr/src/pipedrive/helpers/pages.py,sha256=Klpjw2OnMuhzit3PpiHKsfzGcJ3rQPSQBl
|
|
|
116
116
|
ingestr/src/quickbooks/__init__.py,sha256=cZUuVCOTGPHTscRj6i0DytO63_fWF-4ieMxoU4PcyTg,3727
|
|
117
117
|
ingestr/src/revenuecat/__init__.py,sha256=5HbyZuEOekkbeeT72sM_bnGygSyYdmd_vczfAUz7xoM,4029
|
|
118
118
|
ingestr/src/revenuecat/helpers.py,sha256=CYU6l79kplnfL87GfdxyGeEBrBSWEZfGP0GyjPHuVDk,9619
|
|
119
|
-
ingestr/src/salesforce/__init__.py,sha256=
|
|
119
|
+
ingestr/src/salesforce/__init__.py,sha256=HVHY8pDngB498B6g6KDzwq-q2KPU4PxuEd9Y_8tDDFs,4716
|
|
120
120
|
ingestr/src/salesforce/helpers.py,sha256=QTdazBt-qRTBbCQMZnyclIaDQFmBixBy_RDKD00Lt-8,2492
|
|
121
121
|
ingestr/src/shopify/__init__.py,sha256=RzSSG93g-Qlkz6TAxi1XasFDdxxtVXIo53ZTtjGczW4,62602
|
|
122
122
|
ingestr/src/shopify/exceptions.py,sha256=BhV3lIVWeBt8Eh4CWGW_REFJpGCzvW6-62yZrBWa3nQ,50
|
|
@@ -158,8 +158,8 @@ ingestr/testdata/merge_expected.csv,sha256=DReHqWGnQMsf2PBv_Q2pfjsgvikYFnf1zYcQZ
|
|
|
158
158
|
ingestr/testdata/merge_part1.csv,sha256=Pw8Z9IDKcNU0qQHx1z6BUf4rF_-SxKGFOvymCt4OY9I,185
|
|
159
159
|
ingestr/testdata/merge_part2.csv,sha256=T_GiWxA81SN63_tMOIuemcvboEFeAmbKc7xRXvL9esw,287
|
|
160
160
|
ingestr/tests/unit/test_smartsheets.py,sha256=eiC2CCO4iNJcuN36ONvqmEDryCA1bA1REpayHpu42lk,5058
|
|
161
|
-
ingestr-0.13.
|
|
162
|
-
ingestr-0.13.
|
|
163
|
-
ingestr-0.13.
|
|
164
|
-
ingestr-0.13.
|
|
165
|
-
ingestr-0.13.
|
|
161
|
+
ingestr-0.13.89.dist-info/METADATA,sha256=EfmN2TdrNG9oBfU-U78YNWe9tSZr6smMS5kynvFUBZE,15182
|
|
162
|
+
ingestr-0.13.89.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
163
|
+
ingestr-0.13.89.dist-info/entry_points.txt,sha256=oPJy0KBnPWYjDtP1k8qwAihcTLHSZokSQvRAw_wtfJM,46
|
|
164
|
+
ingestr-0.13.89.dist-info/licenses/LICENSE.md,sha256=cW8wIhn8HFE-KLStDF9jHQ1O_ARWP3kTpk_-eOccL24,1075
|
|
165
|
+
ingestr-0.13.89.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|