Commit Graph

22 Commits

Author SHA1 Message Date
Shyam Sunder 4117f63375 server/model/posts: Make post flags a hybrid attribute in model
This should (hopefully) fix #250 and #252
2019-04-22 20:20:19 -04:00
Shyam Sunder 3879c2ec20 server/search: allow searching by post flags 2018-09-24 11:36:13 +02:00
rr- ad842ee8a5 server: refactor + add type hinting
- 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-05 16:34:45 +01:00
rr- abf1fc2b2d server: make linters happier 2017-02-03 22:42:14 +01:00
rr- 80af79779d server/snapshots: rewrite 2016-08-16 21:51:25 +02:00
rr- 9aea55e3d1 server/general: embrace most of PEP8
Ignored only the rules about continuing / hanging indentation.

Also, added __init__.py to tests so that pylint discovers them. (I don't
buy pytest's BS about installing your package.)
2016-08-14 16:44:03 +02:00
rr- af62f8c45a server/general: ditch falcon for in-house WSGI app
For quite some time, I hated Falcon's class maps approach that caused
more chaos than good for Szurubooru. I've taken a look at the other
frameworks (hug, flask, etc) again, but they all looked too
bloated/over-engineered. I decided to just talk to WSGI myself.

Regex-based routing may not be the fastest in the world, but I'm fine
with response time of 10 ms for cached /posts.
2016-08-14 16:43:35 +02:00
rr- c2bbf7b62c server/general: add assertions 2016-08-14 16:43:04 +02:00
rr- b7f2982c9e server/posts: fix relations bidirectionality 2016-07-17 21:14:03 +02:00
rr- c21494be25 server/posts: make relations bidirectional 2016-07-03 18:30:32 +02:00
rr- ac23067fdf server/general: use UTC time stamps 2016-07-03 14:46:28 +02:00
rr- 4d1f745e38 server/notes: fix note serialization 2016-05-29 12:40:36 +02:00
rr- 77998f1660 server/tags: let mods set default category 2016-05-22 22:17:11 +02:00
rr- cd15cdff7a server/scores+favorites: merge duplicate code 2016-05-10 12:15:05 +02:00
rr- a567974784 server/general: refactor method names 2016-04-30 23:54:05 +02:00
rr- 52f4018bee server/comments+posts: add rating 2016-04-24 16:37:11 +02:00
rr- 6e6c57d44a server/api: move serializers to func layer 2016-04-24 10:31:49 +02:00
rr- 1476c84a9d server/posts: add featured post retrieval 2016-04-23 08:07:21 +02:00
rr- cf00a3a2de server/posts: add post featuring 2016-04-22 20:58:04 +02:00
rr- 46ee9faf72 server/snapshots: add snapshot lists 2016-04-21 19:27:30 +02:00
rr- c2a39a0fd5 server/snapshots: change snapshot representation 2016-04-21 19:01:41 +02:00
rr- 57b18c6461 server/general: rename 'util' to 'func' 2016-04-20 11:58:17 +02:00