(content:bytes)
| 51 | |
| 52 | @staticmethod |
| 53 | def is_readable(content:bytes)->bool: |
| 54 | allowed_bytes = set(range(32, 127)) | {10,13} | {241,243,250} |
| 55 | |
| 56 | for byte in content: |
| 57 | if byte not in allowed_bytes: |
| 58 | return False |
| 59 | return True |
| 60 | |
| 61 | def get_readable_content(content:bytes)->str: |
| 62 | text = "" |