Skip to content

Commit

Permalink
update babel instantiation and requirements.txt
Browse files Browse the repository at this point in the history
  • Loading branch information
kvchitrapu committed Apr 2, 2023
1 parent ae36b81 commit d5ebea9
Show file tree
Hide file tree
Showing 2 changed files with 162 additions and 150 deletions.
10 changes: 5 additions & 5 deletions ambuda/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@
import logging
import sys

import config
import sentry_sdk
from dotenv import load_dotenv
from flask import Flask, session
from flask_babel import Babel, pgettext
from sentry_sdk.integrations.flask import FlaskIntegration
from sqlalchemy import exc

import config
from ambuda import admin as admin_manager
from ambuda import auth as auth_manager
from ambuda import checks, filters, queries
Expand Down Expand Up @@ -111,13 +111,13 @@ def create_app(config_env: str):
# Database
_initialize_db_session(app, config_env)

# Extensions
babel = Babel(app)

@babel.localeselector
# A custom Babel locale_selector.
def get_locale():
return session.get("locale", config_spec.BABEL_DEFAULT_LOCALE)

# Extensions
Babel(app, locale_selector=get_locale)

login_manager = auth_manager.create_login_manager()
login_manager.init_app(app)

Expand Down
302 changes: 157 additions & 145 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,145 +1,157 @@
aksharamukha==2.0.1
alabaster==0.7.12
alembic==1.8.0
amqp==5.1.1
async-generator==1.10
async-timeout==4.0.2
attrs==21.4.0
Babel==2.12.0
backports.functools-lru-cache==1.6.4
bcrypt==4.0.0
billiard==3.6.4.0
black==22.3.0
blinker==1.4
cachetools==5.2.0
celery==5.2.7
certifi==2022.5.18.1
cffi==1.15.0
charset-normalizer==2.0.12
click==8.1.3
click-didyoumean==0.3.0
click-plugins==1.1.1
click-repl==0.2.0
conllu==4.5.2
coverage==6.4.1
cryptography==37.0.2
Deprecated==1.2.13
dnspython==2.2.1
docutils==0.17.1
email-validator==1.2.1
fabric==2.7.0
Flask==2.1.2
Flask-Admin==1.6.0
Flask-Babel==2.0.0
Flask-Bcrypt==1.0.1
Flask-Login==0.6.1
Flask-Mail==0.9.1
Flask-WTF==1.0.1
fonttools==4.33.3
gevent==21.12.0
google-api-core==2.8.2
google-auth==2.9.0
google-cloud-vision==3.1.1
googleapis-common-protos==1.56.3
greenlet==1.1.2
grpcio==1.47.0
grpcio-status==1.47.0
gunicorn==20.1.0
h11==0.13.0
idna==3.3
imagesize==1.3.0
importlib-metadata==4.11.4
indic-transliteration==2.3.31
iniconfig==1.1.1
invoke==1.7.1
itsdangerous==2.1.2
jaconv==0.3
Jinja2==3.1.2
kombu==5.2.4
langcodes==3.3.0
language-data==1.1
linkify-it-py==2.0.0
lxml==4.9.1
Mako==1.2.2
marisa-trie==0.7.7
markdown-it-py==2.1.0
MarkupSafe==2.1.1
mccabe==0.7.0
mdurl==0.1.1
memory-profiler==0.60.0
mypy-extensions==0.4.3
outcome==1.1.0
packaging==21.3
paramiko==2.11.0
pathlib2==2.3.7.post1
pathspec==0.9.0
pika==1.3.0
Pillow==9.1.1
platformdirs==2.5.2
pluggy==1.0.0
prometheus-client==0.14.1
prompt-toolkit==3.0.30
proto-plus==1.22.0
protobuf==3.20.1
psutil==5.9.1
py==1.11.0
pyasn1==0.4.8
pyasn1-modules==0.2.8
pycodestyle==2.9.1
pycparser==2.21
Pygments==2.12.0
pykakasi==2.2.1
PyMuPDF==1.20.2
PyNaCl==1.5.0
pyOpenSSL==22.0.0
pyparsing==3.0.9
PySocks==1.7.1
pytest==7.1.2
pytest-cov==4.0.0
python-dateutil==2.8.2
python-dotenv==0.20.0
python-slugify==6.1.2
pytz==2022.2.1
PyYAML==6.0
redis==4.3.4
regex==2022.6.2
requests==2.27.1
roman==3.3
ruff==0.0.260
rsa==4.8
selenium==4.2.0
sentry-sdk==1.6.0
six==1.16.0
sniffio==1.2.0
snowballstemmer==2.2.0
sortedcontainers==2.4.0
Sphinx==5.0.2
sphinx-rtd-theme==1.0.0
sphinxcontrib-applehelp==1.0.2
sphinxcontrib-devhelp==1.0.2
sphinxcontrib-htmlhelp==2.0.0
sphinxcontrib-jsmath==1.0.1
sphinxcontrib-qthelp==1.0.3
sphinxcontrib-serializinghtml==1.1.5
SQLAlchemy==1.4.37
text-unidecode==1.3
toml==0.10.2
tomli==2.0.1
trio==0.20.0
trio-websocket==0.9.2
typer==0.6.1
typing_extensions==4.2.0
uc-micro-py==1.0.1
unicodedata2==14.0.0
urllib3==1.26.9
vine==5.0.0
watchdog==2.1.9
watchdog-gevent==0.1.1
wcwidth==0.2.5
Werkzeug==2.1.2
wrapt==1.14.1
wsproto==1.1.0
WTForms==3.0.1
zipp==3.8.0
zope.event==4.5.0
zope.interface==5.4.0
aksharamukha==2.0.1
alabaster==0.7.12
alembic==1.8.0
amqp==5.1.1
async-generator==1.10
async-timeout==4.0.2
attrs==21.4.0
babel==2.12.1
backports-functools-lru-cache==1.6.4
bcrypt==4.0.0
billiard==3.6.4.0
black==22.12.0
blinker==1.4
cachetools==5.2.0
celery==5.2.7
certifi==2022.5.18.1
cffi==1.15.0
charset-normalizer==2.0.12
click-didyoumean==0.3.0
click-plugins==1.1.1
click-repl==0.2.0
click==8.1.3
colorama==0.4.6
conllu==4.5.2
coverage==6.4.1
coverage[toml]==6.4.1
cryptography==38.0.1
deprecated==1.2.13
dnspython==2.2.1
docutils==0.17.1
email-validator==1.2.1
exceptiongroup==1.1.1
fabric==2.7.0
flake8==5.0.4
flask-admin==1.6.0
flask-babel==3.0.1
flask-bcrypt==1.0.1
flask-login==0.6.1
flask-mail==0.9.1
flask-wtf==1.0.1
flask==2.1.2
fonttools==4.33.3
fonttools[unicode]==4.33.3
gevent==21.12.0
google-api-core==2.8.2
google-api-core[grpc]==2.8.2
google-auth==2.9.0
google-cloud-vision==3.1.1
googleapis-common-protos==1.56.3
greenlet==1.1.2
grpcio-status==1.47.0
grpcio==1.47.0
gunicorn==20.1.0
h11==0.13.0
idna==3.3
imagesize==1.3.0
importlib-metadata==4.11.4
indic-transliteration==2.3.31
iniconfig==1.1.1
invoke==1.7.1
isort==5.12.0
itsdangerous==2.1.2
jaconv==0.3
jinja2==3.1.2
kombu==5.2.4
langcodes==3.3.0
language-data==1.1
linkify-it-py==2.0.0
lxml==4.9.1
mako==1.2.2
marisa-trie==0.7.7
markdown-it-py==2.1.0
markupsafe==2.1.1
mccabe==0.7.0
mdurl==0.1.1
memory-profiler==0.60.0
mypy-extensions==0.4.3
outcome==1.1.0
packaging==21.3
paramiko==2.11.0
pathlib2==2.3.7.post1
pathspec==0.9.0
pika==1.3.0
pillow==9.1.1
platformdirs==2.5.2
pluggy==1.0.0
prometheus-client==0.14.1
prompt-toolkit==3.0.30
proto-plus==1.22.0
protobuf==4.21.6
psutil==5.9.1
py==1.11.0
pyasn1-modules==0.2.8
pyasn1==0.4.8
pycodestyle==2.9.1
pycparser==2.21
pyflakes==2.5.0
pygments==2.12.0
pykakasi==2.2.1
pymupdf==1.20.2
pynacl==1.5.0
pyopenssl==22.0.0
pyparsing==3.0.9
pysocks==1.7.1
pytest-cov==4.0.0
pytest-cover==3.0.0
pytest-coverage==0.0
pytest==7.2.2
python-dateutil==2.8.2
python-dotenv==0.20.0
python-slugify==6.1.2
pytz==2022.7
pyyaml==6.0
redis==4.3.4
regex==2022.6.2
requests==2.27.1
roman==3.3
rsa==4.8
selenium==4.2.0
sentry-sdk==1.6.0
setuptools==57.5.0
six==1.16.0
sniffio==1.2.0
snowballstemmer==2.2.0
sortedcontainers==2.4.0
sphinx-rtd-theme==1.0.0
sphinx==5.0.2
sphinxcontrib-applehelp==1.0.2
sphinxcontrib-devhelp==1.0.2
sphinxcontrib-htmlhelp==2.0.0
sphinxcontrib-jsmath==1.0.1
sphinxcontrib-qthelp==1.0.3
sphinxcontrib-serializinghtml==1.1.5
sqlalchemy==1.4.37
swig==4.1.1
text-unidecode==1.3
toml==0.10.2
tomli==2.0.1
trio-websocket==0.9.2
trio==0.20.0
typer==0.6.1
typing-extensions==4.2.0
uc-micro-py==1.0.1
unicodedata2==14.0.0
urllib3==1.26.9
urllib3[secure,socks]==1.26.9
vine==5.0.0
watchdog-gevent==0.1.1
watchdog==2.1.9
wcwidth==0.2.5
werkzeug==2.1.2
wrapt==1.14.1
wsproto==1.1.0
wtforms==3.0.1
zipp==3.8.0
zope-event==4.5.0
zope-interface==5.4.0

0 comments on commit d5ebea9

Please sign in to comment.