software-properties SRU stopped due to odd bug
Bryce Harrington
bryce.harrington at canonical.com
Mon Dec 13 04:36:01 UTC 2021
On Mon, Dec 13, 2021 at 03:50:10PM +1300, Robert Ancell wrote:
> Hi all,
>
> I have a software-properties SRU [1] in bionic that has phasing stopped due
> to an error [2].
>
> The stack trace is showing the following (new) code is failing:
>
> di = distro_info.UbuntuDistroInfo()
> releases = di.get_all(result="object")
>
> with the error:
>
> AttributeError: 'UbuntuDistroInfo' object has no attribute 'get_all'
>
> This is very confusing, since the code from this (from the distro-info
> library) is essentially:
>
> class DistroInfo:
> def get_all(self, result="codename"):
> ...
>
> class UbuntuDistroInfo(DistroInfo):
> def __init__(self):
> super().__init__("Ubuntu")
>
> i.e. I can't see any reason why the `di` object would not have a get_all()
> method. Running software-properties and various test scripts on a bionic VM
> I haven't been able to reproduce any such issues.
>
> Theories that have been proposed:
> - The user is actually running an older version of disto-info that was from
> before this method was added (in distro-info 0.15).
> - Seems unlikely since there are error cases in which the install was
> done with a bionic image.
> - The user has a locally installed version of distro-info.
> - Stacktraces shows the system installed version, the appropriate version
> of the binary installed, no PYTHONPATH set.
> - A .pyc is being used that doesn't match the source.
> - Since installs have been from bionic media, it seems impossible that an
> older .pyc could be created.
> - Other code has removed this method.
> - Method is being accessed immediately, no other code seen in source that
> could do this.
> - Memory corruption.
> - Too many cases for error to be random, not seeing other similar issues.
>
> Does anyone have any ideas about what might be going on?
Could it be an old pip-installed version of distro-info?
(C.f. LP: #1848829, #1874250)
Bryce
> --Robert
>
> [1] https://launchpad.net/ubuntu/+source/software-properties/0.96.24.32.18
> [2]
> https://errors.ubuntu.com/problem/477791e8cc662f8dca46050bb638e273028a522f
> --
> ubuntu-devel mailing list
> ubuntu-devel at lists.ubuntu.com
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-devel
More information about the ubuntu-devel
mailing list