asok 0.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (60) hide show
  1. asok/__init__.py +38 -0
  2. asok/admin/__init__.py +2955 -0
  3. asok/admin/static/admin.css +1015 -0
  4. asok/admin/static/admin.js +673 -0
  5. asok/admin/static/logo.svg +14 -0
  6. asok/admin/static/quill.js +11489 -0
  7. asok/admin/static/quill.snow.css +945 -0
  8. asok/admin/templates/2fa.html +70 -0
  9. asok/admin/templates/2fa_setup.html +71 -0
  10. asok/admin/templates/base.html +221 -0
  11. asok/admin/templates/dashboard.html +115 -0
  12. asok/admin/templates/edit.html +217 -0
  13. asok/admin/templates/history.html +66 -0
  14. asok/admin/templates/import.html +174 -0
  15. asok/admin/templates/list.html +248 -0
  16. asok/admin/templates/login.html +88 -0
  17. asok/admin/templates/macros.html +179 -0
  18. asok/admin/templates/me.html +147 -0
  19. asok/admin/templates/media.html +99 -0
  20. asok/admin/templates/search.html +79 -0
  21. asok/admin/translations.py +514 -0
  22. asok/api/__init__.py +128 -0
  23. asok/api/openapi.py +169 -0
  24. asok/api/static/docs.css +654 -0
  25. asok/api/static/logo.svg +14 -0
  26. asok/api/templates/docs.html +450 -0
  27. asok/assets/logo.svg +14 -0
  28. asok/auth.py +234 -0
  29. asok/background.py +43 -0
  30. asok/cache.py +144 -0
  31. asok/cli.py +1885 -0
  32. asok/component.py +150 -0
  33. asok/core.py +1711 -0
  34. asok/exceptions.py +14 -0
  35. asok/forms.py +677 -0
  36. asok/logger.py +126 -0
  37. asok/mail.py +126 -0
  38. asok/orm.py +1749 -0
  39. asok/ratelimit.py +90 -0
  40. asok/request.py +1215 -0
  41. asok/scheduler.py +45 -0
  42. asok/session.py +248 -0
  43. asok/templates.py +995 -0
  44. asok/testing.py +120 -0
  45. asok/utils/__init__.py +0 -0
  46. asok/utils/css.py +75 -0
  47. asok/utils/geo.py +94 -0
  48. asok/utils/humanize.py +114 -0
  49. asok/utils/image.py +67 -0
  50. asok/utils/js.py +19 -0
  51. asok/utils/minify.py +60 -0
  52. asok/utils/security.py +80 -0
  53. asok/validation.py +362 -0
  54. asok/ws.py +801 -0
  55. asok-0.1.0.dist-info/METADATA +209 -0
  56. asok-0.1.0.dist-info/RECORD +60 -0
  57. asok-0.1.0.dist-info/WHEEL +5 -0
  58. asok-0.1.0.dist-info/entry_points.txt +2 -0
  59. asok-0.1.0.dist-info/licenses/LICENSE +21 -0
  60. asok-0.1.0.dist-info/top_level.txt +1 -0
asok/__init__.py ADDED
@@ -0,0 +1,38 @@
1
+ import os
2
+ import sys
3
+
4
+ __version__ = "0.1.0"
5
+
6
+ # Disable bytecode generation (__pycache__) by default to keep the file-system based routing clean.
7
+ # Can be overridden by setting ASOK_WRITE_BYTECODE=true in the environment.
8
+ if os.environ.get("ASOK_WRITE_BYTECODE", "").lower() != "true":
9
+ sys.dont_write_bytecode = True
10
+
11
+ from .admin import Admin as Admin
12
+ from .api import api as api
13
+ from .background import background as background
14
+ from .cache import Cache as Cache
15
+ from .component import Component as Component
16
+ from .core import Asok as Asok
17
+ from .exceptions import RedirectException as RedirectException
18
+ from .forms import Form as Form
19
+ from .logger import RequestLogger as RequestLogger
20
+ from .logger import get_logger as get_logger
21
+ from .mail import Mail as Mail
22
+ from .utils.security import internal_only as internal_only
23
+ from .orm import Field as Field
24
+ from .orm import Model as Model
25
+ from .orm import ModelError as ModelError
26
+ from .orm import Relation as Relation
27
+ from .orm import slugify as slugify
28
+ from .ratelimit import RateLimit as RateLimit
29
+ from .request import Request as Request
30
+ from .request import UploadedFile as UploadedFile
31
+ from .scheduler import schedule as schedule
32
+ from .session import Session as Session
33
+ from .session import SessionStore as SessionStore
34
+ from .templates import render_template_string as render_template_string
35
+ from .testing import TestClient as TestClient
36
+ from .validation import Schema as Schema
37
+ from .validation import Validator as Validator
38
+ from .ws import WebSocketServer as WebSocketServer