datatoolpack 0.7.2__tar.gz → 0.7.4__tar.gz

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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: datatoolpack
3
- Version: 0.7.2
3
+ Version: 0.7.4
4
4
  Summary: Official Python SDK for the AutoData ML data preparation pipeline API
5
5
  Home-page: https://autodata.datatoolpack.com
6
6
  Author: AutoData Team
@@ -1,4 +1,4 @@
1
1
  from .client import AutoDataClient, AutoDataError
2
2
 
3
- __version__ = "0.7.2"
3
+ __version__ = "0.7.4"
4
4
  __all__ = ["AutoDataClient", "AutoDataError", "__version__"]
@@ -445,8 +445,14 @@ class AutoDataClient:
445
445
  session_id: Session to download.
446
446
  download_path: Directory to save files (created if needed).
447
447
  Defaults to ``./auto_data_outputs/<session_id>/``.
448
- output_preferences: Subset of filenames to include. ``None``
449
- downloads everything.
448
+ output_preferences: Subset of outputs to include. ``None``
449
+ downloads everything. Each entry can be
450
+ either the full filename
451
+ (``'dsg_output.csv'``) or the short key
452
+ (``'dsg_output'``); the SDK appends ``.csv``
453
+ to extensionless entries automatically.
454
+ Use ``'pipeline_report'`` (or
455
+ ``'pipeline_report.pdf'``) for the PDF report.
450
456
  compressed: If ``True`` (default), downloads a single ZIP
451
457
  archive and extracts it. If ``False``,
452
458
  downloads each file individually.
@@ -463,7 +469,29 @@ class AutoDataClient:
463
469
  if compressed:
464
470
  body: Dict = {}
465
471
  if output_preferences:
466
- body["files"] = output_preferences
472
+ # Server <= 0.7.3 used exact filename match — a user passing
473
+ # the key-form name ('dsg_output' instead of 'dsg_output.csv')
474
+ # got back an empty archive. Server >= 0.7.4 accepts both
475
+ # forms, but to keep older deployments working we also
476
+ # canonicalize on the client: if an entry has no extension,
477
+ # append the conventional .csv (which is correct for every
478
+ # AutoData output except pipeline_report → .pdf and the
479
+ # *_artifacts.pkl files, which users rarely cherry-pick).
480
+ EXTENSIONLESS_DEFAULTS = {
481
+ "pipeline_report": "pipeline_report.pdf",
482
+ }
483
+ normalized = []
484
+ for item in output_preferences:
485
+ item = str(item).strip()
486
+ if not item:
487
+ continue
488
+ if "." in item:
489
+ normalized.append(item)
490
+ elif item in EXTENSIONLESS_DEFAULTS:
491
+ normalized.append(EXTENSIONLESS_DEFAULTS[item])
492
+ else:
493
+ normalized.append(f"{item}.csv")
494
+ body["files"] = normalized
467
495
  r = self._request(
468
496
  "POST",
469
497
  self._url(f"/download-archive/{session_id}"),
@@ -759,7 +787,7 @@ class AutoDataClient:
759
787
  ``kafka``, ``kinesis``.
760
788
 
761
789
  Generic:
762
- ``http`` (REST/HTTP API), ``mock`` (test).
790
+ ``http`` (REST/HTTP API).
763
791
  secrets: Inline connection secrets (e.g. connection_string,
764
792
  bucket, access keys).
765
793
  credential_id: ID of a saved credential on the server
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: datatoolpack
3
- Version: 0.7.2
3
+ Version: 0.7.4
4
4
  Summary: Official Python SDK for the AutoData ML data preparation pipeline API
5
5
  Home-page: https://autodata.datatoolpack.com
6
6
  Author: AutoData Team
@@ -7,7 +7,7 @@ with open(os.path.join(here, "README.md"), encoding="utf-8") as f:
7
7
 
8
8
  setup(
9
9
  name="datatoolpack",
10
- version="0.7.2",
10
+ version="0.7.4",
11
11
  description="Official Python SDK for the AutoData ML data preparation pipeline API",
12
12
  long_description=long_description,
13
13
  long_description_content_type="text/markdown",
File without changes
File without changes