-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Key error 29 #80
Comments
The line that refers to CellStorage suggests you have a slightly older version of numbers-parser (I changed this last week). The error itself is numbers-parser not finding a string in the string table. If the new version doesn’t work you would need to share a broken file with me. The best approach to reduce confidential data to a test case is to progressively delete half the data and rechecking. If the file loads after deleting half, undo and delete the other half. I’ve found this bisecting technique gets me a minimal example pretty quickly. |
I get the same error when I try to open a corrupted file on issue #79 |
If it's corrupted than that's the fault of numbers_parser itself since it's
a file that numbers_parser was working with and saving to. I will try to
update numbers_parser and bisect the file next time at the office.
…On Thu, Mar 21, 2024, 7:41 AM darioclock ***@***.***> wrote:
I get the same error when I try to open a corrupted file on issue #79
<#79>
—
Reply to this email directly, view it on GitHub
<#80 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AB5LTKT46FYDE2KHC53JWCTYZLWQJAVCNFSM6AAAAABFAN4JOKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMJSGQ3TQMRVGI>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
v4.10.4 contains some fixes to datalists. |
Strange error I'm getting when I try to run numbers_parser on certain files, it yields a stack with key error 29, other Numbers files it seems to work fine on. Any advice?
Traceback (most recent call last):
File "/Users/glucosamigos/py_scripts/ocr_goo.py", line 197, in
numdoc = Document("/Users/glucosamigos/py_scripts/newsheet.numbers")
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/numbers_parser/document.py", line 90, in init
self._sheets = ItemsList(self._model, refs, Sheet)
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/numbers_parser/containers.py", line 11, in init
self._items = [item_class(model, _) for _ in refs]
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/numbers_parser/document.py", line 324, in init
self._tables = ItemsList(self._model, refs, Table)
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/numbers_parser/containers.py", line 11, in init
self._items = [item_class(model, _) for _ in refs]
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/numbers_parser/document.py", line 431, in init
cell_storage = model.table_cell_decode(table_id, row, col)
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/numbers_parser/numbers_cache.py", line 25, in inner_multi_args
value = func(self, *args, **kwargs)
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/numbers_parser/model.py", line 1760, in table_cell_decode
return CellStorage(self, table_id, buffer, row, col)
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/numbers_parser/cell_storage.py", line 196, in init
self.value = self.model.table_string(table_id, self.string_id)
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/numbers_parser/numbers_cache.py", line 25, in inner_multi_args
value = func(self, *args, **kwargs)
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/numbers_parser/model.py", line 491, in table_string
return self._table_strings.lookup_value(table_id, key).string
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/numbers_parser/model.py", line 169, in lookup_value
return self._datalists[table_id]["by_key"][key]
KeyError: 29
The text was updated successfully, but these errors were encountered: