Bug 1028010

Summary: ImportError: /usr/lib64/python2.7/site-packages/pycurl.so: undefined symbol: _PyTrash_thread_deposit_object
Product: [openSUSE] openSUSE Distribution Reporter: Forgotten User Si7ddX0wxG <forgotten_Si7ddX0wxG>
Component: BasesystemAssignee: Jan Matejek <jmatejek>
Status: RESOLVED INVALID QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None CC: forgotten_Si7ddX0wxG, mpluskal
Version: Leap 42.1Flags: jmatejek: needinfo? (forgotten_Si7ddX0wxG)
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: steps to reproduce error
strace -e open createrepo

Description Forgotten User Si7ddX0wxG 2017-03-05 10:58:20 UTC
Hello,

can repeat this error.
Could a downgrade of something be needed to fix bug [python] ?
--Glenn

strace of command see[1]

Steps used:see attachment:

# md /tmp/x
# cd /tmp/x
# createrepo `pwd`
Traceback (most recent call last):
  File "/usr/share/createrepo/genpkgmetadata.py", line 29, in <module>
    import createrepo
  File "/usr/lib64/python2.7/site-packages/createrepo/__init__.py", line 21, in <module>
    import yumbased
  File "/usr/lib64/python2.7/site-packages/createrepo/yumbased.py", line 26, in <module>
    from yum.packages import YumLocalPackage
  File "/usr/lib64/python2.7/site-packages/yum/__init__.py", line 52, in <module>
    import config
  File "/usr/lib64/python2.7/site-packages/yum/config.py", line 30, in <module>
    from parser import ConfigPreProcessor, varReplace
  File "/usr/lib64/python2.7/site-packages/yum/parser.py", line 4, in <module>
    import urlgrabber
  File "/usr/lib/python2.7/site-packages/urlgrabber/__init__.py", line 53, in <module>
    from grabber import urlgrab, urlopen, urlread
  File "/usr/lib/python2.7/site-packages/urlgrabber/grabber.py", line 427, in <module>
    import pycurl
ImportError: /usr/lib64/python2.7/site-packages/pycurl.so: undefined symbol: _PyTrash_thread_deposit_object
Comment 1 Forgotten User Si7ddX0wxG 2017-03-05 11:05:55 UTC
Created attachment 716347 [details]
steps to reproduce error
Comment 2 Jan Matejek 2017-03-07 13:09:31 UTC
hello,

> # python -V
> Python 2.7.3

What distribution is this? We do not maintain a Python 2.7.3 anywhere, AFAIK ... looking into history, this would be openSUSE 12.3?

> python-pycurl-7.19.3.1-2.1.6.x86_64
Also can't find a distribution carrying pycurl 7.19.3.1. Is this some sort of custom repo, maybe building backports?

Otherwise I'm afraid you can't just mix and match distributions like this...
Maybe try to install matching python, python-pycurl and libcurl4 from Leap 42.1 and try again?
Comment 3 Forgotten User Si7ddX0wxG 2017-03-08 00:20:23 UTC
Hello,
- updated ibcurl4

#error message changed,now is:
"ImportError: pycurl: libcurl link-time version (7.37.0) is older than compile-time version (7.38.0)"

What rpms need updating ?
--Cheers Glenn

steps used:

#
# zypper up python python-pycurl  libcurl4 
Loading repository data..
Warning: Repository '42.3updates-oss' appears to be outdated. Consider using a different mirror or server.
Reading installed packages..
No update candidate for 'python-2.7.12-25.18.x86_64'. The highest available version is already installed.
No update candidate for 'python-pycurl-7.19.3.1-2.1.6.x86_64'. The highest available version is already installed.
Resolving package dependencies..

The following package is going to be upgraded:
  libcurl4

1 package to upgrade.
Overall download size: 198.9 KiB. Already cached: 0 B. After the operation, additional 40.1 KiB will be used.
Continue? [y/n/? shows all options] (y): y
Retrieving package libcurl4-7.37.0-16.4.x86_64                                                                                                            (1/1), 198.9 KiB (449.4 KiB unpacked)
Retrieving: libcurl4-7.37.0-16.4.x86_64.rpm .......................................................................[done]
Checking for file conflicts: ..............................................................................[done]
(1/1) Installing: libcurl4-7.37.0-16.4.x86_64 ......................................................................[done]
# rpm -qa |grep -i libcurl4
libcurl4-7.37.0-16.4.x86_64

# createrepo
Traceback (most recent call last):
  File "/usr/share/createrepo/genpkgmetadata.py", line 29, in <module>
    import createrepo
  File "/usr/lib64/python2.7/site-packages/createrepo/__init__.py", line 21, in <module>
    import yumbased
  File "/usr/lib64/python2.7/site-packages/createrepo/yumbased.py", line 26, in <module>
    from yum.packages import YumLocalPackage
  File "/usr/lib64/python2.7/site-packages/yum/__init__.py", line 52, in <module>
    import config
  File "/usr/lib64/python2.7/site-packages/yum/config.py", line 30, in <module>
    from parser import ConfigPreProcessor, varReplace
  File "/usr/lib64/python2.7/site-packages/yum/parser.py", line 4, in <module>
    import urlgrabber
  File "/usr/lib/python2.7/site-packages/urlgrabber/__init__.py", line 53, in <module>
    from grabber import urlgrab, urlopen, urlread
  File "/usr/lib/python2.7/site-packages/urlgrabber/grabber.py", line 427, in <module>
    import pycurl
ImportError: pycurl: libcurl link-time version (7.37.0) is older than compile-time version (7.38.0)
Comment 4 Forgotten User Si7ddX0wxG 2017-03-08 01:04:56 UTC
Hello,
- updated ibcurl4

#error message changed,now is:
"ImportError: pycurl: libcurl link-time version (7.37.0) is older than compile-time version (7.38.0)"

What rpms need updating ?
--Cheers Glenn

steps used:

#
# zypper up python python-pycurl  libcurl4 
Loading repository data.
Reading installed packages.
No update candidate for 'python-2.7.12-25.18.x86_64'. The highest available version is already installed.
No update candidate for 'python-pycurl-7.19.3.1-2.1.6.x86_64'. The highest available version is already installed.
Resolving package dependencies.

The following package is going to be upgraded:
  libcurl4

1 package to upgrade.
Overall download size: 198.9 KiB. Already cached: 0 B. After the operation, additional 40.1 KiB will be used.
Continue? [y/n/? shows all options] (y): y
Retrieving package libcurl4-7.37.0-16.4.x86_64                                                                                                            (1/1), 198.9 KiB (449.4 KiB unpacked)
Retrieving: libcurl4-7.37.0-16.4.x86_64.rpm ....................................[done]
Checking for file conflicts: .......................................[done]
(1/1) Installing: libcurl4-7.37.0-16.4.x86_64 ...................................[done]
# rpm -qa |grep -i libcurl4
libcurl4-7.37.0-16.4.x86_64

# createrepo
Traceback (most recent call last):
  File "/usr/share/createrepo/genpkgmetadata.py", line 29, in <module>
    import createrepo
  File "/usr/lib64/python2.7/site-packages/createrepo/__init__.py", line 21, in <module>
    import yumbased
  File "/usr/lib64/python2.7/site-packages/createrepo/yumbased.py", line 26, in <module>
    from yum.packages import YumLocalPackage
  File "/usr/lib64/python2.7/site-packages/yum/__init__.py", line 52, in <module>
    import config
  File "/usr/lib64/python2.7/site-packages/yum/config.py", line 30, in <module>
    from parser import ConfigPreProcessor, varReplace
  File "/usr/lib64/python2.7/site-packages/yum/parser.py", line 4, in <module>
    import urlgrabber
  File "/usr/lib/python2.7/site-packages/urlgrabber/__init__.py", line 53, in <module>
    from grabber import urlgrab, urlopen, urlread
  File "/usr/lib/python2.7/site-packages/urlgrabber/grabber.py", line 427, in <module>
    import pycurl
ImportError: pycurl: libcurl link-time version (7.37.0) is older than compile-time version (7.38.0)
Comment 5 Forgotten User Si7ddX0wxG 2017-03-08 03:25:14 UTC
# cd /

# find . | grep -i libcurl.so.4
./usr/lib64/libcurl.so.4
./usr/lib64/libcurl.so.4.3.0

# ldconfig -v | grep -i libcurl
ldconfig: Can't stat /libx32: No such file or directory
ldconfig: Can't stat /usr/libx32: No such file or directory
        libcurl.so.4 -> libcurl.so.4.3.0

# ll ./usr/lib64/libcurl.so.4 ./usr/lib64/libcurl.so.4.3.0
lrwxrwxrwx 1 root root     16 Mar  8 02:32 ./usr/lib64/libcurl.so.4 -> libcurl.so.4.3.0
-rwxr-xr-x 1 root root 460136 Dec  3 19:20 ./usr/lib64/libcurl.so.4.3.0
Comment 6 Forgotten User Si7ddX0wxG 2017-03-08 03:33:02 UTC
# find . | grep -i libcurl.so.4
./usr/lib64/libcurl.so.4
./usr/lib64/libcurl.so.4.3.0

# ll ./usr/lib64/libcurl.so.4 ./usr/lib64/libcurl.so.4.3.0
lrwxrwxrwx 1 root root     16 Mar  8 02:32 ./usr/lib64/libcurl.so.4 -> libcurl.so.4.3.0
-rwxr-xr-x 1 root root 460136 Dec  3 19:20 ./usr/lib64/libcurl.so.4.3.0
Comment 7 Forgotten User Si7ddX0wxG 2017-03-08 03:46:39 UTC
# rpm -qa | grep -i libcurl4
libcurl4-7.37.0-16.4.x86_64
Comment 8 Forgotten User Si7ddX0wxG 2017-03-08 04:15:11 UTC
# zypper up libcurl4
Loading repository data...
Reading installed packages...
No update candidate for 'libcurl4-7.37.0-16.4.x86_64'. The highest available version is already installed.
Resolving package dependencies...

Nothing to do.

# find . | grep -i libcurl.so.4
./usr/lib64/libcurl.so.4
./usr/lib64/libcurl.so.4.3.0

# rpm -qa | grep -i libcurl4
libcurl4-7.37.0-16.4.x86_64

 # createrepo
Traceback (most recent call last):
  File "/usr/share/createrepo/genpkgmetadata.py", line 29, in <module>
    import createrepo
  File "/usr/lib64/python2.7/site-packages/createrepo/__init__.py", line 21, in <module>
    import yumbased
  File "/usr/lib64/python2.7/site-packages/createrepo/yumbased.py", line 26, in <module>
    from yum.packages import YumLocalPackage
  File "/usr/lib64/python2.7/site-packages/yum/__init__.py", line 52, in <module>
    import config
  File "/usr/lib64/python2.7/site-packages/yum/config.py", line 30, in <module>
    from parser import ConfigPreProcessor, varReplace
  File "/usr/lib64/python2.7/site-packages/yum/parser.py", line 4, in <module>
    import urlgrabber
  File "/usr/lib/python2.7/site-packages/urlgrabber/__init__.py", line 53, in <module>
    from grabber import urlgrab, urlopen, urlread
  File "/usr/lib/python2.7/site-packages/urlgrabber/grabber.py", line 427, in <module>
    import pycurl
ImportError: pycurl: libcurl link-time version (7.37.0) is older than compile-time version (7.38.0)
#
Question: How to I downgrade the compile-time version (7.38.0) to match the   link-time version ?

What is rpm called ?
Thanks
--Glenn
Comment 9 Forgotten User Si7ddX0wxG 2017-03-08 04:34:29 UTC
# rpm -qa | grep -i "7.3[]7-8].0"
libcurl4-7.37.0-16.4.x86_64
Comment 10 Forgotten User Si7ddX0wxG 2017-03-08 04:47:03 UTC
# rpm -qa | grep -i curl | sort
curl-7.28.1-4.47.1.x86_64
libcurl4-7.37.0-16.4.x86_64
python-pycurl-7.19.3.1-2.1.6.x86_64
Comment 11 Forgotten User Si7ddX0wxG 2017-03-08 07:12:14 UTC
# cat /usr/share/createrepo/genpkgmetadata.py |wc -l
324

# cat /usr/share/createrepo/genpkgmetadata.py |head -29 |tail
# written by seth vidal skvidal at fedoraproject.org

import os
import sys
import re
from optparse import OptionParser,SUPPRESS_HELP
import time
import errno

import createrepo
Comment 12 Forgotten User Si7ddX0wxG 2017-03-08 07:40:17 UTC
Created attachment 716700 [details]
strace -e open createrepo

# strace -e open createrepo
Comment 13 Forgotten User Si7ddX0wxG 2017-03-08 07:50:48 UTC
/usr/lib64/python2.7/site-packages # rpm -qf pycurl.so
python-pycurl-7.19.3.1-2.1.6.x86_64
Comment 14 Jan Matejek 2017-03-08 13:00:35 UTC
which distribution are you using?
Comment 15 Forgotten User Si7ddX0wxG 2017-03-10 06:54:37 UTC
solved.
updated 'libcurl\|pycurl

# rpm -qa | grep 'libcurl\|pycurl'  |sort
libcurl4-7.37.0-16.4.x86_64
python-pycurl-7.19.0-5.4.x86_64
python3-pycurl-7.19.5.1-4.2.x86_64

# createrepo /tmp/xx
Saving Primary metadata
Saving file lists metadata
Saving other metadata

from log: /var/log/zypp/history

2017-03-10 17:08:31|install|python-pycurl|7.19.0-5.4|x86_64|root@test.site|tumbleweed-oss|81eca1676e42ceef3626ce220390f68389a945038e7ef8cb851392b074bb1a5a|
2017-03-10 17:08:31|install|python3-pycurl|7.19.5.1-4.2|x86_64|root@test.site|tumbleweed-oss|9897ca18587c688dc1dbd879cadd732c6d249633e90b8fa5661e1e9ab7c1ff45|
2017-03-10 17:10:14|command|root@test.site|'/usr/lib/YaST2/bin/y2base' 'sw_single' 'qt'|
2017-03-10 17:10:14|install|libcurl4|7.37.0-16.4|x86_64|root@test.site|tumbleweed-oss|ecd816cbe3e44dd8373fe4ce4391c0a16be4f933c7706ef50a67e9482bc093a7|

zypper links used:
http://mirrors1.kernel.org/opensuse/distribution/leap/42.3/repo/oss/suse/
http://mirrors1.kernel.org/opensuse/distribution/leap/42.3/repo/non-oss/suse/


# rpm -qa | grep 'libcurl\|pycurl'  |sort
libcurl4-7.37.0-16.4.x86_64
python-pycurl-7.19.0-5.4.x86_64
python3-pycurl-7.19.5.1-4.2.x86_64

# createrepo /tmp/xx
Saving Primary metadata
Saving file lists metadata
Saving other metadata
#

closing thiis off
--Glenn
Comment 16 Martin Pluskal 2017-07-31 21:40:34 UTC
Nothing was fixed actually - report is for unsupported version of python.
Comment 17 Martin Pluskal 2017-07-31 21:41:38 UTC
*** Bug 1028831 has been marked as a duplicate of this bug. ***