LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-25-2013, 05:50 AM   #1
project.linux.proj
Member
 
Registered: Dec 2012
Posts: 78

Rep: Reputation: Disabled
getting errror while installing openpyxl


Hi,

I am getting an error while installing python pkg openpyxl. I tried "easy_install openpyxl" and downling the zip "# /usr/bin/python setup.py install". when i run the command help('modules'). the package doesn't list there.

# easy_install openpyxl
Searching for openpyxl
Best match: openpyxl 1.1.0
Processing openpyxl-1.1.0-py2.4.egg
openpyxl 1.1.0 is already the active version in easy-install.pth

Using /usr/lib/python2.4/site-packages/openpyxl-1.1.0-py2.4.egg
Processing dependencies for openpyxl
=======================================================
# /usr/bin/python setup.py install

byte-compiling build/bdist.linux-x86_64/egg/openpyxl/reader/workbook.py to workbook.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_meta.py to test_meta.pyc
SyntaxError: ('future feature with_statement is not defined',)
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_number_format.py to test_number_format.pyc
SyntaxError: ('future feature with_statement is not defined',)
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_strings.py to test_strings.pyc
File "build/bdist.linux-x86_64/egg/openpyxl/tests/test_strings.py", line 58
with open(osp.join(DATADIR, 'reader', 'sharedStrings.xml')) as f:
^
SyntaxError: invalid syntax

SyntaxError: invalid syntax
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/writer/theme.py to theme.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/writer/workbook.py to workbook.pyc
creating build/bdist.linux-x86_64/egg/EGG-INFO
copying src/openpyxl.egg-info/PKG-INFO -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/openpyxl.egg-info/SOURCES.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/openpyxl.egg-info/dependency_links.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/openpyxl.egg-info/top_level.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
zip_safe flag not set; analyzing archive contents...
creating 'dist/openpyxl-1.1.4-py2.4.egg' and adding 'build/bdist.linux-x86_64/egg' to it
removing 'build/bdist.linux-x86_64/egg' (and everything under it)
Processing openpyxl-1.1.4-py2.4.egg
Copying openpyxl-1.1.4-py2.4.egg to /usr/lib/python2.4/site-packages
Removing openpyxl 1.1.0 from easy-install.pth file
Adding openpyxl 1.1.4 to easy-install.pth file

Installed /usr/lib/python2.4/site-packages/openpyxl-1.1.4-py2.4.egg
Processing dependencies for openpyxl==1.1.4

Last edited by project.linux.proj; 03-25-2013 at 05:52 AM.
 
Old 03-25-2013, 06:44 AM   #2
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016 CentOS6.9 CentOS7.3 + 50+ other Linux OS, for test only.
Posts: 16,684

Rep: Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286
? CentOS 5.x / RHEL 5.x ?

? Why not use the latest openpyxl = openpyxl-1.1.4.zip
https://pypi.python.org/pypi/openpyxl/1.1.0
> https://pypi.python.org/packages/sou...7f43f02e0c931a

cd openpyxl-1.1.4/ ; su ; # python setup.py install

Prerequisites : # yum install python-setuptools

-
 
1 members found this post helpful.
Old 03-25-2013, 07:01 AM   #3
project.linux.proj
Member
 
Registered: Dec 2012
Posts: 78

Original Poster
Rep: Reputation: Disabled
It is RedHatEnterpriseServer 5.5. when i run the command. I removed the package and tried to install the version that u just suggested. but still getting same erros.

