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.15.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | a7e60070007d7a3cc4fe3da36894da89dc58cdb9c013d355490622db30e6967a |
|
MD5 | 8fbe2f96f093631f74a0f91b63334394 |
|
BLAKE2b-256 | 7c39aa39b2ebf978e77ec995f73576ad0507b463ac7e1027b5479131a51bf841 |
Close
Hashes for common_harness_lib-0.0.15-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e0afa63101fa466748512cb035b111bad9330673e61a49f47d7978cafc825066 |
|
MD5 | 7cfccd11bd644fbd27a7a844ca7ed1bc |
|
BLAKE2b-256 | cd03bc016c1ea3a4743d03d869b06b680ac837db575676dff1330cdea6a86523 |