Module Not Found Error

I tried to upgrade our docker image to tryton/tryton:6.2-office but unfortunately now it’s not working anymore. Internal Server Error, the issue seems to be :

  File "/usr/local/lib/python3.9/dist-packages/trytond/modules/web_user/user.py", line 35, in <module>

    from trytond.tools.email_ import set_from_header

ModuleNotFoundError: No module named 'trytond.tools.email_'

I don’t have the module “web user” activated. Is it required now ?

Rolling back to tryton/tryton:6.0-office fix the issue.

For me you have an older version of trytond in the PYTHONPATH.

Thanks for your reply @ced
We use the docker image tryton/tryton:6.0-office, we don’t change PYTHONPATH.
I just changed the docker image to tryton/tryton:6.2-office. Reverting to tryton/tryton:6.0-office solve it.

Here is our dockerfile :

FROM tryton/tryton:6.0-office
USER root

COPY ./ImportScripts /ImportScripts
RUN apt update && apt -y upgrade && apt -y autoremove
RUN apt install -y procps
RUN apt install -y python3-pandas
RUN pip3 install xlrd==1.2.0
RUN pip3 install openpyxl
RUN apt install -y bash-completion nano
RUN chsh -s /bin/bash trytond
# Copy our modules in the tryton container
COPY ./modules/ /modules
RUN pip3 install /modules/transport \
    && rm -rf /root/.cache

COPY trytond-log.conf /etc/trytond-log.conf
ENV TRYTOND_LOGGING_CONFIG=/etc/trytond-log.conf
USER trytond

You probably got a dependency that depends on the wrong Tryton series.

Thank you very much!
I needed to update the tryton.cfg of my module and change it to :

[tryton]
version = 6.2.0
...