[Bug 2042356] Re: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction
Hi Sudip, I've already used these packages with one of my wiimotes on an earlier version of Ubuntu. And they worked fine. I see that the packages wminput and wmgui are only available on Jammy (22.04) and above, based on https://packages.ubuntu.com/search?keywords=wminput I started a live-USB of Ubuntu Focal 20.04.6 on a PC, and apt indeed does not find wminput or wmgui. I suspect it's because of the python2->python3 switch, at that time. So I started a live-USB of Ubuntu Bionic 18.04.6 on the same PC, and could install the 3 packages (they don't show up in https://packages.ubuntu.com/search?keywords=wminput because this Ubuntu version is not supported any more) I can confirm that it works fine on Ubuntu 18.04: wminput displays a "Ready." message after pairing with the wiimote, and buttons/gyroscope of the wiimote have the expected effect on the Ubuntu desktop: move cursor or pointer $ sudo wminput Put Wiimote in discoverable mode now (press 1+2)... Ready. wmgui also works fine on Ubuntu 18.04: sensors and buttons states are properly shown NB: after pairing the wiimote with Ubuntu 18.04, its leds are all off, just like on Ubuntu 22.04 or 24.04. So what I suspected to be a "crashed" state of the wiimote seems to be its normal state with wminput/wmgui -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2042356 Title: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cwiid/+bug/2042356/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 2042356] Re: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction
Removing ubuntu-sponsors for now as clearly this bug fix alone is not enough. Hi mosroy, Sorry for the delayed reply. I will check the code and try to add debugs to find out whats happening. But meanwhile, will it be possible to test Focal (20.04) also to confirm if wminput/wmgui works there or not. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2042356 Title: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cwiid/+bug/2042356/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 2042356] Re: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction
With the same hardware (PC+wiimote), I've tested with Ubuntu 24.04 (with a live USB). With distro packages (not the ones from the PPA), I see the exact same behavior: no error message, wiimote seems crashed -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2042356 Title: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cwiid/+bug/2042356/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 2042356] Re: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction
Hi Sudip, I've tested the packages from your ppa (after an add-apt-repository, and removing them locally, to make sure they all come from the PPA) They can be installed with no issue, and the python errors do not show up any more. However, when I run wminput , it does not work. I put my wiimote in discovery mode: buttons 1+2 pushed, blinking leds, and run the command: $ sudo wminput Put Wiimote in discoverable mode now (press 1+2)... After a few seconds (less than 5), the leds stop blinking, and stay off on the wiimote. Nothing more appears on the PC, and the wiimote seems to be "crashed". Using any button on it has no effect: nothing on the PC, and no blinking led on the wiimote. I need to remove the batteries the wiimote, and put them again, to restore a "normal" state of the wiimote, where using any button makes the leds blink for a short moment. I've reproduced that with 2 different wiimotes, and on 2 different computers (both running Ubuntu 22.04.4 with latest patches. One with kernel 5.15.0-105-generic, the other one with 6.5.0-28-generic) To sum up, the Python import error seems to be solved, but there's probably another issue that prevents wminput to work. With wmgui, the wiimote behavior is the same, and a popup "wmgui does not answer" appears on the desktop I'd be glad to help debugging, but don't find any "verbose" or similar option to get more info -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2042356 Title: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cwiid/+bug/2042356/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 2042356] Re: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction
Hi mossroy, Can you please try the ppa at https://launchpad.net/~sudipmuk/+archive/ubuntu/cwiid/. Please make sure that libcwiid and python3-cwiid are also installed from this ppa. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2042356 Title: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cwiid/+bug/2042356/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 2042356] Re: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction
Hi Miriam, The changes in the libwiicd and the other changes that I left out looked like general improvement to the code and is introducing new features which are not related to this bug report. The changes in the Makefile and setup.py are also not related to this bug report. The comments that are not imported are removing the changelog from the source code and also updating the copyright. Those chages are done by new upstream who has forked the old repo and added Python3 support and also made the improvements. imho, these are ok for a new version but might not be appropriate for a SRU (please correct me if I am wrong). -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2042356 Title: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cwiid/+bug/2042356/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 2042356] Re: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction
Hi Sudip! I reviewed the patch, and I have a few questions: - The patch seems to be one of the commits of the MR accepted on Debian on 976439 (the last one in fact). Would the commit a7ac2dbdc122115b5603f595c56cc55a6f09dca3 "Also add libwiicd patches. " be needed? - The patch is for commit https://salsa.debian.org/georgesk/cwiid/-/blob/e7cebe40c94b05e97f07302c36e93f60482b0ae5/debian/patches/python3-build-azzra, but is not completely imported: - Makefile.in is not imported in the patch (maybe is this related to the commit a7ac2db (the one I pointed to in the previous question?) Why are some parts of the original commit (change comments, e.g.) not imported into the patch? Could you give us more information about this elections? I build the package with the patch (it builds OK) and I didn't test yet -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2042356 Title: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cwiid/+bug/2042356/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 2042356] Re: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction
I have this same issue, and have a wiimote to test with. Is there a .deb file generated with this patch, that I could try? -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2042356 Title: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cwiid/+bug/2042356/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 2042356] Re: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction
debdiff for Jammy attached. ** Summary changed: - wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction + [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction ** Description changed: + [ Impact ] + + wminput is completey unusable as it will immediately crash with + undefined symbol error. + + $ sudo wminput + ImportError: /usr/lib/python3/dist-packages/cwiid.cpython-310-x86_64-linux-gnu.so: undefined symbol: PyVarObject_CallFunction + + This is mostly because the code was not properly ported to Python-3. + + [ Test Plan ] + + 1. install wminput + 2. execute wminput with a mac address + + If the package is not fixed, it will fail with undefined symbol error. + + Ideally someone with the hardware should test. + + [ Where problems could occur ] + + There are changes in the code and there are chances of regression due to + this change. But wminput as of now is already unusable, so any + regression can not be worse than that. + + [ Other Info ] + + The patch, even though looks big is mostly changing all the PyVarObject to PyObject, and few other changes. + Initially I tried to pick only the changes for PyVarObject but that resulted in errors for PyInt_FromLong. After fixing that, errors from PyCObject_Check appeared. So, I thought its best to use all the fixes from the Debian patch. + + + [ Original Bug Description ] + When trying to invoke wminput I get the following: james@thelio:~$ sudo wminput [redacted MAC address] ImportError: /usr/lib/python3/dist-packages/cwiid.cpython-310-x86_64-linux-gnu.so: undefined symbol: PyVarObject_CallFunction This is a duplicate of 1958466, but I could not run apport-collect against it because it was not my bug. Since it's been orphaned for over a year, I made this bug and ran apport-bug to file it. I'm happy to provide any additional data. ProblemType: Bug DistroRelease: Ubuntu 22.04 Package: wminput 0.6.91-2ubuntu1 Uname: Linux 6.5.4-76060504-generic x86_64 ApportVersion: 2.20.11-0ubuntu82.5 Architecture: amd64 CasperMD5CheckResult: unknown CurrentDesktop: MATE Date: Tue Oct 31 14:35:47 2023 InstallationDate: Installed on 2020-10-27 (1099 days ago) InstallationMedia: Ubuntu-MATE 20.04.1 LTS "Focal Fossa" - Release amd64 (20200731) SourcePackage: cwiid UpgradeStatus: Upgraded to jammy on 2022-08-12 (445 days ago) ** Patch added: "cwiid_jammy.debdiff" https://bugs.launchpad.net/debian/+source/cwiid/+bug/2042356/+attachment/5769545/+files/cwiid_jammy.debdiff ** Changed in: cwiid (Ubuntu Jammy) Status: In Progress => Confirmed ** Changed in: cwiid (Ubuntu Jammy) Assignee: Sudip Mukherjee (sudipmuk) => (unassigned) -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2042356 Title: [SRU] wminput crashes with ImportError: ... undefined symbol: PyVarObject_CallFunction To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/cwiid/+bug/2042356/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs