Skip to content
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

missing data for consequent duplicite lines #86

Closed
antonsjava opened this issue Dec 19, 2023 · 7 comments
Closed

missing data for consequent duplicite lines #86

antonsjava opened this issue Dec 19, 2023 · 7 comments

Comments

@antonsjava
Copy link

oo-ods-test.zip
Hello

I just try sods for first time and it seems there is bug (maybe I don't understant it)

I try to make scenario where create and read ods file line by line.

sk.antons.sods.CreateDoc

  • reads ./src/data/duplicate-lines.csv
  • copy content of csv to ./target/sods.ods

sk.antons.sods.ReadDoc

  • reads ./target/sods.ods
  • copy content to ./target/sods-output-copied.csv
  • copy content to ./target/sods-output2-copied.csv (just other way of sods use)

scenario 1

  • start CreateDoc
  • start ReadDoc
  • when I open ./target/sods.ods in libreoffice it seems ok
  • when you look to ./target/sods-output-copied.csv or ./target/sods-output-copied2.csv data of duplicate consequent lines are mising (only lastone is present)

scenario 2

  • start CreateDoc
  • open ./target/sods.ods in libreoffice and save it
  • start ReadDoc
  • when I open ./target/sods.ods in libreoffice it seems ok
  • when you look to ./target/sods-output-copied.csv or ./target/sods-output-copied.csv all data are present

So it seems that created ods file is somehow wrong for consequent reading by sods.

Thanks

Copy link

Thanks for your report! Please ensure you have provided enough info in order to recreate the issue, including the problematic ODS File.

@antonsjava
Copy link
Author

in attached file there are all generated files together with code so you can recreate them if you want

@miachm
Copy link
Owner

miachm commented Dec 19, 2023

when you look to ./target/sods-output-copied.csv or ./target/sods-output-copied2.csv data of duplicate consequent lines are mising (only lastone is present)

I... Don't understand this line. You mean is missing data?

@antonsjava
Copy link
Author

when you look at generated file ./target/sods-output-copied.csv or ./target/sods-output2-copied.csv

if you look on line 11 for example it looks like

;;;;;;;;

but it should be

3;3;3;;;;;;

data are mising

if you have 'same lines' in generated ods they are unable to read (until you explicitly save that ods file in office application)
only last line for each serie of same lines are present
(look to ./src/data/duplicate-lines.csv - result should look same - plus/minus of empty cells)

@miachm
Copy link
Owner

miachm commented Dec 22, 2023

Okay found it. The interpretation of the tag "table:number-rows-repeated" is buggy in its reading implementation. It's not applying the value to the repeated rows.

LibreOffice is not using that tag in their files (at least in the example you gave me). That's why re-saving the file worked.

miachm added a commit that referenced this issue Dec 22, 2023
@miachm
Copy link
Owner

miachm commented Dec 22, 2023

Fixed in the commit 858f0bb

@miachm
Copy link
Owner

miachm commented Dec 22, 2023

Released into 1.6.7

@miachm miachm closed this as completed Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants