summaryrefslogtreecommitdiff
path: root/server/szurubooru/func/posts.py
AgeCommit message (Collapse)Author
2024-12-07server+client: use safety rating param in "lookalikes" apiHunternif
2022-10-02client,server: reverse search post by signatureHunternif
2021-08-04Merge branch 'master' into hunternifHunternif
2021-08-04Merge remote-tracking branch 'origin/master' into hunternifHunternif
# Conflicts: # client/css/post-content-control.styl # client/css/post-list-view.styl # client/html/post_edit_sidebar.tpl # client/js/controllers/post_list_controller.js # client/js/controllers/post_main_controller.js # client/js/controllers/post_upload_controller.js # client/js/controllers/tag_controller.js # client/js/controllers/user_list_controller.js # client/js/controls/expander_control.js # client/js/controls/post_content_control.js # client/js/controls/post_edit_sidebar_control.js # client/js/controls/post_readonly_sidebar_control.js # client/js/controls/tag_input_control.js # client/js/main.js # client/js/models/abstract_list.js # client/js/models/post.js # client/js/models/post_list.js # client/js/models/settings.js # client/js/models/tag.js # client/js/models/tag_list.js # client/js/tags.js # client/js/util/search.js # client/js/util/touch.js # client/js/util/uri.js # client/js/util/views.js # client/js/views/post_main_view.js # client/js/views/post_upload_view.js # client/js/views/posts_header_view.js # client/js/views/posts_page_view.js # client/js/views/settings_view.js # client/js/views/tag_view.js # client/package-lock.json # client/package.json # server/config.yaml.dist # server/szurubooru/api/__init__.py # server/szurubooru/api/post_api.py # server/szurubooru/api/tag_api.py # server/szurubooru/func/posts.py # server/szurubooru/func/tags.py # server/szurubooru/model/__init__.py # server/szurubooru/model/post.py # server/szurubooru/model/tag.py # server/szurubooru/search/configs/__init__.py # server/szurubooru/search/configs/post_search_config.py # server/szurubooru/search/executor.py # server/szurubooru/tests/api/test_post_retrieving.py # server/szurubooru/tests/api/test_post_updating.py # server/szurubooru/tests/api/test_tag_updating.py # server/szurubooru/tests/conftest.py # server/szurubooru/tests/func/test_posts.py # server/szurubooru/tests/func/test_tags.py # server/szurubooru/tests/search/configs/test_post_search_config.py
2021-05-07Add AVIF/HEIC detectionRuin0x11
ffmpeg doesn't support HEIC decoding yet...
2021-01-05server/posts: store and provide MD5 checksumsShyam Sunder
2020-09-19server/pools: serialize pools as micro resource within post resourcesShyam Sunder
Fixes #348
2020-06-06client+server: implement code autoformatting using prettier and blackShyam Sunder
2020-06-05server: format code to flake8Shyam Sunder
2020-06-03fix python lint issuesShyam Sunder
2020-06-02PR fixesRuin0x11
2020-05-04Add pool input box in post detailsRuin0x11
2020-05-04Add list of posts to poolsRuin0x11
2020-03-21server/posts/upload: edit default flag behaviorShyam Sunder
The 'loop' flag will be auto-selected by default on video posts if the flags parameter is undefined when creating a new post.
2020-03-13server/func/image_hash: added docstrings to functionsShyam Sunder
2020-03-13server/image_search: add migrations for elasticsearch removalShyam Sunder
2020-03-13server/image_search: implement reverse search functionality in postgresShyam Sunder
This will remove the dependency on the Elasticsearch database. The search query is passed currently as raw SQL. Proper implementation using SQLAlchemy will need custom ORM classed to be made. Additional config parameter "allow_broken_uploads" has been added.
2020-03-06server/tests: use postgresql test databaseShyam Sunder
2020-01-12server/func/posts: explicity specify MD5 for post security hashShyam Sunder
2019-04-25Merge branch 'master' into hunternifIlya Tetin
2019-04-22server/model/posts: Make post flags a hybrid attribute in modelShyam Sunder
This should (hopefully) fix #250 and #252
2019-04-19server: serialize post metrics and metric ranges in postIlya Tetin
2019-02-11server/func/posts: fix #221Shyam Sunder
2018-12-22server/func/posts: transfer flags on mergeShyam Sunder
2018-09-24server/posts: automatically detect sound in video post uploadsShyam Sunder
2018-09-24server/search: allow searching by post flagsShyam Sunder
2018-09-24server+client: added sound flag to video postsShyam Sunder
2018-03-08server/posts: deleting a post purges its artifactsReAnzu
Specifically, its thumbnail and post source.
2018-03-08server/posts: auto convert GIFs to WEBMs/MP4sReAnzu
- Default setting is false for both conversions, as this will require additional resources of the server, but is bandwidth friendly for viewers - WEBM conversion is slow, but better quality than MP4 conversion with a typically smaller file size - Tags are copied over from the original upload - Snapshots are generated for the new auto posts
2017-10-01remove tags.jsonrr-
2017-08-24server/posts: add non-guessable IDs to post URLsrr-
2017-04-24server: lintrr-
2017-03-12server/posts: ignore old elasticsearch resultsrr-
2017-02-05server: refactor + add type hintingrr-
- Added type hinting (for now, 3.5-compatible) - Split `db` namespace into `db` module and `model` namespace - Changed elastic search to be created lazily for each operation - Changed to class based approach in entity serialization to allow stronger typing - Removed `required` argument from `context.get_*` family of functions; now it's implied if `default` argument is omitted - Changed `unalias_dict` implementation to use less magic inputs
2017-02-03server: make linters happierrr-
2017-02-03server/image-hash: do not depend on image-matchrr-
While I hold this library in great esteem for its excellent work on implementing the original paper, I have several problems with it: - as of this commit, it (again) has bug fixes unreleased on pip - its code is badly structured - forces OOP and then proceeds @staticmethod everything - bad class design, parameters are repeated in several places - terrible contract of make_record() and generate_signature() - ambiguous parameters: path vs. image path vs. image content - doesn't adhere to PEP-8 - depends on cairo just to render svg images almost no one uses this library with
2017-02-02server/posts: fix reverse search late evaluationrr-
Uploading webms caused 'Not an image.' error to be shown, cause generators are evaluated lazily, so the `catch` never worked.
2017-02-02server/posts: reduce warnings from sqlalchemyrr-
...regarding empty IN() statements
2017-01-25server/posts: fix handling corrupt filesrr-
In case of a ProcessingError, the image dimensions are set to None. But after that, they are compared with 0, which resulted in a TypeError.
2017-01-07server/posts: change reverse image search APIrr-
Add exact duplicates search; refactor to use classes over dictionaries
2017-01-03server/posts: fix post relationsrr-
Trying to relate post to itself resulted in 500 ISE.
2016-12-26server/image-hash: add image search enginerr-
2016-10-22server/tags: merge also tag relationsrr-
2016-10-21server/posts: add replaceContent to post mergingrr-
2016-10-21server/posts: add post mergingrr-
2016-10-02server/posts: fix relation updatingrr-
Fixes #103
2016-09-10server/posts: report duplicate post ID and URLrr-
2016-08-26server/posts: defer flush; save content lazilyrr-
Rather than flushing the post right away only to find out that there were validation errors, try to postpone flushing for as long as possible. The previous behavior has led to too eager spending of post IDs - each flush calls nextval(post_id_seq), and postgres sequences are not affected by transaction rollbacks, so each erroneous post creation discarded a post ID, which has led to gaps in post IDs.
2016-08-20server/posts: use SHA1 checksumsrr-
This changes the checksums to ones that are compatible with 1.x, which relieves the migration script from recalculating the checksums for all the posts.
2016-08-16server/snapshots: rewriterr-