[Bug 1822733] Re: "sipconfig.Configuration().sop_mod_dir" returns non existing path in python3.

Dmitry Shachnev mitya57 at gmail.com
Tue Apr 2 14:58:36 UTC 2019


Thanks for reporting this! I acknowledge this bug.

But sipconfig is deprecated and should not be used anymore — it will be
removed in SIP v5. The upstream developer recommends copying
Python/configure.py from QScintilla [1] and using that code as a
boilerplate.

So I am giving this bug a low priority.

[1]: https://www.riverbankcomputing.com/software/qscintilla/download

** Changed in: sip4 (Ubuntu)
       Status: New => Triaged

** Changed in: sip4 (Ubuntu)
   Importance: Undecided => Low

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

Title:
  "sipconfig.Configuration().sop_mod_dir" returns non existing path in
  python3.

Status in sip4 package in Ubuntu:
  Triaged

Bug description:
  As suggested here:
  https://answers.launchpad.net/ubuntu/+source/sip4/+question/679701

  I forward this issue here as a BR.

  I've got a trouble with sip on Ubuntu 18.04 64 bit (4.18.0-16-generic
  x86_64 GNU/Linux).

  $ lsb_release -rd
    Description:	Ubuntu 18.04.2 LTS
    Release:	18.04

  I must rely on the official Ubuntu packages to build a software
  depending on "sip", so "python3-sip" and "python3-sip-dev" packages
  are installed from apt-get.

  Here are the commands from a python3 console:

  >>> import sipconfig
  >>> sipcfg = sipconfig.Configuration()
  >>> print("sip_version_str:%s" % sipcfg.sip_version_str)
      sip_version_str:4.19.7
  >>> print("sip_module_dir:%s" % sipcfg.sip_mod_dir)
      sip_module_dir:/usr/lib/python3.6/dist-packages

  But "/usr/lib/python3.6/dist-packages" is not a valid path.

  I either have; "/usr/lib/python3/dist-packages" ("3" instead of "3.6" append to "python" in path name)
  or; "/usr/lib/python3.6/site-packages" which is almost empty (with only one unrelated folder there: "indicator_keyboard").
  Actually, "sipconfig.py" is located in the previous folder (i.e. "/usr/lib/python3/dist-packages/" ).

  It is possible something should be updated in "sipcfg.sip_mod_dir"
  definition...? Probably with some tests to check if path exists...?

  The version of the "sip" shipped from the official Ubuntu 18.04
  repositories is: 4.19.7.

  More informations:

  $ find /usr -iname "*sipconfig*"
    /usr/lib/python3/dist-packages/sipconfig.py
    /usr/lib/python3/dist-packages/sipconfig_nd6.py
    /usr/lib/python3/dist-packages/__pycache__/sipconfig_nd6.cpython-36.pyc
    /usr/lib/python3/dist-packages/__pycache__/sipconfig.cpython-36.pyc

  $ find /usr/bin -iname "*sip*"
    /usr/bin/dh_sip
    /usr/bin/lsipc
    /usr/bin/sip
    /usr/bin/dh_sip3

  $ find /usr/include/python3.6* -iname "*sip*"
   /usr/include/python3.6dm/sip.h
   /usr/include/python3.6m/sip.h

  $ sip -V
    4.19.7

  $ which sip
    /usr/bin/sip

  $ apt-cache policy python3-sip
    python3-sip:
      Installed: 4.19.7+dfsg-1
      Candidate: 4.19.7+dfsg-1
      Version table:
     *** 4.19.7+dfsg-1 500
            500 http://ch.archive.ubuntu.com/ubuntu bionic/universe amd64 Packages
            100 /var/lib/dpkg/status

  $ apt-cache policy python3-sip-dev
    python3-sip-dev:
      Installed: 4.19.7+dfsg-1
      Candidate: 4.19.7+dfsg-1
      Version table:
     *** 4.19.7+dfsg-1 500
            500 http://ch.archive.ubuntu.com/ubuntu bionic/universe amd64 Packages
            100 /var/lib/dpkg/status

  $ apt-cache policy sip-dev
    sip-dev:
      Installed: 4.19.7+dfsg-1
      Candidate: 4.19.7+dfsg-1
      Version table:
     *** 4.19.7+dfsg-1 500
            500 http://ch.archive.ubuntu.com/ubuntu bionic/universe amd64 Packages
            100 /var/lib/dpkg/status

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



More information about the foundations-bugs mailing list