Torf

Latest version: v4.2.7

Safety actively analyzes 693883 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 7 of 10

1.4

- New method: calculate_piece_size()
- Piece size is now automatically calculated when path is set instead of
calculating it on demand when requested
- Setting piece size to a non-number now raises ValueError instead of
RuntimeError
- Exclude patterns are now matched against every part of a file's path, not
just the last part (i.e. the file name)
- Setting torrent.path to '.' or '..' now sets the correct name
- Torrent instances are equal (==) if their metainfo is equal
- Torrent instances are hashable
- Torrent instances can be copied with the copy() method or the copy module
from the standard library

1.3

- Fix 'filepaths' attribute when setting a custom name

1.2

- Don't leave an empty file when calling write() on an invalid torrent

1.1

- Major rewrite with lots of tests that should fix the most obvious bugs
- The options --source and --nosource have been removed
- The option --nocreator has been added
- Output is now easier to parse when stdout is not a TTY (e.g. when piping to
grep, cut, awk, etc)

1.0

Final release

1.0rc5

- Fixed a bug where overwriting a torrent file resulted in corrupt torrent
- Added property 'pieces' that returns the number of pieces
- Added property 'filetree' that can be used to create a beautiful tree of a
torrent's content
- Added property 'is_ready' that is True when torrent can be exported
- When reading torrent files, don't read large files all the way to EOF before
failing
- All exceptions now have an 'errno' attribute (see 'errno' module)

Page 7 of 10

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.