Your message dated Mon, 13 Jan 2025 11:36:43 +0000
with message-id <e1txikn-00dbfq...@fasolo.debian.org>
and subject line Bug#1092627: fixed in pyracerz 0.2+dfsg-4
has caused the Debian Bug report #1092627,
regarding pyracerz: Tracks fail to load: 'ConfigParser' object has no attribute
'readfp'
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)
--
1092627: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1092627
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: pyracerz
Version: 0.2+dfsg-3
Severity: important
Tags: patch upstream
X-Debbugs-Cc: sma...@sdf.org
Dear Maintainer,
*** Reporter, please consider answering these questions, where appropriate ***
* What led up to the situation?
I started the game and made menu selections up to the point when
the race should start.
* What exactly did you do (or not do) that was effective (or
ineffective)?
1. I started pyracerz from the command line and the opening screen
came up with a race car sound. The xterm I start it from showed
these messages:
12% pyracerz
pygame 2.6.1 (SDL 2.30.11, Python 3.13.1)
Hello from the pygame community. https://www.pygame.org/contribute.html
Cannot use psyCo...
2. From the opening menu I pressed enter with "Single Race" selected.
3. The screen changed to one with header "singleRace: chooseTrack.
I pressed enter with the default < bio > track selected.
4. Next came the screen with header "singleRace: chooseNbLaps" I
pressed enter with 1 selected.
5. Next it was "singleRace: chooseNbHumanPlayers". I down arrowed
to 1 and pressed enter.
6. Next "singleRace: chooseHumanPlayer1". I pressed up error to
select GO and pressed enter, which accepted the default settings.
7. Next "singleRace: chooseNbRobotPlayers". I pressed enter with 0
selected.
8. The graphical window closed, the program terminated, and the
xterm I started it from showed these two new messages:
Cannot load track :
'ConfigParser' object has no attribute 'readfp'
* What was the outcome of this action?
The game couldn't be played. Only the options could selected.
The error messages above appeared on my xterm.
* What outcome did you expect instead?
For the race to start.
It looks like python 3.2 removed readfp from the ConfigParser class
and replaced it with read_file. You can see
"New in version 3.2: Replaces readfp()" under the read_file entry
here in Python 3.2 documentation:
https://docs.python.org/3.2/library/configparser.html#configparser-objects
Contrast that with Python 3.1 documentation that still has readfp
(under the RawConfigParser base class):
https://docs.python.org/3.1/library/configparser.html#rawconfigparser-objects
When I patched and built the source package locally with readfp
renamed to read_file I could get to the track screen and play the
game. I'm attaching the patch replace-readfp.patch which should
apply cleanly after the other patches have applied (i.e. after
font-replacement.patch).
*** End of the template - remove these template lines ***
-- System Information:
Debian Release: trixie/sid
APT prefers unstable
APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Kernel: Linux 6.12.8-amd64 (SMP w/4 CPU threads; PREEMPT)
Kernel taint flags: TAINT_WARN
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
Versions of packages pyracerz depends on:
ii fonts-radisnoir 0.9b-5
ii python3 3.13.1-2
ii python3-pygame 2.6.1-1
pyracerz recommends no packages.
pyracerz suggests no packages.
-- no debconf information
Index: b/modules/menu.py
===================================================================
--- a/modules/menu.py
+++ b/modules/menu.py
@@ -1071,7 +1071,7 @@ class MenuHiscores(Menu):
confFile=configparser.ConfigParser()
try:
- confFile.readfp(open("/var/games/pyracerz/pyracerz.conf", "r"))
+ confFile.read_file(open("/var/games/pyracerz/pyracerz.conf", "r"))
self.nbItem = 0
for sect in confFile.sections():
@@ -1117,7 +1117,7 @@ class MenuHiscores(Menu):
confFile=configparser.ConfigParser()
try:
- confFile.readfp(open("/var/games/pyracerz/pyracerz.conf", "r"))
+ confFile.read_file(open("/var/games/pyracerz/pyracerz.conf", "r"))
except Exception:
return
Index: b/modules/misc.py
===================================================================
--- a/modules/misc.py
+++ b/modules/misc.py
@@ -160,7 +160,7 @@ def addHiScore(track, player):
confFile=configparser.ConfigParser()
try:
- confFile.readfp(open("/var/games/pyracerz/pyracerz.conf", "r"))
+ confFile.read_file(open("/var/games/pyracerz/pyracerz.conf", "r"))
except Exception:
fileExist = 0
@@ -169,7 +169,7 @@ def addHiScore(track, player):
fwrite = open("/var/games/pyracerz/pyracerz.conf", "w+")
confFile.add_section("hi " + track.name)
confFile.write(fwrite)
- confFile.readfp(open("/var/games/pyracerz/pyracerz.conf", "r"))
+ confFile.read_file(open("/var/games/pyracerz/pyracerz.conf", "r"))
# For the Inverse
if track.reverse == 0:
@@ -220,7 +220,7 @@ def getUnlockLevel():
confFile=configparser.ConfigParser()
try:
- confFile.readfp(open("/var/games/pyracerz/pyracerz.conf", "r"))
+ confFile.read_file(open("/var/games/pyracerz/pyracerz.conf", "r"))
except Exception:
return 0
@@ -247,7 +247,7 @@ def setUnlockLevel(lck):
confFile=configparser.ConfigParser()
try:
- confFile.readfp(open("/var/games/pyracerz/pyracerz.conf", "r"))
+ confFile.read_file(open("/var/games/pyracerz/pyracerz.conf", "r"))
except Exception:
fileExist = 0
@@ -255,7 +255,7 @@ def setUnlockLevel(lck):
fwrite = open("/var/games/pyracerz/pyracerz.conf", "w+")
confFile.add_section("unlockLevel")
confFile.write(fwrite)
- confFile.readfp(open("/var/games/pyracerz/pyracerz.conf", "r"))
+ confFile.read_file(open("/var/games/pyracerz/pyracerz.conf", "r"))
h = hashlib.sha1(b"pyRacerz")
h.update(str(lck).encode())
Index: b/modules/track.py
===================================================================
--- a/modules/track.py
+++ b/modules/track.py
@@ -48,7 +48,7 @@ class Track:
self.track = pygame.transform.scale(getImageFromTrackName(name), (int(1024*misc.zoom), int(768*misc.zoom)))
self.trackF = pygame.transform.scale(getImageFFromTrackName(name), (int(1024*misc.zoom), int(768*misc.zoom)))
confFile=configparser.ConfigParser()
- confFile.readfp(open(os.path.join("/usr/share/games/pyracerz/tracks", name + ".conf"), "r"))
+ confFile.read_file(open(os.path.join("/usr/share/games/pyracerz/tracks", name + ".conf"), "r"))
self.name = name
self.author = confFile.get("track", "author")
--- End Message ---
--- Begin Message ---
Source: pyracerz
Source-Version: 0.2+dfsg-4
Done: Alexandre Detiste <tc...@debian.org>
We believe that the bug you reported is fixed in the latest version of
pyracerz, which is due to be installed in the Debian FTP archive.
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to 1092...@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Alexandre Detiste <tc...@debian.org> (supplier of updated pyracerz package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmas...@ftp-master.debian.org)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
Format: 1.8
Date: Mon, 13 Jan 2025 11:30:09 +0100
Source: pyracerz
Architecture: source
Version: 0.2+dfsg-4
Distribution: unstable
Urgency: medium
Maintainer: Debian Games Team <pkg-games-de...@lists.alioth.debian.org>
Changed-By: Alexandre Detiste <tc...@debian.org>
Closes: 1092627
Changes:
pyracerz (0.2+dfsg-4) unstable; urgency=medium
.
* Team upload.
.
[ Mike Small ]
* Fix compatibility with Python 3.13 (Closes: #1092627)
Checksums-Sha1:
b0ea006b29f67bb30f91a3f0c82ac3b556f67fa3 2048 pyracerz_0.2+dfsg-4.dsc
bf4e8e9596a91def964cc0f2c9ca74f5196e8220 15272
pyracerz_0.2+dfsg-4.debian.tar.xz
37dd5b0bce5fb4f29151337a705da6fe0142bf30 6407
pyracerz_0.2+dfsg-4_source.buildinfo
Checksums-Sha256:
48147a30ca52feee43a1ffc5d47e624f33c14db7b4ea26da5592b807f12992d8 2048
pyracerz_0.2+dfsg-4.dsc
f170f3f5d1d5eaeaf2a46c111a2672cfb2375191bbb82a99e36ca1ef3c872746 15272
pyracerz_0.2+dfsg-4.debian.tar.xz
dfa42ade3f51c25a6df3294cf199134b0911c96651eb3ae42ca7a63e9af0f0b9 6407
pyracerz_0.2+dfsg-4_source.buildinfo
Files:
9e9020b9e41ad5ba4f230aa07265e881 2048 games optional pyracerz_0.2+dfsg-4.dsc
2f0ed72337c3ab54060039dcccd9d08b 15272 games optional
pyracerz_0.2+dfsg-4.debian.tar.xz
8ab75a37d08be40c3fe45478a429d185 6407 games optional
pyracerz_0.2+dfsg-4_source.buildinfo
-----BEGIN PGP SIGNATURE-----
iQJFBAEBCgAvFiEEj23hBDd/OxHnQXSHMfMURUShdBoFAmeE620RHHRjaGV0QGRl
Ymlhbi5vcmcACgkQMfMURUShdBpXFA/9H3LgJfMQxHo/8XVW15k6LCyo2FHu7O0v
0lqPkvz72sDpoLWqr+DWEyiIAtxQgNIFB24F2oHiKei2SVLMH2bqo++Sn+6SU0Uy
ClFiSPsrR1i81X6XYMgAaQ9KSYZNWLbJS6sflE+j+uvZH7s1tY4xnsc64TMaVPQ7
A3fiCIV3BaMRRGEU6LXdx+lRUlt+NdO+VDIpM0k0v9dJS9OYZr63HXltbusmX1nB
d3sOnpqvrw84Xn3TXpEDYcD7VimUIFOWrO8z1OBlVDUIo7OCtVl/5GQ9sMZsofmv
jhRMo4YzEzHpsA9GcijX9T3u52zD2RuNKPoDBssOCzcjfhSfWbZ8GXz0mksgzuA9
1lljUJ9Y6SSTmya6KDzoAWsk6T0+l6ZqboK0Gdn+zX/lEu58EgubtHWiq92rZRLr
OWHTDi8wDNtXhzbfHUVv5cM5cvjDcNmdug650IPDxAsETtSURveki/4wi7TBjD4D
oTsDcmjpnsO4gJkuNjNjfXTKiHCyObYjxyPegIjdf4ULzXs0kVOPawL+ol2c7DTs
ON3ZZzrw/cV59fYsKzaxG//4zgz9mJKWCSjvI0H4zUKW5jV1pX9JLPvcuQ7xmvd/
ifCTWtncgVH7eY8I3EOZXGPsoImzRe5iaBFYu4Mev+j/izG8gDcDrg4BA+z4cKyo
3bnDMK7oL0I=
=HICz
-----END PGP SIGNATURE-----
pgpCJbbw3NLvK.pgp
Description: PGP signature
--- End Message ---