mirror of
https://github.com/jmcnamara/libxlsxwriter.git
synced 2026-05-15 14:15:54 -06:00
[GH-ISSUE #461] Using the library in a docker results in a segfault on workbook_get_worksheet_by_name #363
Labels
No labels
awaiting user feedback
bug
cmake
cmake
docs
feature request
in progress
long term
medium term
medium term
pull-request
question
question
ready to close
short term
under investigation
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/libxlsxwriter#363
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @BinarSkugga on GitHub (Oct 25, 2024).
Original GitHub issue: https://github.com/jmcnamara/libxlsxwriter/issues/461
Hello,
I am trying to use and run this library using Python. It works great on my computer but when I try to do it inside of a docker container it results in a segfault. I'm using
ctypesandlibxlsxwriter 1.1.8. I ran it usinggdb, here's the full log:Here's my dockerfile for building and running it:
And finally the python code, although it works on my host:
cstringdoes actypes.c_char_p, it fails onworkbook_add_worksheet@jmcnamara commented on GitHub (Oct 25, 2024):
Why not just use the Python version of the library, XlsxWriter: https://xlsxwriter.readthedocs.io/index.html
@BinarSkugga commented on GitHub (Oct 26, 2024):
My reports have upward of 100k lines and it can takes 3-5 minutes to generate them using the python library. I am trying to gain some performance so the delay is not as bad. I tried using constant memory and the port for this in python seems abandoned.
@jmcnamara commented on GitHub (Oct 26, 2024):
It shouldn't take that long. Here is a quick test I did with the performance example in the XlsxWriter repo:
It writes 100,000 rows by 50 columns of mixed numbers and strings in around 30 seconds. Try it out on your test machine. If you get similar results but your overall program takes 3 minutes then the bottleneck is elsewhere.
It isn't abandoned. I maintain both
XlsxWriterandlibxlsxwriterand theconstant_memoryfunctionality is exactly the same in both.@BinarSkugga commented on GitHub (Oct 26, 2024):
I'll try that inside of our docker. I believe it's limited in RAM & CPU, that might be the issue, that or some abstraction around the library that we made.
I didn't mean the python library is abandoned, sorry about that. I meant the python port around the library in C is: https://github.com/pyexcel/libxlsxwpy
Apart from this, do you have any idea about the segfault ? I still want an alternative if the issue is something I have no control over.
@jmcnamara commented on GitHub (Oct 26, 2024):
I don't. It is not something that I have encountered or have seen reported.
That is reasonable. If it is an option then the Rust version of this library
rust_xlsxwriterhas the speed of the C library and (if you use Rust)) the usability of the Python version. It also supports constant memory mode if needed: https://github.com/jmcnamara/rust_xlsxwriter@jmcnamara commented on GitHub (Oct 26, 2024):
I will need to close this because I don't believe it is a bug in libxlsxwriter. If you do find the source of the issue let me know.
@BinarSkugga commented on GitHub (Oct 27, 2024):
No worries, thank for your help still :)