Test files › Source code › mixed-indentation.py
Sample Python file (mixed indentation)
Python that mixes tab and space indentation inside one block, which the interpreter rejects.
↓ Download mixed-indentation.py| Filename | mixed-indentation.py |
| Format | Python |
| Size | 146 bytes (146 bytes) |
| MIME type | text/x-python; charset=utf-8 |
| SHA-256 | ebf668cedebc40c144d82aad5bc1b02c05697e8428db91faa23f44924b416c54 |
What this file catchesEditors, formatters and diff views that render tabs and spaces identically, so the file looks perfectly aligned on screen and still fails with TabError at import. Also any tool that strips or normalises whitespace on upload and changes what the code means.
Download & verify
curl -fsSL -o "mixed-indentation.py" "https://files.hexaqa.com/code/mixed-indentation.py"
curl -fsSL "https://files.hexaqa.com/code/mixed-indentation.py" | sha256sum
# expect: ebf668cedebc40c144d82aad5bc1b02c05697e8428db91faa23f44924b416c54