Compose fails because the admin E-mail has no @ sign in the default
Expected:
Installation with docker-compose finishes without any error.
Observed: Installation contains error because the Admin E-mail address does not contain an @ sign.
proposed solution: Provide the option to define the admin E-mail address or change the compose.yml file.
Logging:
server_1 | 10 140101147127872 [2024-08-23 22:16:35,351] INFO trytond.modules all modules loaded
server_1 | Traceback (most recent call last):
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/res/user.py", line 466, in check_valid_email
server_1 | validate_email(user.email)
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/tools/email_.py", line 53, in validate_email
server_1 | emailinfo = _validate_email(
server_1 | ^^^^^^^^^^^^^^^^
server_1 | File "/usr/local/lib/python3.11/dist-packages/email_validator/validate_email.py", line 71, in validate_email
server_1 | = split_email(email)
server_1 | ^^^^^^^^^^^^^^^^^^
server_1 | File "/usr/local/lib/python3.11/dist-packages/email_validator/syntax.py", line 123, in split_email
server_1 | left_part, right_part = split_string_at_unquoted_special(email, ("@", "<"))
server_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
server_1 | File "/usr/local/lib/python3.11/dist-packages/email_validator/syntax.py", line 86, in split_string_at_unquoted_special
server_1 | raise EmailSyntaxError("An email address must have an @-sign.")
server_1 | email_validator.exceptions_types.EmailSyntaxError: An email address must have an @-sign.
server_1 |
server_1 | The above exception was the direct cause of the following exception:
server_1 |
server_1 | Traceback (most recent call last):
server_1 | File "/usr/local/bin/trytond-admin", line 33, in <module>
server_1 | admin.run(options)
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/admin.py", line 131, in run
server_1 | admin.save()
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/model/descriptors.py", line 31, in newfunc
server_1 | return self.func(owner, [instance], *args, **kwargs)
server_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/model/modelstorage.py", line 2023, in save
server_1 | cls.write(*sum(
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/res/user.py", line 407, in write
server_1 | super(User, cls).write(*args)
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/model/avatar.py", line 90, in write
server_1 | super().write(*args)
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/model/modelsql.py", line 262, in wrapper
server_1 | return func(cls, *args, **kwargs)
server_1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/model/modelsql.py", line 1410, in write
server_1 | cls._validate(sub_records, field_names=all_field_names)
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/transaction.py", line 50, in wrapper
server_1 | return func(*args, **kwargs)
server_1 | ^^^^^^^^^^^^^^^^^^^^^
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/model/modelstorage.py", line 1590, in _validate
server_1 | cls.validate_fields(records, field_names)
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/res/user.py", line 457, in validate_fields
server_1 | cls.check_valid_email(users, fields_names)
server_1 | File "/usr/local/lib/python3.11/dist-packages/trytond/res/user.py", line 468, in check_valid_email
server_1 | raise UserValidationError(gettext(
server_1 | trytond.res.user.UserValidationError: The email address "admin" for "Administrator" is not valid. - An email address must have an @-sign.
server_1 | [2024-08-23 22:16:36 +0000] [11] [INFO] Starting gunicorn 20.1.0
server_1 | [2024-08-23 22:16:36 +0000] [11] [INFO] Listening at: http://0.0.0.0:8000 (11)
server_1 | [2024-08-23 22:16:36 +0000] [11] [INFO] Using worker: sync
server_1 | [2024-08-23 22:16:36 +0000] [12] [INFO] Booting worker with pid: 12