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.17.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2a47efbbb0b87e35cfae36051a85593e5f8ea3fe766eb9a413953890c7af5d36 |
|
MD5 | 9bf3f6a914d569c296cd1f024108b95b |
|
BLAKE2b-256 | 27a8084b399aa1f998d93b1f861ea5bd633eec4a16ce742f0e0d99fe62cdc3a1 |
Close
Hashes for common_harness_lib-0.0.17-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 92f9d6b10e2b10bcb00799236e934851f1ff34d0ad85b7aade5875478b742731 |
|
MD5 | 72fcf6281cd4f2256c0423320b447939 |
|
BLAKE2b-256 | 0f8bcfc8d8bb303e30f81a008c8771d1ab2998a3cdfc42a07a1fe25629b2af9c |