Helper package for H2H Task images.
Project description
common-harness-lib
[H2H Toolkit] Common python library for harness functions within task docker images.
Usage:
Create object with CommonHarnessLib()
. To disable s3 features, use the disable_s3=False
flag.
Methods:
- S3:
- handle_s3_exception(err: Exception): Handle's common s3 errors.
- get_object_content(bucket_name: str, object_key: str): Get's a s3 object content as a string.
- download_wordlists(wordlist_keys: List[str]): Downloads a list of wordlists from s3 and combines them as one file.
- System:
- run_command(command: List[str]): Run a command (i.e. ["echo", "hello world"])
- Validation:
- validate_dict({"firstname": str, "age": int}): Validates that a dict matches required type entries
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for common-harness-lib-0.0.14.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | ae28425964adc3940ac68021e36b8f93e148cf6c85e5ed74fffd238b62af3a16 |
|
MD5 | 9e9be2f7c27dbc5890cd78899141919f |
|
BLAKE2b-256 | 75184e4f69fd1653ccc08cb858e4de4ca93415be39ed768e097bcb231a534a51 |
Close
Hashes for common_harness_lib-0.0.14-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2e3a68eb43f2483ed39934c66024fbfe44c062b54a31610838e3f027c27fc243 |
|
MD5 | e682e30dded684484c01ac621e283ba0 |
|
BLAKE2b-256 | 3f70188cb819662f8bc1260c254d8edc5cc7bc9c28da10ef586b0df706f32319 |