Commit Graph

940 Commits (a5d5e8e3b87134bdd99e9de9140f798a302b612c)

Author SHA1 Message Date
Aevann a5d5e8e3b8 Revert "remove hidevotedon"
This reverts commit d8cf302a43.
2023-03-15 07:22:13 +02:00
Aevann d8cf302a43 remove hidevotedon 2023-03-15 06:21:52 +02:00
Aevann 984aecec9a destroy the shadow realm (#135)
Co-authored-by: Aevann <randomname42029@gmail.com>
Reviewed-on: #135
2023-02-27 15:38:12 +00:00
Aevann 8c495c914a default ratelimit doesnt apply implicitly if theres other @limiter.limit before the function, so add it explicity before all functions 2023-02-26 10:41:04 +02:00
Aevann 7aaeedea36 better ratelimiting 2023-02-26 03:42:39 +02:00
Aevann 3efa1dfb04 remove unnecessary timeouts in cache.memoize 2023-02-02 02:42:47 +02:00
Aevann d38a9b8010 nerf "request" category 2023-01-28 12:45:51 +02:00
Aevann db24ff06e7 restore /comments 2023-01-25 13:10:58 +02:00
Aevann fa58ad978b fix syntax error in a previous commit 2023-01-24 08:02:35 +02:00
Aevann 2c2167d51f limit all non-death holes in WPD 2023-01-24 07:43:46 +02:00
Aevann a40dee5bd8 improve user ratelimiting 2023-01-21 06:39:46 +02:00
Aevann 9ded1cab20 move live commit to the sidebar where its less annoying 2023-01-21 06:27:30 +02:00
Aevann b13ec4f4c7 give an error message in /comments to stop bad bug reports 2023-01-21 05:59:53 +02:00
Aevann 131cf0b456 disable /comments on rdrama again 2023-01-21 00:01:09 +02:00
Aevann cc8a3211d9 restore /comments 2023-01-20 23:55:06 +02:00
Aevann 88d298801f Revert "redirect /comments to /search/comments"
This reverts commit c67f28125d.
2023-01-20 23:53:42 +02:00
Aevann c67f28125d redirect /comments to /search/comments 2023-01-20 23:43:30 +02:00
Aevann 21dcdc9310 disable it only on rdrama 2023-01-20 23:17:12 +02:00
Aevann f579fa24ec disable /comments temporarily 2023-01-20 23:16:09 +02:00
Aevann 044664a25e get rid of useless tabs and spaces 2023-01-01 13:36:20 +02:00
Aevann 9e0a3fd6b9 reduce commit hash from 12 chars to 7 2022-12-30 16:39:34 +02:00
Aevann 0bbe5d5ddd show live commit to everyone 2022-12-30 15:32:58 +02:00
Aevann1 97e3623ef0 default comment_idlist timefilter to "day" 2022-12-21 22:15:37 +02:00
justcool393 ab41db22b7 [DO NOT MERGE] multiple sub banners (#59)
allows multiple sub banners

Snakes note: By request of Carp, especially for WPD.

Co-authored-by: justcool393 <justcool393@gmail.com>
Co-authored-by: Snakes <duolsm@outlook.com>
Reviewed-on: #59
Co-authored-by: justcool393 <justcool393@noreply.fsdfsd.net>
Co-committed-by: justcool393 <justcool393@noreply.fsdfsd.net>
2022-12-11 23:44:34 +00:00
Aevann 81267ef1c6 do this https://stupidpol.site/h/countryclub/post/79285/tired-of-some-cute-twink-jannies/3194721?context=8#context (#53)
Co-authored-by: Aevann1 <randomname42029@gmail.com>
Reviewed-on: #53
2022-12-07 16:51:51 +00:00
Aevann e105035272 remove country club system and replace it with a 3 tier thing: (#41)
- /h/masterbaiters: 1 TS - for gayops

- /h/countryclub: 1000 TS - for anything requiring secrecy and doesnt need critical mass - have to make it a rule that u cant post gayops in /h/countryclub

- /h/chudrama: 5000 TS - for chad+stud posts

EDIT: i removed the /h/masterbaiters gate, but u can bring it back if u want
Co-authored-by: Aevann1 <randomname42029@gmail.com>
Co-authored-by: Snakes <duolsm@outlook.com>
Reviewed-on: #41
Co-authored-by: Aevann <aevann@noreply.fsdfsd.net>
Co-committed-by: Aevann <aevann@noreply.fsdfsd.net>
2022-12-04 18:39:06 +00:00
Aevann1 3d1c16044a use abort instead of sending raw text lol 2022-11-29 01:38:41 +02:00
justcool393 8506c46306 wpd: remove special front page logic 2022-11-28 16:55:16 -06:00
justcool393 0ff034b01b add typing to a bunch of routes 2022-11-26 15:00:16 -06:00
Aevann1 b3c47f5598 tell ppl how much Truescore they need to see /h/chudrama 2022-11-26 06:22:09 +02:00
justcool393 83963470e8
user can_view functions (#460)
* user: move can_see_to user class

* stub out can_see in comments and posts

* make can_see a classmethod so it's usable for loggedoutfriends

* test

* kill me now

* threelargeclassesmating

* dfdfdfdfdfdfd

* sdsdsdsd

* classmethod should be above i think

* Revert "classmethod should be above i think"

This reverts commit df1772eb9e7e71bf7b89123f6277b648de2b1af3.

* Revert "Revert "classmethod should be above i think""

This reverts commit 32883406c2e2916fc6c436611376a1817c16cb84.

* test rewritnig thing

* go home python

* what the fuck python

* fix AttributeError

* sdsdsdsdsdsd

* lazy and user and stuff

* test

* Revert "test"

This reverts commit 45af5bb3d45f3ec17126ab117d494ec978062a38.

* merge

* newline

* test

* test 2

* Revert "test"

This reverts commit 196dae677e2ee8cd29261c93dcb747087cb399b6.

* revert test

* fix merge error

* fix import error ciruclation i think

* sdsd

* add type annotations back

* deleted_utc

* isinstance

* user_can_see in jinja and remove unnecessary things

* a bunch of stuff
remove can_see from comment and post
expand can_see to messages

* antiannoyingamountsofwhitespace

* fix for chudrama

* improve prev
2022-11-17 16:02:08 -05:00
justcool393 8f2f48d6d1
[DO NOT MERGE] import detanglation (#442)
* move Base definition to files.classes.__init__.py

* fix ImportError

* move userpage listing to users.py

* don't import the app from classes

* consts: set default values to avoid crashes
consts: warn if the secret key is the default config value

* card view: sneed (user db schema)

* cloudflare: use DEFAULT_CONFIG_VALUE

* const: set default values

* decouple media.py from __main__

* pass database to avoid imports

* import cleanup and import request not in const, but in the requests mega import

* move asset_submissions site check to __init__

* asset submissions feature flag

* flag

* g.is_tor

* don't import request where it's not needed

* i think this is fine

* mail: move to own routes and helper

* wrappers

* required wrappers move

* unfuck wrappers a bit

* move snappy quotes and marseys to stateful consts

* marsify

* :pepodrool:

* fix missing import

* import cache

* ...and settings.py

* and static.py

* static needs cache

* route

* lmao all of the jinja shit was in feeds.py amazing

* classes should only import what they need from flask

* import Response

* hdjbjdhbhjf

* ...

* dfdfdfdf

* make get a non-required import

* isort imports (mostly)

* but actually

* configs

* reload config on import

* fgfgfgfg

* config

* config

* initialize snappy and test

* cookie of doom debug

* edfjnkf

* xikscdfd

* debug config

* set session cookie domain, i think this fixes the can't login bug

* sdfbgnhvfdsghbnjfbdvvfghnn

* hrsfxgf

* dump the entire config on a request

* kyskyskyskyskyskyskyskyskys

* duifhdskfjdfd

* dfdfdfdfdfdfdfdfdfdfdfdf

* dfdfdfdf

* imoprt all of the consts beacuse fuck it

* 😭

* dfdfdfdfdfdfsdasdf

* print the entire session

* rffdfdfjkfksj

* fgbhffh

* not the secret keys

* minor bug fixes

* be helpful in the warning

* gfgfgfg

* move warning lower

* isort main imports (i hope this doesn't fuck something up)

* test

* session cookie domain redux

* dfdfdfd

* try only importing Flask

* formkeys fix

* y

* :pepodrool:

* route helper

* remove before flight

* dfdfdfdfdf

* isort classes

* isort helpers

* move check_for_alts to routehelpers and also sort imports and get rid of unused ones

* that previous commit but actkally

* readd the cache in a dozen places they were implicitly imported

* use g.is_tor instead of request.headers. bla bla bla

* upgrade streamers to their own route file

* get rid of unused imports in __main__

* fgfgf

* don't pull in the entire ORM where we don't need it

* features

* explicit imports for the get helper

* explicit imports for the get helper redux

* testing allroutes

* remove unused import

* decouple flask from classes

* syntax fix also remember these have side fx for some reason (why?)

* move side effects out of the class

* posts

* testing on devrama

* settings

* reloading

* settingssdsdsds

* streamer features

* site settings

* testing settings on devrama

* import

* fix modlog

* remove debug stuff

* revert commit 67275b21ab6e2f2520819e84d10bfc1c746a15b6

* archiveorg to _archiveorg

* skhudkfkjfd

* fix cron for PCM

* fix bugs that snekky wants me to

* Fix call to realbody passing db, standardize kwarg

* test

* import check_for_alts from the right place

* cloudflare

* testing on devrama

* fix cron i think

* shadow properly

* tasks

* Remove print which will surely be annoying in prod.

* v and create new session

* use files.classes

* make errors import little and fix rare 500 in /allow_nsfw

* Revert "use files.classes"

This reverts commit 98c10b876cf86ce058b7fb955cf1ec0bfb9996c6.

* pass v to media functions rather than using g

* fix

* dfdfdfdfd

* cleanup, py type checking is dumb so don't use it where it causes issues

* Fix some merge bugs, add DEFAULT_RATELIMIT to main.

* Fix imports on sqlalchemy expressions.

* `from random import random` is an error.

* Fix replies db param.

* errors: fix missing import

* fix rare 500: only send to GIFT_NOTIF_ID if it exists, and send them the right text

* Fix signup formkey.

* fix 2 500s

* propagate db to submissions

* fix replies

* dfdfdfdf

* Fix verifiedcolor.

* is_manual

* can't use getters outside of an app context

* don't attempt to do gumroad on sites where it's not enabled

* don't attempt to do gumraod on sites's where it's unnecessary

* Revert "don't attempt to do gumroad on sites where it's not enabled"

This reverts commit 6f8a6331878655492dfaf1907b27f8be513c14d3.

* fix 500

* validate media type

Co-authored-by: TLSM <duolsm@outlook.com>
2022-11-15 03:19:08 -06:00
Snakes 4afa60dc81
Use database to filter hidevotedon directly.
We no longer need to build a list of potentially tens of thousands
of submission_ids in Python from the database to then pass back to
the database.
2022-11-09 09:57:51 -05:00
Snakes ebb3957f41
Eager load submission listing relationships. 2022-11-09 09:16:22 -05:00
justcool393 26549a6e66
remove logged out routes (#433)
* remove /logged_out/ routes

* update sitemap, remove users route, and update header

* cloudflare cookie

* only mess with the cookie whenever we desire auth

* sitemap: (small) improvements
sitemap: fix little bug i introduced
sitemap: fix login redirects for /id/ routes

* sitemap: remove duplicate entry

* contact is auth desired

* imports: don't import what we don't need and bind late to the db

* praying to god this works

* keep yourself safe

* oh i actually need to commit and push lol

* import Sub

* t

* refix cache purger
2022-11-09 00:35:24 -05:00
justcool393 ddbe3de33b remove catalog feature no one uses 2022-11-07 18:59:28 -06:00
Snakes cb3d92c479
WPD: fix auto-login token validation call params. 2022-11-07 19:41:25 -05:00
Aevann1 5111eb7ca4 exclude /h/changelog from hole filter 2022-11-07 03:18:54 +02:00
Aevann1 5a61907268 Revert "extend the holes filter to pinned posts"
This reverts commit ba031b09be.
2022-11-07 03:15:42 +02:00
Aevann1 ba031b09be extend the holes filter to pinned posts 2022-11-07 02:59:17 +02:00
Aevann1 2fe10e9644 replace cc toggle with holes toggle 2022-11-07 02:44:31 +02:00
Aevann1 0aa27a926b small fix to /h/social and /h/music logic 2022-11-07 01:43:50 +02:00
justcool393 8f1700a3c5 WPD: front: partially fix next page bug (increase counter to 101 so that we know about any next pages)
- the next page but still is there but this may fix it in some cases
WPD: front: fix bug that makes posts not show up when viewing a hole
2022-11-06 02:31:28 -06:00
Aevann1 a6f79e78d2 remove the "if True" 2022-11-06 08:33:29 +02:00
Aevann1 ba144f026e last-ditch attempt, killing myself if this one fails 2022-11-06 08:30:53 +02:00
Aevann1 12ceae5677 stop spamming console 2022-11-06 08:21:58 +02:00
Aevann1 9a1d88b22a time for print-debugging 2022-11-06 08:20:45 +02:00
Aevann1 842b971602 trying to fix /h/social limit 2022-11-06 08:18:58 +02:00
Aevann1 1ec5de2fcf Revert "WPD: remove vestigial social and music filer code"
This reverts commit bb1658e0a0.
2022-11-06 07:18:28 +02:00
justcool393 3a6dfdf2de listings: constantify PAGE_SIZE as 25
magic numbers are bad, do better next time
2022-10-28 22:20:48 -05:00