-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Alexander Saff
committed
Nov 16, 2020
1 parent
994e1d4
commit 4e2a56f
Showing
6 changed files
with
40 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
Metadata-Version: 2.1 | ||
Name: dataEng-container-tools | ||
Version: 0.1.8 | ||
Version: 0.1.9 | ||
Summary: A package containing tools for data engineering containers. | ||
Home-page: https://github.com/colpal/dataEng-container-tools | ||
Author: Alexander Saff | ||
Author-email: [email protected] | ||
License: UNKNOWN | ||
Description: # Data Engineering Container Tools | ||
|
||
This packages is split into three parts: **CLA**, **GCS**, and **safe_stdout**. | ||
This packages is split into four parts: **CLA**, **GCS**, **safe_stdout**, and **simple_setup**. | ||
|
||
## CLA: | ||
Deals with receiving input from the command line. Has three classes: `custom_command_line_argument`, `command_line_argument_type`, and `command_line_arguments`. | ||
|
@@ -106,7 +106,7 @@ Description: # Data Engineering Container Tools | |
* `default_secret_folder`: Variable containing the folder in which secrets are injected by default. Currently set to `'/vault/secrets/'`. | ||
|
||
## Example: | ||
An example workflow might look something like this: | ||
An example workflow using the classes above might look something like this: | ||
``` | ||
from dataEng_container_tools.cla import command_line_arguments, command_line_argument_type | ||
from dataEng_container_tools.gcs import gcs_file_io | ||
|
@@ -126,6 +126,19 @@ Description: # Data Engineering Container Tools | |
result = file_io.upload_file_from_object(gcs_uri=output_uris[0], object_to_upload=pqt_obj) | ||
``` | ||
|
||
## simple_setup: | ||
A simple way to get input from the command line, and download and upload documents to/from GCS. Fewer options than the classes above but also fewer lines of code to write. A brief example (documentation to come): | ||
``` | ||
from dataEng_container_tools.simple_setup import simple_setup | ||
simple = simple_setup(['input_left', 'input_right', 'output_inner', 'output_outer', 'secret_location', 'example_flag']) | ||
objects = simple.get_input_objects() | ||
# | ||
# Edit the objects in some way here. | ||
# | ||
return_objs = {'output_outer': objects['input_left'], 'output_inner': objects['input_right']} | ||
upload = simp.upload_objects(return_objs) | ||
``` | ||
|
||
Platform: UNKNOWN | ||
Classifier: Programming Language :: Python :: 3 | ||
Classifier: License :: OSI Approved :: MIT License | ||
|
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ | |
|
||
setuptools.setup( | ||
name="dataEng-container-tools", | ||
version="0.1.8", | ||
version="0.1.9", | ||
author="Alexander Saff", | ||
author_email="[email protected]", | ||
description="A package containing tools for data engineering containers.", | ||
|