Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-138406

policycoreutils - DeprecationWarning: builtin type SwigPyPacked + SwigPyObject

Linking RHIVOS CVEs to...Migration: Automation ...SWIFT: POC ConversionSync from "Extern...XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • rhel-10.0
    • policycoreutils
    • None
    • No
    • Moderate
    • rhel-security-selinux
    • None
    • QE ack
    • False
    • False
    • Hide

      None

      Show
      None
    • None
    • None
    • Hide

      There should be no deprecation warnings when importing the seobject python module.

      Show
      There should be no deprecation warnings when importing the seobject python module.
    • None
    • Automated
    • Unspecified
    • Unspecified
    • Unspecified
    • None

      What were you trying to do that didn't work?

      The warning was found thanks to inspiration from the anaconda team (RHEL-82838).

      Please provide the package NVR for which the bug is seen:

      policycoreutils-3.9-2.el10.x86_64
      python3-policycoreutils-3.9-2.el10.noarch
      policycoreutils-python-utils-3.9-2.el10.noarch

      How reproducible is this bug?

      Always

      Steps to reproduce:

      Minimal reproducer for the swigvarlink DeprecationWarning

      #!/usr/bin/env python3
      import warnings
      warnings.simplefilter('always')
      import seobject
      

      Actual results:

      # python3
      Python 3.12.12 (main, Oct 10 2025, 00:00:00) [GCC 14.3.1 20250617 (Red Hat 14.3.1-2)] on linux
      Type "help", "copyright", "credits" or "license" for more information.
      >>> import warnings
      >>> warnings.simplefilter('always')
      >>> import seobject
      <frozen importlib._bootstrap>:488: DeprecationWarning: builtin type SwigPyPacked has no __module__ attribute
      <frozen importlib._bootstrap>:488: DeprecationWarning: builtin type SwigPyObject has no __module__ attribute
      <frozen importlib._bootstrap>:488: DeprecationWarning: builtin type SwigPyPacked has no __module__ attribute
      <frozen importlib._bootstrap>:488: DeprecationWarning: builtin type SwigPyObject has no __module__ attribute
      >>> 
      

      Expected results:

      An empty output is expected.

      Source of the issue:

      The warning is caused by code generated with the affected SWIG:

      A rebuild against the fixed SWIG will resolve it.

              vmojzis@redhat.com Vit Mojzis
              jplesnik@redhat.com Jitka Plesnikova
              Vit Mojzis Vit Mojzis
              Milos Malik Milos Malik
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated: