Python Forum
ImportError: cannot import name 'Union' from '_ctypes' (unknown location)
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
ImportError: cannot import name 'Union' from '_ctypes' (unknown location)
#15
If I start from compiled package cannot add modules

pkgadd -d python-3.2.2-sol10-sparc-local

The following packages are available:
1 SMCpyth3 python
(sparc) 3.2.2

Select package(s) you wish to process (or 'all' to process
all packages). (default: all) [?,??,q]: 1

Processing package instance <SMCpyth3> from </presidio_sun/SUNFREEWARE/python/python-3.2.2-sol10-sparc-local>

python(sparc) 3.2.2
The Python Group
Using </usr/local> as the package base directory.
## Processing package information.
## Processing system information.
8 package pathnames are already properly installed.
## Verifying disk space requirements.
## Checking for conflicts with packages already installed.
## Checking for setuid/setgid programs.

Installing python as <SMCpyth3>

## Installing part 1 of 1.
/usr/local/bin/2to3 <symbolic link>
/usr/local/bin/2to3-3.2
/usr/local/bin/idle3 <symbolic link>
/usr/local/bin/idle3.2
/usr/local/bin/pydoc3 <symbolic link>
/usr/local/bin/pydoc3.2
/usr/local/bin/python3
/usr/local/bin/python3-config <symbolic link>
........

/usr/local/bin/python3
Python 3.2.2 (default, Nov 16 2011, 05:23:55)
[GCC 3.4.6] on sunos5
Type "help", "copyright", "credits" or "license" for more information.
>>>

cd pysftp-0.2.9$
/usr/local/bin/python3 setup.py install
Traceback (most recent call last):
File "setup.py", line 3, in <module>
from setuptools import setup
ImportError: No module named setuptools

/usr/local/bin/python3
Python 3.2.2 (default, Nov 16 2011, 05:23:55)
[GCC 3.4.6] on sunos5
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> sys.path
['', '/usr/local/lib/python32.zip', '/usr/local/lib/python3.2', '/usr/local/lib/python3.2/plat-sunos5', '/usr/local/lib/python3.2/lib-dynload', '/usr/local/lib/python3.2/site-packages']
>>>

find /usr/local/ -name _socket*
/usr/local/lib/python3.8/site-packages/_socket.so
/usr/local/lib/python3.8/lib-dynload/_socket.so
Reply


Messages In This Thread
RE: ImportError: cannot import name 'Union' from '_ctypes' (unknown location) - by ciuffoly - Sep-24-2020, 02:22 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
Question Cannot import easysnmp: ImportError: libnetsnmp.so.30 Calab 4 1,310 Jun-08-2023, 08:52 PM
Last Post: Gribouillis
  ImportError: cannot import name 'Pyfhel' from 'Pyfhel' Anldra12 9 3,867 Dec-13-2021, 06:55 PM
Last Post: Anldra12
  ImportError: cannot import name 'get_config' russray2008 0 4,931 Sep-20-2021, 02:18 PM
Last Post: russray2008
  Inheritance vs Union gserranowong 3 2,457 Jun-29-2021, 06:13 PM
Last Post: gserranowong
  ImportError: cannot import name 'Request' from 'request' abhishek81py 1 4,085 Jun-18-2020, 08:07 AM
Last Post: buran
  ImportError: cannot import name 'MidiEvaluator' from 'parser' (Windows 10) spiffspaceman 4 2,861 May-22-2020, 10:16 PM
Last Post: snippsat
  ImportError: cannot import name 'X ' from ' Y' (Unknown location) Arjunpi 1 4,533 Apr-30-2020, 12:56 AM
Last Post: Larz60+
  Lists union and intersecion arbiel 5 3,056 Mar-28-2020, 05:57 AM
Last Post: buran
  Where could I get _ctypes module except libffi-dev? Snake 7 8,564 Jan-17-2020, 11:10 AM
Last Post: Larz60+
  problem with mapnik in anaconda python 2: from _mapnik import * ImportError: DLL load parsley 0 2,005 Dec-11-2019, 07:50 AM
Last Post: parsley

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020