File "build/bdist.linux-x86_64/egg/openpyxl/tests/test_strings.py", line 58
with open(osp.join(DATADIR, 'reader', 'sharedStrings.xml')) as f:
^
SyntaxError: invalid syntax
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/__init__.py to __init__.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_password_hash.py to test_password_hash.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_cell.py to test_cell.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_theme.py to test_theme.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_zip.py to test_zip.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_style.py to test_style.pyc
File "build/bdist.linux-x86_64/egg/openpyxl/tests/test_style.py", line 82
with open(reference_file) as ref_file:
^
SyntaxError: invalid syntax
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_worksheet.py to test_worksheet.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/helper.py to helper.pyc
File "build/bdist.linux-x86_64/egg/openpyxl/tests/helper.py", line 52
with open(reference_file) as expected_file:
^
SyntaxError: invalid syntax
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_props.py to test_props.pyc
File "build/bdist.linux-x86_64/egg/openpyxl/tests/test_props.py", line 75
with open(self.reference_filename) as ref_file:
^
SyntaxError: invalid syntax
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_write.py to test_write.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_workbook.py to test_workbook.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_named_range.py to test_named_range.pyc
File "build/bdist.linux-x86_64/egg/openpyxl/tests/test_named_range.py", line 59
with open(osp.join(DATADIR, 'reader', 'workbook.xml')) as f:
^
SyntaxError: invalid syntax
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/tests/test_read.py to test_read.pyc
File "build/bdist.linux-x86_64/egg/openpyxl/tests/test_read.py", line 50
with open(osp.join(DATADIR, 'reader', 'sheet2.xml')) as f:
^
SyntaxError: invalid syntax
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/namedrange.py to namedrange.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/style.py to style.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/worksheet.py to worksheet.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/workbook.py to workbook.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/writer/excel.py to excel.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/writer/__init__.py to __init__.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/writer/strings.py to strings.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/writer/styles.py to styles.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/writer/worksheet.py to worksheet.pyc
File "build/bdist.linux-x86_64/egg/openpyxl/writer/worksheet.py", line 45
SubElement(sheet_pr, 'outlinePr', {'summaryBelow' : '%d' % (1 if worksheet.show_summary_below else 0),
^
SyntaxError: invalid syntax
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/writer/theme.py to theme.pyc
byte-compiling build/bdist.linux-x86_64/egg/openpyxl/writer/workbook.py to workbook.pyc
creating build/bdist.linux-x86_64/egg/EGG-INFO
copying src/openpyxl.egg-info/PKG-INFO -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/openpyxl.egg-info/SOURCES.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/openpyxl.egg-info/dependency_links.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/openpyxl.egg-info/top_level.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
zip_safe flag not set; analyzing archive contents...
creating 'dist/openpyxl-1.1.4-py2.4.egg' and adding 'build/bdist.linux-x86_64/egg' to it
removing 'build/bdist.linux-x86_64/egg' (and everything under it)
Processing openpyxl-1.1.4-py2.4.egg
Copying openpyxl-1.1.4-py2.4.egg to /usr/lib/python2.4/site-packages
Adding openpyxl 1.1.4 to easy-install.pth file

Installed /usr/lib/python2.4/site-packages/openpyxl-1.1.4-py2.4.egg
Processing dependencies for openpyxl==1.1.4
 
Old 03-25-2013, 10:43 AM   #4
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016 CentOS6.9 CentOS7.3 + 50+ other Linux OS, for test only.
Posts: 16,684

Rep: Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286
# 3.

Well, then do not attempt to use "easy_install".

Please use # python setup.py install
 
Old 03-25-2013, 12:29 PM   #5
project.linux.proj
Member
 
Registered: Dec 2012
Posts: 78

Original Poster
Rep: Reputation: Disabled
Still it has error and doesn't list when run help('modules') May I know how to fix it ?

Thanks,
 
Old 03-26-2013, 12:42 AM   #6
project.linux.proj
Member
 
Registered: Dec 2012
Posts: 78

Original Poster
Rep: Reputation: Disabled
Can anybody ensure me if it is a bug and I should try Python newer version ?

Thanks,
 
Old 03-26-2013, 01:36 AM   #7
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016 CentOS6.9 CentOS7.3 + 50+ other Linux OS, for test only.
Posts: 16,684

Rep: Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286Reputation: 3286
Is OK here, so far concerns the install :

Please see post # 2. No errors at # python setup.py install
 
Old 03-26-2013, 01:42 AM   #8
project.linux.proj
Member
 
Registered: Dec 2012
Posts: 78

Original Poster
Rep: Reputation: Disabled
Thanks for replying Knudfl. So the question is , how can I convince user that the pkg is installed because it is not listing in module list when i run the command help('modules') ?

Thanks,
 
Old 03-26-2013, 04:47 AM   #9
project.linux.proj
Member
 
Registered: Dec 2012
Posts: 78

Original Poster
Rep: Reputation: Disabled
Finally I tried to install different version openpyxl-1.5.8 . It worked and installed with the same way i was installing " python setup.py install "

Thanks,
 
1 members found this post helpful.
  


Reply

Tags
openpyxl


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] connection refused errror rajiv.patil82 Linux - Software 1 11-27-2010 11:30 AM
JBoss Startup Errror? your_shadow03 Linux - Newbie 16 02-23-2010 09:04 AM
glibc 2.5.1 errror @d4M Linux From Scratch 2 01-18-2009 12:06 AM
k3b errror messages (several) rvijay Debian 2 02-28-2005 04:15 AM
cd drive mounting errror Longinus Linux - Newbie 7 06-05-2004 12:54 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:14 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration