dbtk 0.8.1__tar.gz → 0.8.2__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.
Files changed (70) hide show
  1. {dbtk-0.8.1 → dbtk-0.8.2}/PKG-INFO +1 -1
  2. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/__init__.py +1 -1
  3. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/cli.py +2 -1
  4. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/table.py +1 -1
  5. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/readers/fixed_width.py +2 -2
  6. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/writers/base.py +2 -2
  7. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/writers/xml.py +1 -1
  8. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk.egg-info/PKG-INFO +1 -1
  9. {dbtk-0.8.1 → dbtk-0.8.2}/pyproject.toml +5 -1
  10. {dbtk-0.8.1 → dbtk-0.8.2}/LICENSE.txt +0 -0
  11. {dbtk-0.8.1 → dbtk-0.8.2}/README.md +0 -0
  12. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/config.py +0 -0
  13. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/cursors.py +0 -0
  14. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/database.py +0 -0
  15. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/dbtk_sample.yml +0 -0
  16. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/defaults.py +0 -0
  17. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/__init__.py +0 -0
  18. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/base_surge.py +0 -0
  19. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/bulk_surge.py +0 -0
  20. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/config_generators.py +0 -0
  21. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/data_surge.py +0 -0
  22. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/managers.py +0 -0
  23. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/transforms/__init__.py +0 -0
  24. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/transforms/address.py +0 -0
  25. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/transforms/core.py +0 -0
  26. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/transforms/database.py +0 -0
  27. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/transforms/datetime.py +0 -0
  28. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/transforms/email.py +0 -0
  29. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/etl/transforms/phone.py +0 -0
  30. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/formats/__init__.py +0 -0
  31. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/formats/edi.py +0 -0
  32. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/logging_utils.py +0 -0
  33. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/readers/__init__.py +0 -0
  34. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/readers/base.py +0 -0
  35. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/readers/csv.py +0 -0
  36. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/readers/data_frame.py +0 -0
  37. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/readers/excel.py +0 -0
  38. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/readers/json.py +0 -0
  39. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/readers/utils.py +0 -0
  40. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/readers/xml.py +0 -0
  41. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/record.py +0 -0
  42. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/utils.py +0 -0
  43. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/writers/__init__.py +0 -0
  44. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/writers/csv.py +0 -0
  45. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/writers/database.py +0 -0
  46. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/writers/excel.py +0 -0
  47. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/writers/fixed_width.py +0 -0
  48. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/writers/json.py +0 -0
  49. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk/writers/utils.py +0 -0
  50. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk.egg-info/SOURCES.txt +0 -0
  51. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk.egg-info/dependency_links.txt +0 -0
  52. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk.egg-info/entry_points.txt +0 -0
  53. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk.egg-info/requires.txt +0 -0
  54. {dbtk-0.8.1 → dbtk-0.8.2}/dbtk.egg-info/top_level.txt +0 -0
  55. {dbtk-0.8.1 → dbtk-0.8.2}/setup.cfg +0 -0
  56. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_bulk.py +0 -0
  57. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_config.py +0 -0
  58. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_data_bending.py +0 -0
  59. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_edi_writer.py +0 -0
  60. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_excel_writer.py +0 -0
  61. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_fixed_width_record.py +0 -0
  62. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_logging_utils.py +0 -0
  63. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_readers.py +0 -0
  64. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_table.py +0 -0
  65. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_table_new_features.py +0 -0
  66. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_transforms_core.py +0 -0
  67. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_transforms_datetime.py +0 -0
  68. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_transforms_phone.py +0 -0
  69. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_validation_collector.py +0 -0
  70. {dbtk-0.8.1 → dbtk-0.8.2}/tests/test_writers.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dbtk
3
- Version: 0.8.1
3
+ Version: 0.8.2
4
4
  Summary: Data Benders Toolkit - A lightweight toolkit for data integration, ELT and ETL
5
5
  Author: Scott Bailey <scottrbailey@gmail.com>
6
6
  License: MIT
@@ -36,9 +36,9 @@ from .database import Database
36
36
  from .config import connect, set_config_file
37
37
  from .cursors import Cursor
38
38
  from .logging_utils import setup_logging, cleanup_old_logs, errors_logged
39
- from . import etl
40
39
  from . import readers
41
40
  from . import writers
41
+ from . import etl
42
42
 
43
43
  # Simple, clean exports
44
44
  __all__ = [
@@ -114,7 +114,8 @@ def checkup():
114
114
 
115
115
  def main():
116
116
  parser = argparse.ArgumentParser(prog='dbtk', description='DBTK command-line utilities')
117
- subparsers = parser.add_subparsers(dest='command', required=True)
117
+ subparsers = parser.add_subparsers(dest='command')
118
+ subparsers.required = True # required= kwarg not supported in Python 3.6
118
119
 
119
120
  # checkup
120
121
  subparsers.add_parser('checkup', help='Check for dependencies and configuration issues')
@@ -63,7 +63,7 @@ class Table:
63
63
  'user_id': {'default': lambda: conf_vars['user_id']},
64
64
  }
65
65
 
66
- * **fn** (callable | list[callable] | str, optional):
66
+ * **fn** (Union[callable, List[callable], str], optional):
67
67
  Transformation function(s) to apply to the source value.
68
68
  callable: applied directly; list: functions applied in order (pipeline);
69
69
  str: magic shorthand (e.g. 'int', 'maxlen:255', 'lookup:table:col:val').
@@ -4,7 +4,7 @@
4
4
 
5
5
  import logging
6
6
  import os
7
- from typing import TextIO, List, Dict, Any, Optional, Iterator
7
+ from typing import TextIO, List, Dict, Any, Optional, Iterator, Type
8
8
 
9
9
  from .base import Reader
10
10
  from ..record import Record, FixedWidthRecord
@@ -271,7 +271,7 @@ class EDIReader(FixedReader):
271
271
  def _get_columns(self, type_code: str) -> List[FixedColumn]:
272
272
  return self.columns.get(type_code)
273
273
 
274
- def _get_factory(self, type_code: str) -> type[Record]:
274
+ def _get_factory(self, type_code: str) -> Type[Record]:
275
275
  if type_code not in self._type_factories:
276
276
  cols = self._get_columns(type_code)
277
277
  if cols is None:
@@ -181,7 +181,7 @@ class BaseWriter(ABC):
181
181
 
182
182
  Returns
183
183
  -------
184
- tuple[Union[TextIO, BinaryIO], bool]
184
+ Tuple[Union[TextIO, BinaryIO], bool]
185
185
  (file_handle, should_close_flag)
186
186
  """
187
187
  if self.file is None:
@@ -280,7 +280,7 @@ class BaseWriter(ABC):
280
280
 
281
281
  Returns
282
282
  -------
283
- tuple[Optional[Iterator], Optional[List[str]]]
283
+ Tuple[Optional[Iterator], Optional[List[str]]]
284
284
  (iterator, column_names)
285
285
  """
286
286
  if not data:
@@ -207,7 +207,7 @@ class XMLStreamer(BatchWriter):
207
207
 
208
208
  Returns
209
209
  -------
210
- tuple[BinaryIO, bool]
210
+ Tuple[BinaryIO, bool]
211
211
  (file_handle, should_close_flag)
212
212
 
213
213
  Raises
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dbtk
3
- Version: 0.8.1
3
+ Version: 0.8.2
4
4
  Summary: Data Benders Toolkit - A lightweight toolkit for data integration, ELT and ETL
5
5
  Author: Scott Bailey <scottrbailey@gmail.com>
6
6
  License: MIT
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "dbtk"
7
- version = "0.8.1"
7
+ version = "0.8.2"
8
8
  description = "Data Benders Toolkit - A lightweight toolkit for data integration, ELT and ETL"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.6"
@@ -78,5 +78,9 @@ Homepage = "https://github.com/scottrbailey/dbtk"
78
78
  Documentation = "https://dbtk.readthedocs.io"
79
79
  Repository = "https://github.com/scottrbailey/dbtk.git"
80
80
 
81
+ [tool.setuptools.packages.find]
82
+ where = ["."]
83
+ include = ["dbtk*"]
84
+
81
85
  [tool.setuptools.package-data]
82
86
  dbtk = ["dbtk_sample.yml"]
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes