1
0
Fork 0
mirror of https://github.com/ProjectSynthoria/SynthoriaArchive.git synced 2025-03-12 15:26:56 +02:00
Commit graph

21 commits

Author SHA1 Message Date
f3031cd480
Updated for NyaaV3 2025-03-02 15:08:58 +02:00
Anna-Maria Meriniemi
4fe0ff5b1a
Optimize magnet generation (#594)
with our trusty tool: caching!
2020-07-12 00:14:35 -07:00
TheAMM
bf090c0fab torrents: clean up & optimize magnets further
Removes the specialized template ES magnet creator, since create_magnet()
can use both Torrents and ES objects. Search results will get the
properly escaped magnets, now.
Slightly optimizes the tracker adding and string joins.
RIP base32, wonder how many bad clients will break with sha1.
2018-07-21 22:06:58 +03:00
Tadeo Kondrak
ef7ff1b9ce Add torrent counter on profile page (#409) (#513) 2018-07-17 14:52:54 +03:00
TheAMM
2bf96196cb torrents: Clean up magnet URI quotation
A cosmetic change.
Swapping quote_via to quote, we don't convert spaces to pluses, keeping
the name intact (which only mattered until peers send the metadata).
2018-07-15 04:40:07 +03:00
Anna-Maria Meriniemi
e5fe63156d Fix flat PR (#446)
* Clean up PR #349 

- Rely on os.makedirs(..., exist_ok=True) for "thread"-safety

- Remove the previous info_dict when we know the transaction went through.

- bytes.hex() will always be lowercase (unless we go off CPython):
c3d9508ff2/Python/pystrhex.c (L5-L49)
c3d9508ff2/Python/codecs.c (L16)

- Reintroduce comments and meaningful creation dates in generated torrents:
Also make create_default_metadata_base set the correct metadata now
2018-02-04 13:56:29 +01:00
nyaadev
fd0a02b95c Move bencoded info dicts from mysql torrent_info table to info_dict directory. DB change!
IMPORTANT!!! Make sure to run utils/infodict_mysql2file.py before upgrading the database.
2018-02-02 20:39:02 +01:00
Anna-Maria Meriniemi
5990cf2f50 Remove tracker limit and always add our trackers (#417)
With all trackers.txt trackers being included in generated .torrents,
we can now be certain the magnet (which use trackers.txt) and the .torrent
uses will not be split up in different swarms in case the main announce dies.
(That is, if uploaders add enough of their own trackers and additional trackers
were deemed unnecessary (at least 5 already), the magnet and .torrent would only
share the main site announce)
2017-11-22 00:02:22 -08:00
Kfir Hadas
87dd95f1e0 Refactor into an app factory [2 of 2] (#322)
* Replace all `from nyaa import app` imports with `app = flask.current_app` (or `from flask import current_app as app` where possible)
* Add a separate config object for top-level and class statements as `nyaa.extensions.config`
Required because those codes don't have app context at the time of evaluation/execution.
* Remove `routes.py` file and register all blueprints in `nyaa/__init__.py`
* Refactor `nyaa/__init__.py` into an app factory
* Update tools
* Update tests (temporary, will be replaced)
2017-08-01 21:02:08 +03:00
Kfir Hadas
0181d6cb33 Prepare for app factory [1 of 2] (#315)
* Move db, assets, debug toolbar and fix_paginate into nyaa.extensions
* Change all `from nyaa import db` imports to `from nyaa.extensions import db`
* Move `nyaa.torrents.create_magnet_from_es_info` context processor into template-utils blueprint
* Fix tools (wrap in `with app.app_context():` where needed)
2017-07-30 20:35:16 +03:00
Anna-Maria Meriniemi
1bc36c5a17 [Schema change] Add webseed support (BEP-19) (#317)
Store webseeds in Trackers table with is_webseed flag
Adjusts torrent creation accordingly
2017-07-30 00:00:39 +03:00
Kfir Hadas
b992467dad Apply isort & flake8 (#312)
* Update isort settings
* Apply import sorting (isort) on all files in nyaa/
* Fixed Flake8 errors in nyaa/ (see PR for list)
* Add isort to lint.sh and requirements.txt
2017-07-28 20:01:19 +03:00
aldacron
142dd5359c Resolves #129 and refactored create magnet es naming 2017-05-24 23:19:08 -07:00
nyaadev
b7144f80f9 Make comments great again. 2017-05-22 23:38:06 +02:00
TheAMM
1e230584ab Re-add generated torrent tracker count limit
As found out in #164, this feature disappeared somewhere along the line.
2017-05-22 23:59:21 +03:00
Kfir Hadas
4e9409fb30 AutoPEP8 (after elasticsearch merge) 2017-05-16 12:47:06 +03:00
aldacron
00c768c722 merged elasticsearch, let's hope this doesn't break shit 2017-05-16 01:28:55 -07:00
aldacron
2005174358 finished up rss, changed rss behavior to include pre-defined trackers only, also cleaned up debug statements 2017-05-16 00:46:25 -07:00
TheAMM
16c30413dc Remove extra b'e' in torrent generation
Fixes #45
Flexget checks for trailing data after bdecoding, which most decoders don't do - so this went unnoticed.
2017-05-14 20:14:49 +03:00
nyaadev
7e25e6d9b8 Our main tracker first, then user trackers, then trackers.txt 2017-05-13 15:46:08 +02:00
nyaadev
00d65e312c Initial commit. 2017-05-12 20:51:49 +02:00