etlplus 0.9.0__py3-none-any.whl → 0.11.5__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.
- etlplus/cli/commands.py +19 -19
- etlplus/cli/constants.py +1 -1
- etlplus/cli/io.py +2 -2
- etlplus/config/pipeline.py +2 -2
- etlplus/database/ddl.py +1 -1
- etlplus/enums.py +3 -77
- etlplus/extract.py +5 -7
- etlplus/file/__init__.py +25 -0
- etlplus/file/core.py +287 -0
- etlplus/file/csv.py +82 -0
- etlplus/file/enums.py +238 -0
- etlplus/file/json.py +87 -0
- etlplus/file/xml.py +165 -0
- etlplus/file/yaml.py +125 -0
- etlplus/load.py +9 -12
- etlplus/run.py +6 -9
- {etlplus-0.9.0.dist-info → etlplus-0.11.5.dist-info}/METADATA +1 -1
- {etlplus-0.9.0.dist-info → etlplus-0.11.5.dist-info}/RECORD +22 -16
- etlplus/file.py +0 -657
- {etlplus-0.9.0.dist-info → etlplus-0.11.5.dist-info}/WHEEL +0 -0
- {etlplus-0.9.0.dist-info → etlplus-0.11.5.dist-info}/entry_points.txt +0 -0
- {etlplus-0.9.0.dist-info → etlplus-0.11.5.dist-info}/licenses/LICENSE +0 -0
- {etlplus-0.9.0.dist-info → etlplus-0.11.5.dist-info}/top_level.txt +0 -0
etlplus/run.py
CHANGED
|
@@ -23,7 +23,6 @@ from .api import RetryPolicy
|
|
|
23
23
|
from .api import Url
|
|
24
24
|
from .config import load_pipeline_config
|
|
25
25
|
from .enums import DataConnectorType
|
|
26
|
-
from .enums import coerce_data_connector_type
|
|
27
26
|
from .extract import extract
|
|
28
27
|
from .load import load
|
|
29
28
|
from .run_helpers import compose_api_request_env
|
|
@@ -185,8 +184,7 @@ def run(
|
|
|
185
184
|
|
|
186
185
|
data: Any
|
|
187
186
|
stype_raw = getattr(source_obj, 'type', None)
|
|
188
|
-
|
|
189
|
-
match stype:
|
|
187
|
+
match DataConnectorType.coerce(stype_raw or ''):
|
|
190
188
|
case DataConnectorType.FILE:
|
|
191
189
|
path = getattr(source_obj, 'path', None)
|
|
192
190
|
fmt = ex_opts.get('format') or getattr(
|
|
@@ -261,8 +259,8 @@ def run(
|
|
|
261
259
|
sleep_seconds=cast(float, env.get('sleep_seconds', 0.0)),
|
|
262
260
|
)
|
|
263
261
|
case _:
|
|
264
|
-
#
|
|
265
|
-
#
|
|
262
|
+
# :meth:`coerce` already raises for invalid connector types, but
|
|
263
|
+
# keep explicit guard for defensive programming.
|
|
266
264
|
raise ValueError(f'Unsupported source type: {stype_raw}')
|
|
267
265
|
|
|
268
266
|
# DRY: unified validation helper (pre/post transform)
|
|
@@ -318,8 +316,7 @@ def run(
|
|
|
318
316
|
overrides = job_obj.load.overrides or {}
|
|
319
317
|
|
|
320
318
|
ttype_raw = getattr(target_obj, 'type', None)
|
|
321
|
-
|
|
322
|
-
match ttype:
|
|
319
|
+
match DataConnectorType.coerce(ttype_raw or ''):
|
|
323
320
|
case DataConnectorType.FILE:
|
|
324
321
|
path = overrides.get('path') or getattr(target_obj, 'path', None)
|
|
325
322
|
fmt = overrides.get('format') or getattr(
|
|
@@ -357,8 +354,8 @@ def run(
|
|
|
357
354
|
)
|
|
358
355
|
result = load(data, 'database', str(conn))
|
|
359
356
|
case _:
|
|
360
|
-
#
|
|
361
|
-
#
|
|
357
|
+
# :meth:`coerce` already raises for invalid connector types, but
|
|
358
|
+
# keep explicit guard for defensive programming.
|
|
362
359
|
raise ValueError(f'Unsupported target type: {ttype_raw}')
|
|
363
360
|
|
|
364
361
|
# Return the terminal load result directly; callers (e.g., CLI) can wrap
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
etlplus/__init__.py,sha256=M2gScnyir6WOMAh_EuoQIiAzdcTls0_5hbd_Q6of8I0,1021
|
|
2
2
|
etlplus/__main__.py,sha256=btoROneNiigyfBU7BSzPKZ1R9gzBMpxcpsbPwmuHwTM,479
|
|
3
3
|
etlplus/__version__.py,sha256=1E0GMK_yUWCMQFKxXjTvyMwofi0qT2k4CDNiHWiymWE,327
|
|
4
|
-
etlplus/enums.py,sha256=
|
|
5
|
-
etlplus/extract.py,sha256=
|
|
6
|
-
etlplus/
|
|
7
|
-
etlplus/load.py,sha256=R_y0_vtsEo1bwxWVQu2bfhB5ZIJoIoWu2ycCdvY4RnE,8737
|
|
4
|
+
etlplus/enums.py,sha256=WyxpUEUPdYdXlueKDXGaSEo7o9OqCXyzjDOOPqmW8tw,8326
|
|
5
|
+
etlplus/extract.py,sha256=LOyL8_KCOaIGemTxSnKbN_ttfLWUljqT4OQxANe7G3k,6089
|
|
6
|
+
etlplus/load.py,sha256=aufl-2CpuI_J1hKBY1uFsoVf9Gfl9bKQjs233dYFf00,8631
|
|
8
7
|
etlplus/mixins.py,sha256=ifGpHwWv7U00yqGf-kN93vJax2IiK4jaGtTsPsO3Oak,1350
|
|
9
8
|
etlplus/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
|
-
etlplus/run.py,sha256=
|
|
9
|
+
etlplus/run.py,sha256=FjcMF56HUbSw2PAvB_dZWP-xTFP-Pa_QLYTsrjmFurw,12262
|
|
11
10
|
etlplus/run_helpers.py,sha256=bj6MkaeFxjl3CeKG1HoXKx5DwAlXNERVW-GX-z1P_qQ,24373
|
|
12
11
|
etlplus/transform.py,sha256=uAUVDDHYCgx7GpVez9IK3OAZM-CnCuMa9iox3vwGGJA,25296
|
|
13
12
|
etlplus/types.py,sha256=1hsDlnF6r76zAwaUYay-i6pCM-Y0IU5nP7Crj8PLCQ4,6157
|
|
@@ -31,10 +30,10 @@ etlplus/api/rate_limiting/__init__.py,sha256=ZySB1dZettEDnWvI1EHf_TZ9L08M_kKsNR-
|
|
|
31
30
|
etlplus/api/rate_limiting/config.py,sha256=2b4wIynblN-1EyMqI4aXa71SljzSjXYh5N1Nngr3jOg,9406
|
|
32
31
|
etlplus/api/rate_limiting/rate_limiter.py,sha256=Uxozqd_Ej5Lsj-M-mLT2WexChgWh7x35_YP10yqYPQA,7159
|
|
33
32
|
etlplus/cli/__init__.py,sha256=J97-Rv931IL1_b4AXnB7Fbbd7HKnHBpx18NQfC_kE6c,299
|
|
34
|
-
etlplus/cli/commands.py,sha256=
|
|
35
|
-
etlplus/cli/constants.py,sha256=
|
|
33
|
+
etlplus/cli/commands.py,sha256=g8_m3A8HEMyTRu2HctNiRoi2gtB5oSZCUEcyq-PIXos,24669
|
|
34
|
+
etlplus/cli/constants.py,sha256=E6Uy4WauLa_0zkzxqImXh-bb1gKdb9sBZQVc8QOzr2Q,1943
|
|
36
35
|
etlplus/cli/handlers.py,sha256=K0GazvrPgocJ-63HZqF0xhyJk8TB1Gcj-eIbWltXKRU,17759
|
|
37
|
-
etlplus/cli/io.py,sha256=
|
|
36
|
+
etlplus/cli/io.py,sha256=EFaBPYaBOyOllfMQWXgTjy-MPiGfNejicpD7ROrPyAE,7840
|
|
38
37
|
etlplus/cli/main.py,sha256=IgeqxypixfwLHR-QcpgVMQ7vMZ865bXOh2oO9v-BWeM,5234
|
|
39
38
|
etlplus/cli/options.py,sha256=vfXT3YLh7wG1iC-aTdSg6ItMC8l6n0Lozmy53XjqLbA,1199
|
|
40
39
|
etlplus/cli/state.py,sha256=Pfd8ru0wYIN7eGp1_A0tioqs1LiCDZCuJ6AnjZb6yYQ,8027
|
|
@@ -42,24 +41,31 @@ etlplus/cli/types.py,sha256=tclhKVJXDqHzlTQBYKARfqMgDOcuBJ-Zej2pvFy96WM,652
|
|
|
42
41
|
etlplus/config/__init__.py,sha256=VZWzOg7d2YR9NT6UwKTv44yf2FRUMjTHynkm1Dl5Qzo,1486
|
|
43
42
|
etlplus/config/connector.py,sha256=0-TIwevHbKRHVmucvyGpPd-3tB1dKHB-dj0yJ6kq5eY,9809
|
|
44
43
|
etlplus/config/jobs.py,sha256=hmzRCqt0OvCEZZR4ONKrd3lvSv0OmayjLc4yOBk3ug8,7399
|
|
45
|
-
etlplus/config/pipeline.py,sha256=
|
|
44
|
+
etlplus/config/pipeline.py,sha256=m4Jh0ctFcKrIx6zR7LEC0sYY5wq0o8NqOruWPlz6qmA,9494
|
|
46
45
|
etlplus/config/profile.py,sha256=Ss2zedQGjkaGSpvBLTD4SZaWViMJ7TJPLB8Q2_BTpPg,1898
|
|
47
46
|
etlplus/config/types.py,sha256=a0epJ3z16HQ5bY3Ctf8s_cQPa3f0HHcwdOcjCP2xoG4,4954
|
|
48
47
|
etlplus/config/utils.py,sha256=4SUHMkt5bKBhMhiJm-DrnmE2Q4TfOgdNCKz8PJDS27o,3443
|
|
49
48
|
etlplus/database/__init__.py,sha256=AKJsDl2RHuRGPS-eXgNJeh4aSncJP5Y0yLApBF6i7i8,1052
|
|
50
|
-
etlplus/database/ddl.py,sha256=
|
|
49
|
+
etlplus/database/ddl.py,sha256=CKrxGWGKkick--AnUUzBRGpH30f4h8RuE3JXOLg420o,7923
|
|
51
50
|
etlplus/database/engine.py,sha256=7rr7YndA8LwyWJL8k1YhQbqxxmW4gWEUQjp0NwQcYtc,4061
|
|
52
51
|
etlplus/database/orm.py,sha256=gCSqH-CjQz6tV9133-VqgiwokK5ylun0BwXaIWfImAo,10008
|
|
53
52
|
etlplus/database/schema.py,sha256=HNTgglI8qvQLInr7gq--2lLmLKHzAZTL2MJUOIw9DlY,7025
|
|
54
53
|
etlplus/database/types.py,sha256=_pkQyC14TzAlgyeIqZG4F5LWYknZbHw3TW68Auk7Ya0,795
|
|
54
|
+
etlplus/file/__init__.py,sha256=X03bosSM-uSd6dh3ur0un6_ozFRw2Tm4PE6kVUjtXK8,475
|
|
55
|
+
etlplus/file/core.py,sha256=NXTGSIKIo7HvLDlMtme37_d4NUhsf4RUNKp5mTj-wqU,8131
|
|
56
|
+
etlplus/file/csv.py,sha256=VbMW_NaqCw03HlfvYzb9MoAgCXI3cl9qc4dASkTHoyw,1880
|
|
57
|
+
etlplus/file/enums.py,sha256=rwrbwj6PejG0c5v6jzcsmeNu9cSqDyWB1foIuM5UyJo,6648
|
|
58
|
+
etlplus/file/json.py,sha256=xSV5PkZ_tZQuZNdLr1FQUwuCQXyL7Ch3WRJ3hkw0p68,1911
|
|
59
|
+
etlplus/file/xml.py,sha256=vjate5u9Z26LPlpvZsdzpqXsIUZRgen7oHa3ly-aIhs,3905
|
|
60
|
+
etlplus/file/yaml.py,sha256=6KaWoG7oYB26EHX2TZ7LOgigO11Hoq3MH--adFq_Eck,3004
|
|
55
61
|
etlplus/templates/__init__.py,sha256=tsniN7XJYs3NwYxJ6c2HD5upHP3CDkLx-bQCMt97UOM,106
|
|
56
62
|
etlplus/templates/ddl.sql.j2,sha256=s8fMWvcb4eaJVXkifuib1aQPljtZ8buuyB_uA-ZdU3Q,4734
|
|
57
63
|
etlplus/templates/view.sql.j2,sha256=Iy8DHfhq5yyvrUKDxqp_aHIEXY4Tm6j4wT7YDEFWAhk,2180
|
|
58
64
|
etlplus/validation/__init__.py,sha256=Pe5Xg1_EA4uiNZGYu5WTF3j7odjmyxnAJ8rcioaplSQ,1254
|
|
59
65
|
etlplus/validation/utils.py,sha256=Mtqg449VIke0ziy_wd2r6yrwJzQkA1iulZC87FzXMjo,10201
|
|
60
|
-
etlplus-0.
|
|
61
|
-
etlplus-0.
|
|
62
|
-
etlplus-0.
|
|
63
|
-
etlplus-0.
|
|
64
|
-
etlplus-0.
|
|
65
|
-
etlplus-0.
|
|
66
|
+
etlplus-0.11.5.dist-info/licenses/LICENSE,sha256=MuNO63i6kWmgnV2pbP2SLqP54mk1BGmu7CmbtxMmT-U,1069
|
|
67
|
+
etlplus-0.11.5.dist-info/METADATA,sha256=XQIXTX24poFjhrvKi2PduG8esQF5fGuu6rxVjLuBLc8,21036
|
|
68
|
+
etlplus-0.11.5.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
69
|
+
etlplus-0.11.5.dist-info/entry_points.txt,sha256=6w-2-jzuPa55spzK34h-UKh2JTEShh38adFRONNP9QE,45
|
|
70
|
+
etlplus-0.11.5.dist-info/top_level.txt,sha256=aWWF-udn_sLGuHTM6W6MLh99ArS9ROkUWO8Mi8y1_2U,8
|
|
71
|
+
etlplus-0.11.5.dist-info/RECORD,,
|