read_archived_file

read_archived_file#

read_archived_file(archive_path: str | CloudPath | Path, regex: str) bytes[source]#

Read archived file (in bytes) from zip or tar archives.

You can use this site to build your regex.

Parameters:
  • archive_path (AnyPathStrType) – Archive path

  • regex (str) – Regex (used by re) as it can be found in the getmembers() list

Returns:

Archived file in bytes

Return type:

bytes