torrent
torrent copied to clipboard
Ignore malformed (optional) fields in metainfo.Load
Some torrents sites could generate malformed torrent file. I personally encountered that the private tracker site aidoru-online generates torrents with malformed "announce-list" fields: it incorrectly uses the comma-seperated trackers joined string instead of using the Bencode list structure.
Bittorrent clients such as qBittorrent silently ignore such malformed announce-list whening adding those torrents, and fallback to use "announce" field as tracker.
Currently, metainfo.Load return err if failed to parse any field. It will be helpful that it is be able to ignore parsing error of some optional / non-fatal fields, and still return the parsed result of other fields in such case.