Public bug reported:

/usr/lib/python3/dist-packages/hachoir/parser/misc/pdf.py:395: SyntaxWarning: 
'str' object is not callable; perhaps you missed a comma?
  raise ParserError("Can't find '%s' starting at %u"


the bug was fixed in hachoir commit fa5fc55606 titled "Fix SyntaxWarning in 
3.8", dated 2020-06-01. The diff adds the missing %:

  -            raise ParserError("Can't find '%s' starting at %u"
  +            raise ParserError("Can't find '%s' starting at %u" %
                                 (Trailer.MAGIC, self.absolute_address // 8))

It first shipped in release 3.1.2 (2021-02-15) — confirmed present
(broken) in 3.1.1 and fixed in 3.1.2.

That means the Ubuntu Noble package (3.1.0+dfsg-5) predates the fix by
two versions, and the fix has been in upstream release for over 3 years
now — it's an Ubuntu/Debian packaging lag, not an unfixed upstream
issue.

Debian's package (sid/trixie: 3.1.0+dfsg-5/6) is also behind hachoir
upstream, so not an easy thing to solve?

ProblemType: Bug
DistroRelease: Ubuntu 24.04
Package: hachoir 3.1.0+dfsg-5
Uname: Linux 6.13.0-061300-generic x86_64
ApportVersion: 2.28.2-0ubuntu0.1
Architecture: amd64
CasperMD5CheckResult: unknown
CurrentDesktop: ubuntu:GNOME
Date: Sun Jul 26 20:24:16 2026
InstallationDate: Installed on 2024-09-08 (686 days ago)
InstallationMedia: Ubuntu 24.04.1 LTS "Noble Numbat" - Release amd64 
(20240827.1)
PackageArchitecture: all
ProcEnviron:
 LANG=en_US.UTF-8
 PATH=(custom, no user)
 SHELL=/bin/bash
 TERM=xterm-256color
 XDG_RUNTIME_DIR=<set>
RebootRequiredPkgs: Error: path contained symlinks.
SourcePackage: hachoir
UpgradeStatus: No upgrade log present (probably fresh install)

** Affects: hachoir (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: amd64 apport-bug noble wayland-session

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2161844

Title:
  hachoir: SyntaxWarning: 'str' object is not callable; perhaps you
  missed a comma?

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/hachoir/+bug/2161844/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to