xitongsys / parquet-go

pure golang library for reading/writing parquet file
Apache License 2.0
1.27k stars 293 forks source link

PR-513 breaks example/json_schema.go #516

Closed hangxie closed 1 year ago

hangxie commented 1 year ago

I don't have time to look into details yet, https://github.com/xitongsys/parquet-go/pull/513 breaks example/json_schema.go

$ git checkout master
Already on 'master'
Your branch is up to date with 'origin/master'.
$ git pull
Already up to date.
$ go run json_schema.go
2023/01/25 00:20:11 Write error writer is stopped
2023/01/25 00:20:11 Write error writer is stopped
2023/01/25 00:20:11 Write error writer is stopped
2023/01/25 00:20:11 Write error writer is stopped
2023/01/25 00:20:11 Write error writer is stopped
2023/01/25 00:20:11 Write error writer is stopped
2023/01/25 00:20:11 Write error writer is stopped
2023/01/25 00:20:11 Write error writer is stopped
2023/01/25 00:20:11 Write error writer is stopped
2023/01/25 00:20:11 Write error writer is stopped
2023/01/25 00:20:11 Write Finished
2023/01/25 00:20:11 Can't create parquet reader seek json_schema.parquet: invalid argument
$ git checkout aadb31c52a16bf8759faca1e91299ff1a81ded0d
Note: switching to 'aadb31c52a16bf8759faca1e91299ff1a81ded0d'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c <new-branch-name>

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false

HEAD is now at aadb31c Merge pull request #492 from zaneli/fix-encodingread-test
$ go run json_schema.go
2023/01/25 00:20:26 Write Finished
2023/01/25 00:20:26 [{StudentName 20 0 50 true [Math Physics] map[Math:[89.5 99.4] Physics:[100 95.3]]  [{Jack 1}] [{Tom 2}]}]
2023/01/25 00:20:26 [{StudentName 21 1 50.1 false [Math Physics] map[Math:[89.5 99.4] Physics:[100 95.3]]  [{Jack 1}] [{Tom 2}]}]
2023/01/25 00:20:26 [{StudentName 22 2 50.2 true [Math Physics] map[Math:[89.5 99.4] Physics:[100 95.3]]  [{Jack 1}] [{Tom 2}]}]
2023/01/25 00:20:26 [{StudentName 23 3 50.3 false [Math Physics] map[Math:[89.5 99.4] Physics:[100 95.3]]  [{Jack 1}] [{Tom 2}]}]
2023/01/25 00:20:26 [{StudentName 24 4 50.4 true [Math Physics] map[Math:[89.5 99.4] Physics:[100 95.3]]  [{Jack 1}] [{Tom 2}]}]
2023/01/25 00:20:26 [{StudentName 20 5 50.5 false [Math Physics] map[Math:[89.5 99.4] Physics:[100 95.3]]  [{Jack 1}] [{Tom 2}]}]
2023/01/25 00:20:26 [{StudentName 21 6 50.6 true [Math Physics] map[Math:[89.5 99.4] Physics:[100 95.3]]  [{Jack 1}] [{Tom 2}]}]
2023/01/25 00:20:26 [{StudentName 22 7 50.7 false [Math Physics] map[Math:[89.5 99.4] Physics:[100 95.3]]  [{Jack 1}] [{Tom 2}]}]
2023/01/25 00:20:26 [{StudentName 23 8 50.8 true [Math Physics] map[Math:[89.5 99.4] Physics:[100 95.3]]  [{Jack 1}] [{Tom 2}]}]
2023/01/25 00:20:26 [{StudentName 24 9 50.9 false [Math Physics] map[Math:[89.5 99.4] Physics:[100 95.3]]  [{Jack 1}] [{Tom 2}]}]
hangxie commented 1 year ago

Fixed by https://github.com/xitongsys/parquet-go/pull/517