Hi On Wed, 2018-10-31 at 10:59 +0000, Łukasz Kokoszka via Weblate wrote: > Running "weblate commit_pending --all --age 0" gives even more errors > ;) > > ERROR Handled exception UnboundLocalError: b"local variable 'age' > > referenced before assignment" > > Traceback (most recent call last): > > File "/usr/local/bin/weblate", line 11, in <module> > > sys.exit(main()) > > File "/usr/local/lib/python3.5/dist-packages/weblate/runner.py", > > line 34, in main > > execute_from_command_line(argv) > > File "/usr/local/lib/python3.5/dist- > > packages/django/core/management/__init__.py", line 381, in > > execute_from_command_line > > utility.execute() > > File "/usr/local/lib/python3.5/dist- > > packages/django/core/management/__init__.py", line 375, in execute > > self.fetch_command(subcommand).run_from_argv(self.argv) > > File "/usr/local/lib/python3.5/dist- > > packages/django/core/management/base.py", line 316, in > > run_from_argv > > self.execute(*args, **cmd_options) > > File "/usr/local/lib/python3.5/dist- > > packages/weblate/trans/management/commands/__init__.py", line 42, > > in execute > > super(WeblateCommand, self).execute(*args, **options) > > File "/usr/local/lib/python3.5/dist- > > packages/django/core/management/base.py", line 353, in execute > > output = self.handle(*args, **options) > > File "/usr/local/lib/python3.5/dist- > > packages/weblate/trans/management/commands/commit_pending.py", line > > 45, in handle > > self.stdout.write if int(options['verbosity']) >= 1 else None, > > File "/usr/local/lib/python3.5/dist-packages/celery/local.py", > > line 191, in __call__ > > return self._get_current_object()(*a, **kw) > > File "/usr/local/lib/python3.5/dist-packages/celery/app/task.py", > > line 375, in __call__ > > return self.run(*args, **kwargs) > > File "/usr/local/lib/python3.5/dist- > > packages/weblate/trans/tasks.py", line 93, in commit_pending > > if last_change > age: > > UnboundLocalError: local variable 'age' referenced before > > assignment
This should be fixed here: https://github.com/WeblateOrg/weblate/commit/accedf77b0a5289d829c60f083343ece5072779c That's probably the reason why the Celery task is not working as expected as it's using same code. > When it comes to your question why we aren't using newer version. So > in our tests version 3.2.1-1 and 3.2.1-2 were producing a lot of > ignored exceptions similar to this one: > > Exception ignored in: <function > > WeakValueDictionary.__init__.<locals>.remove at 0x7f55b6b5cea0> > > Traceback (most recent call last): > > File "/usr/lib/python3.5/weakref.py", line 117, in remove > > TypeError: 'NoneType' object is not callable > > Exception ignored in: <function > > WeakValueDictionary.__init__.<locals>.remove at 0x7f55b6b5cea0> > > Traceback (most recent call last): > > File "/usr/lib/python3.5/weakref.py", line 117, in remove > > TypeError: 'NoneType' object is not callable This is bug in Python, should be harmless, see https://bugs.python.org/issue29519 > > and we had some problems with migrations, however from current > perspective this (falling migrations) were our fault, and we will > give them a try one more time. > Versions: 3.2.2+ produced a lot of internal server errors during > simple clicking, and one especially huge problem for is the fact that > language management stopped working giving error: > > list index out of range > > Request Method: POST > > Request URL: http://localhost/admin/lang/language/add/ > > Django Version: 2.1.2 > > Exception Type: IndexError > > Exception Value: > > list index out of range > > Exception Location: /usr/local/lib/python3.5/dist- > > packages/django/db/models/query.py in __getitem__, line 303 > > Python Executable: /usr/bin/uwsgi-core > > Python Version: 3.5.3 > > Python Path: > > ['/usr/local/lib/python3.5/dist-packages/', > > '.', > > '', > > '/usr/lib/python35.zip', > > '/usr/lib/python3.5', > > '/usr/lib/python3.5/plat-x86_64-linux-gnu', > > '/usr/lib/python3.5/lib-dynload', > > '/usr/local/lib/python3.5/dist-packages', > > '/usr/lib/python3/dist-packages', > > '/'] Can you please open issue for that including full traceback? Thanks. -- Michal Čihař | https://cihar.com/ | https://weblate.org/
signature.asc
Description: This is a digitally signed message part
_______________________________________________ Weblate mailing list [email protected] https://lists.cihar.com/cgi-bin/mailman/listinfo/weblate
