Bug 2143595 - Trac - even more broken with Fedora 37
Summary: Trac - even more broken with Fedora 37
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: trac
Version: 37
Hardware: All
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Gwyn Ciesla
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 2149630 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-11-17 10:42 UTC by camelot
Modified: 2022-12-16 01:56 UTC (History)
6 users (show)

Fixed In Version: trac-1.5.3-8.fc36 trac-1.5.3-8.fc37
Clone Of:
Environment:
Last Closed: 2022-12-07 22:20:13 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description camelot 2022-11-17 10:42:28 UTC
Trac does not work since Fedora 35, new problems with Fedora 37

Packages of Fedora 37:
trac-1.5.3-7.fc37.noarch
python3-markupsafe-2.1.1-3.fc37.x86_64

Since markupsafe 2.1.0:
"Remove soft_unicode, which was previously deprecated. Use soft_str instead. #261"
https://markupsafe.palletsprojects.com/en/2.1.x/changes/#version-2-1-0

To fix ths i had manually to run:
sudo sed -i 's/soft_unicode/soft_str/g' /lib/python3.11/site-packages/trac/util/presentation.py
I've not checked if this is fixed in a newer trac version



Since Fedora 35 (also still with Fedora 36+37):
This python3 fix is needed to run: https://trac.edgewall.org/changeset/17541

eg by
cd /lib/python3.11/site-packages/trac
wget 'https://trac.edgewall.org/changeset/17541?format=diff&new=17541' -O 17541.diff
dos2unix 17541.diff
patch -p3 < 17541.diff

Comment 1 Anthony Messina 2022-11-18 21:46:00 UTC
(In reply to camelot from comment #0)
> Trac does not work since Fedora 35, new problems with Fedora 37
> 
> Packages of Fedora 37:
> trac-1.5.3-7.fc37.noarch
> python3-markupsafe-2.1.1-3.fc37.x86_64
> 
> Since markupsafe 2.1.0:
> "Remove soft_unicode, which was previously deprecated. Use soft_str instead.
> #261"
> https://markupsafe.palletsprojects.com/en/2.1.x/changes/#version-2-1-0
> 
> To fix ths i had manually to run:
> sudo sed -i 's/soft_unicode/soft_str/g'
> /lib/python3.11/site-packages/trac/util/presentation.py
> I've not checked if this is fixed in a newer trac version

This is referenced upstream as https://trac.edgewall.org/ticket/13404

I can confirm the patch allows my Trac instance to work on Fedora 37.

Comment 2 Gwyn Ciesla 2022-11-21 17:24:23 UTC
Thank you!

This is a start but doesn't allow Trac to build:

Traceback (most recent call last):
  File "/home/gwyn/fedora/git/trac/Trac-1.5.3/setup.py", line 42, in <module>
    setup(**extra)
  File "/usr/lib/python3.11/site-packages/setuptools/__init__.py", line 87, in setup
    return distutils.core.setup(**attrs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 177, in setup
    return run_commands(dist)
           ^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 193, in run_commands
    dist.run_commands()
  File "/usr/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 968, in run_commands
    self.run_command(cmd)
  File "/usr/lib/python3.11/site-packages/setuptools/dist.py", line 1229, in run_command
    super().run_command(command)
  File "/usr/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 987, in run_command
    cmd_obj.run()
  File "/usr/lib/python3.11/site-packages/setuptools/_distutils/command/build.py", line 131, in run
    self.run_command(cmd_name)
  File "/usr/lib/python3.11/site-packages/setuptools/_distutils/cmd.py", line 317, in run_command
    self.distribution.run_command(command)
  File "/usr/lib/python3.11/site-packages/setuptools/dist.py", line 1229, in run_command
    super().run_command(command)
  File "/usr/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 987, in run_command
    cmd_obj.run()
  File "/home/gwyn/fedora/git/trac/Trac-1.5.3/trac/dist.py", line 390, in run
    write_js(outfile, catalog, self.domain, locale)
  File "/home/gwyn/fedora/git/trac/Trac-1.5.3/trac/dist.py", line 501, in write_js
    from trac.util.presentation import to_json
  File "/home/gwyn/fedora/git/trac/Trac-1.5.3/trac/util/presentation.py", line 26, in <module>
    from markupsafe import soft_unicode
ImportError: cannot import name 'soft_unicode' from 'markupsafe' (/usr/lib64/python3.11/site-packages/markupsafe/__init__.py)
error: Bad exit status from /var/tmp/rpm-tmp.hbgxRm (%build)

Comment 3 Anthony Messina 2022-11-26 19:17:08 UTC
(In reply to Gwyn Ciesla from comment #2)
> Thank you!
> 
> This is a start but doesn't allow Trac to build:
> 
> Traceback (most recent call last):
>   File "/home/gwyn/fedora/git/trac/Trac-1.5.3/setup.py", line 42, in <module>
>     setup(**extra)
>   File "/usr/lib/python3.11/site-packages/setuptools/__init__.py", line 87,
> in setup
>     return distutils.core.setup(**attrs)
>            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>   File "/usr/lib/python3.11/site-packages/setuptools/_distutils/core.py",
> line 177, in setup
>     return run_commands(dist)
>            ^^^^^^^^^^^^^^^^^^
>   File "/usr/lib/python3.11/site-packages/setuptools/_distutils/core.py",
> line 193, in run_commands
>     dist.run_commands()
>   File "/usr/lib/python3.11/site-packages/setuptools/_distutils/dist.py",
> line 968, in run_commands
>     self.run_command(cmd)
>   File "/usr/lib/python3.11/site-packages/setuptools/dist.py", line 1229, in
> run_command
>     super().run_command(command)
>   File "/usr/lib/python3.11/site-packages/setuptools/_distutils/dist.py",
> line 987, in run_command
>     cmd_obj.run()
>   File
> "/usr/lib/python3.11/site-packages/setuptools/_distutils/command/build.py",
> line 131, in run
>     self.run_command(cmd_name)
>   File "/usr/lib/python3.11/site-packages/setuptools/_distutils/cmd.py",
> line 317, in run_command
>     self.distribution.run_command(command)
>   File "/usr/lib/python3.11/site-packages/setuptools/dist.py", line 1229, in
> run_command
>     super().run_command(command)
>   File "/usr/lib/python3.11/site-packages/setuptools/_distutils/dist.py",
> line 987, in run_command
>     cmd_obj.run()
>   File "/home/gwyn/fedora/git/trac/Trac-1.5.3/trac/dist.py", line 390, in run
>     write_js(outfile, catalog, self.domain, locale)
>   File "/home/gwyn/fedora/git/trac/Trac-1.5.3/trac/dist.py", line 501, in
> write_js
>     from trac.util.presentation import to_json
>   File "/home/gwyn/fedora/git/trac/Trac-1.5.3/trac/util/presentation.py",
> line 26, in <module>
>     from markupsafe import soft_unicode
> ImportError: cannot import name 'soft_unicode' from 'markupsafe'
> (/usr/lib64/python3.11/site-packages/markupsafe/__init__.py)
> error: Bad exit status from /var/tmp/rpm-tmp.hbgxRm (%build)

Did you try the build with https://trac.edgewall.org/changeset/17575?  That's the upstream resolution for https://trac.edgewall.org/ticket/13404.

Comment 4 Gwyn Ciesla 2022-12-07 20:40:03 UTC
That didn't include the patch I needed but inspired the correct fix. Thanks!

Comment 5 Gwyn Ciesla 2022-12-07 20:40:22 UTC
*** Bug 2149630 has been marked as a duplicate of this bug. ***

Comment 6 Fedora Update System 2022-12-07 20:52:37 UTC
FEDORA-2022-ae44d52eb8 has been submitted as an update to Fedora 37. https://bodhi.fedoraproject.org/updates/FEDORA-2022-ae44d52eb8

Comment 7 Fedora Update System 2022-12-07 20:52:38 UTC
FEDORA-2022-91ad6abf57 has been submitted as an update to Fedora 36. https://bodhi.fedoraproject.org/updates/FEDORA-2022-91ad6abf57

Comment 8 Fedora Update System 2022-12-07 22:17:21 UTC
FEDORA-2022-e71e1b1eb6 has been submitted as an update to Fedora 38. https://bodhi.fedoraproject.org/updates/FEDORA-2022-e71e1b1eb6

Comment 9 Fedora Update System 2022-12-07 22:20:13 UTC
FEDORA-2022-e71e1b1eb6 has been pushed to the Fedora 38 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 10 Fedora Update System 2022-12-08 02:10:41 UTC
FEDORA-2022-ae44d52eb8 has been pushed to the Fedora 37 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2022-ae44d52eb8`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2022-ae44d52eb8

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 11 Fedora Update System 2022-12-08 02:53:45 UTC
FEDORA-2022-91ad6abf57 has been pushed to the Fedora 36 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2022-91ad6abf57`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2022-91ad6abf57

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 12 Fedora Update System 2022-12-16 01:42:59 UTC
FEDORA-2022-91ad6abf57 has been pushed to the Fedora 36 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 13 Fedora Update System 2022-12-16 01:56:39 UTC
FEDORA-2022-ae44d52eb8 has been pushed to the Fedora 37 stable repository.
If problem still persists, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.