Overcome the error: AttributeError: 'Settings' object has no attribute 'PLUGINS_REPO_ID'

Hey everybody,

the last days some users complained that the creation of a superuser resulted in error. Here is the command and the corresponding logs:

root@seatable:/opt/seatable# docker exec -it seatable /shared/seatable/scripts/seatable.sh superuser 

Traceback (most recent call last):
  File "manage.py", line 10, in <module>
    execute_from_command_line(sys.argv)
  File "/opt/seatable/seatable-server-latest/dtable-web/thirdpart/django/core/management/__init__.py", line 419, in execute_from_command_line
    utility.execute()
  File "/opt/seatable/seatable-server-latest/dtable-web/thirdpart/django/core/management/__init__.py", line 413, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/opt/seatable/seatable-server-latest/dtable-web/thirdpart/django/core/management/base.py", line 354, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/opt/seatable/seatable-server-latest/dtable-web/thirdpart/django/core/management/base.py", line 393, in execute
    self.check()
...  
... (i removed some error lines)
...
  File "/usr/lib/python3.7/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1006, in _gcd_import
  File "<frozen importlib._bootstrap>", line 983, in _find_and_load
  File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 677, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 728, in exec_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "/opt/seatable/seatable-server-2.7.3/dtable-web/seahub/urls.py", line 156, in <module>
    from seahub.api2.endpoints.admin.sys_plugins import AdminDTableSystemPluginsView, AdminDTableSystemPluginView, \
  File "/opt/seatable/seatable-server-2.7.3/dtable-web/seahub/api2/endpoints/admin/sys_plugins.py", line 32, in <module>
    PLUGINS_REPO_ID = settings.PLUGINS_REPO_ID
  File "/opt/seatable/seatable-server-latest/dtable-web/thirdpart/django/conf/__init__.py", line 83, in __getattr__
    val = getattr(self._wrapped, name)
AttributeError: 'Settings' object has no attribute 'PLUGINS_REPO_ID'

The reason for this error is in most cases quite simple.
As described in the installation manual SeaTable requires since Version 2.5 a seatable-license.txt file. If this file is not created or added before you execute this superuser creation, then this error occurs. You get a free license for up to three users here at https://seatable.io.

So if you face this issue: stop seatable, add the license file, start seatable and create a superuser

docker exec -d seatable /shared/seatable/scripts/seatable.sh stop
nano /opt/seatable/seatable-data/seatable/seatable-license.txt
docker exec -d seatable /shared/seatable/scripts/seatable.sh start
docker exec -it seatable /shared/seatable/scripts/seatable.sh superuser
# add an email and choose a passwort...
# Superuser created successfully.

Best regards
Christoph