Disables all POSTs, optionally allowing users to log in (without updating last login date)
Blocked POSTs will redirect to the GET endpoint if possible, otherwise to referrer or in last case, home page.
API requests will get a plaintext message with 405 status code.
Index names are not necessarily named 'ix_table_column', so inspect the real schema for index names. Results are cached in memory.
(I have no clue how, but mine are prefixed idx_ instead of ix_!)
Clears out the "sort" variable naming as well.
MINIMUM_ANONYMOUS_TORRENT_SIZE can be used to require a minimum total
size of torrents uploaded by anonymous users (ie. without accounts).
Sets up a "framework" for post-WTForm torrent validation as well;
this can easily be extended into filename blacklists and such.
Add new tool for developing (lint/autopep8/isort/test)
New tool uses flake8 and isort for lint checks.
Deprecate existing tool (still works)
Update readme
Update Travis config
As per comments in #288, Firefox forces a "what do you want to do with this"-dialog for 'attachment' even when it's set to open them immediately in another program.
* 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)
url-list is supposed to be omitted in case of no webseeds,
but qB will instead use an empty bytestring '' as the value.
This commit makes the validation more lenient regarding url-list.
* Update Travis to Trusty Q2 (they fixed the issue it had before, it works now)
* Fix charset in database creation on Travis to use `utf8mb4_unicode_ci`.
* 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