Comments (7)
Weird that it would work on one and not the other. Would you be adverse to attaching a sanitized version of the file? I would like to see if it fails on amy other oses if not I will take a look to see if the change has any adverse affects and add it to the code.
Sent from my iPhone
On Apr 10, 2012, at 4:39 PM, Brian [email protected] wrote:
I received the following error while trying to parse a .xlsx file on RHEL6, using Ruby 1.9.3. I did not get this error when I ran the same script on the same file on OSX 10.7:
1.9.3
~hoffman/.rvm/gems/ruby-1.9.3-p125/gems/rubyXL-1.2.7/lib/rubyXL/parser.rb:357:ininitialize': No such file or directory - ../data/2012_04_10_16_22_50_0400/xl/drawings/_rels (Errno::ENOENT) from /home/dlib/hoffman/.rvm/gems/ruby-1.9.3-p125/gems/rubyXL-1.2.7/lib/rubyXL/parser.rb:357:in
new'
from /home/dlib/hoffman/.rvm/gems/ruby-1.9.3-p125/gems/rubyXL-1.2.7/lib/rubyXL/parser.rb:357:indecompress' from /home/dlib/hoffman/.rvm/gems/ruby-1.9.3-p125/gems/rubyXL-1.2.7/lib/rubyXL/parser.rb:49:in
parse'I was able to solve this locally by adding the following line above line 357 in parser.rb:
Dir.mkdir(drawings_path)
Reply to this email directly or view it on GitHub:
#26
from rubyxl.
Sorry for the slow reply. I posted a copy of the file here:
https://gist.github.com/2423940
The only edit to the original is line 357. I don't know if this will produce errors or if it's a good idea to incorporate it - it was just the easiest way for me to get the parser working on my RHEL6 machine.
from rubyxl.
hmm I will take a look this weekend to see if I can get your error to happen I know i recently fixed the pathing in that function so it may be a side effect do you know if your two machines are running different versions?
from rubyxl.
I am facing the same issue.I am on Mac OSX 10.7.I added the line suggested by lcdhoffman locally. Now it parse the file correctly.But while writing to excel it creates the problem.The excel file could not be opened seems like its corrupted.
from rubyxl.
Just got this same error on OS X 10.6.8:
/Library/Ruby/Gems/1.8/gems/rubyXL-1.2.7/lib/rubyXL/parser.rb:358:in initialize': No such file or directory - ./Wed_May_30_11_19_02_0400_2012/xl/drawings/_rels (Errno::ENOENT) from /Library/Ruby/Gems/1.8/gems/rubyXL-1.2.7/lib/rubyXL/parser.rb:358:in
new'
from /Library/Ruby/Gems/1.8/gems/rubyXL-1.2.7/lib/rubyXL/parser.rb:358:in decompress' from /Library/Ruby/Gems/1.8/gems/rubyXL-1.2.7/lib/rubyXL/parser.rb:49:in
parse'
from loadPRG.rb:4
Also resolved by adding Dir.mkdir(drawings_path)
to line 357
from rubyxl.
Also had the same issue on OS X 10.7.4. Adding the same snippet as the previous comments rectified my issues.
from rubyxl.
just released a version that should fix this 1.2.8
from rubyxl.
Related Issues (20)
- How to change the default data type of a column?
- RubyZip 3.0 will introduce breaking changes that rubyXL will currently depend upon HOT 1
- Got a string with a part missing when i read value from cell. HOT 1
- Cannot open xlsx file using rubyXL HOT 3
- cell and styles.xml HOT 1
- can't change border diagonal
- "Nokogiri::XML::SyntaxError (1:1: FATAL: Document is empty)" on parsing the buffer more than once HOT 1
- GitHub sponsor/open collective HOT 2
- `insert_column` with existing styled cell doesn't set cell `@worksheet`, causing failure in `LegacyCell#validate_worksheet` HOT 1
- How can I make a cell in the sheet dropdown list with accept multiple values? (multiple selection)? HOT 1
- Storage class not found for docProps/app.xml and xl/workbook.xml leading to error opening file
- AWS setup for E-mail processing HOT 1
- MissingFile error during send_file in rails
- Re-open #332
- undefined method `change_row_italics' HOT 1
- Obscure error raised when calling `parse_buffer` with an empty buffer HOT 1
- when i parse a xlsx file, change_contents not found. and how can i change merged cell content? HOT 1
- External link can not write to new file
- `#parse_buffer` unexpectedly modifies input buffer HOT 3
- Error Parsing Xlsx when it has links to other files
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rubyxl.