Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
callidus
Machina Callida
Commits
402ffe3c
Commit
402ffe3c
authored
May 18, 2020
by
Konstantin Schulz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
changed the order of database initializations in the corpus storage manager
parent
32c97df5
Pipeline
#11594
failed with stages
in 1 minute and 18 seconds
Changes
1
Pipelines
2
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
mc_backend/mcserver/app/__init__.py
mc_backend/mcserver/app/__init__.py
+5
-4
No files found.
mc_backend/mcserver/app/__init__.py
View file @
402ffe3c
...
...
@@ -63,15 +63,13 @@ def create_app(cfg: Type[Config] = Config) -> Flask:
def
full_init
(
app
:
Flask
,
is_csm
:
bool
)
->
None
:
""" Fully initializes the application, including logging."""
from
mcserver.app.services.corpusService
import
CorpusService
from
mcserver.app.services
import
CustomCorpusService
if
is_csm
:
from
mcserver.app.services.databaseService
import
DatabaseService
DatabaseService
.
init_db_alembic
()
from
mcserver.app.services
import
DatabaseService
DatabaseService
.
init_db_update_info
()
DatabaseService
.
update_exercises
(
is_csm
=
is_csm
)
DatabaseService
.
init_db_corpus
()
if
not
app
.
config
[
"TESTING"
]:
from
mcserver.app.services.corpusService
import
CorpusService
CorpusService
.
init_graphannis_logging
()
start_updater
(
app
)
...
...
@@ -91,6 +89,9 @@ def init_app_common(cfg: Type[Config] = Config, is_csm: bool = False) -> Flask:
db
.
init_app
(
app
)
migrate
.
init_app
(
app
,
db
)
db
.
create_all
()
if
is_csm
:
from
mcserver.app.services.databaseService
import
DatabaseService
DatabaseService
.
init_db_alembic
()
from
mcserver.app.services.textService
import
TextService
TextService
.
init_proper_nouns_list
()
TextService
.
init_stop_words_latin
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment