Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What is the purpose of "id" field in parser/api_format ? #417

Open
antonsoroko opened this issue May 9, 2024 · 3 comments · May be fixed by #441
Open

What is the purpose of "id" field in parser/api_format ? #417

antonsoroko opened this issue May 9, 2024 · 3 comments · May be fixed by #441

Comments

@antonsoroko
Copy link
Contributor

antonsoroko commented May 9, 2024

What is the purpose of id field in parser/api_format ?
it was added here
5945e3d
but i do not see its usage even in old code.

@antonsoroko
Copy link
Contributor Author

also what is the purpose of key?
d748157

i also do not see its usage even in old code.

@elgatito
Copy link
Owner

@antonsoroko API format was added long time before me, in Quasar. I think there were few providers that had API interface.
https://bitbucket.org/scakemyer/script.quasar.burst/src/master/burst/providers/providers.json

@antonsoroko
Copy link
Contributor Author

antonsoroko commented Oct 2, 2024

@elgatito so key is used for "ncore" to get a special "key" for torrents download.
f264872#diff-a6e2a8aeb132492f997b788d8d527f0d01101d703968eec24b46724942cc8595R1591

but id field looks unused. it was added by you 3 years ago, but then i do not see any usage neither in burst or elementum.
for duplicates hash is used -

if not any(existing == hash_ for existing in hashes):

in elementum there is no such field for TorrentFile - https://github.com/elgatito/elementum/blame/master/bittorrent/torrent_file.go#L35

maybe it was supposed to be used to find duplicates, but then this idea was abandoned.
we can keep it or remove it. up to your liking.

UPD: for test i removed all lines added in the commit above - nothing changed in terms of search.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants