mirror of
https://github.com/LibreTranslate/LibreTranslate.git
synced 2024-12-22 15:16:30 +00:00
updated argos to 1.1.2, fix argos translate init and templates.html render
This commit is contained in:
parent
90d743796b
commit
a0760eb23f
4 changed files with 4 additions and 4 deletions
2
.github/workflows/publish-package.yml
vendored
2
.github/workflows/publish-package.yml
vendored
|
@ -44,7 +44,7 @@ jobs:
|
|||
- name: Set up Python
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: '3.x'
|
||||
python-version: '3.8'
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
|
|
|
@ -68,7 +68,7 @@ def create_app(char_limit=-1, req_limit=-1, batch_limit=-1, ga_id=None, debug=Fa
|
|||
|
||||
@app.route("/")
|
||||
def index():
|
||||
return render_template(resource_filename('app', 'templates/index.html'), gaId=ga_id, frontendTimeout=frontend_timeout)
|
||||
return render_template('index.html', gaId=ga_id, frontendTimeout=frontend_timeout)
|
||||
|
||||
@app.route("/languages")
|
||||
def langs():
|
||||
|
|
|
@ -7,7 +7,7 @@ def boot():
|
|||
check_and_install_models()
|
||||
|
||||
def check_and_install_models(force=False):
|
||||
if len(package.get_installed_packages()) == 0 or force:
|
||||
if len(package.get_installed_packages()) < 2 or force:
|
||||
# Update package definitions from remote
|
||||
print("Updating language models")
|
||||
package.update_package_index()
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
argostranslate==1.1.0
|
||||
argostranslate==1.1.2
|
||||
Flask==1.1.2
|
||||
flask-swagger==0.2.14
|
||||
flask-swagger-ui==3.36.0
|
||||
|
|
Loading…
Reference in a new issue