red-parquet 22.0.0 → 23.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/parquet/arrow-file-reader.rb +2 -0
- data/lib/parquet/arrow-file-writer.rb +2 -0
- data/lib/parquet/version.rb +1 -1
- data/red-parquet.gemspec +1 -1
- data/test/test-array-statistics.rb +10 -0
- data/test/test-arrow-table.rb +1 -0
- data/test/test-boolean-statistics.rb +16 -9
- metadata +5 -5
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 323fa3b4a88ef118dd4580d50a34c8f30db87b93338e3b43d142b17d19ee6efa
|
|
4
|
+
data.tar.gz: 0a0d9fb8fced5f7d4ac62d57138782d1a45a476030d25e40666d50c9fe0290cc
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1e45caca717bdefade59a70d8273c8f20a20050651d256db56d47a814567626627e6bb5385f645a4b6ae97a56aa025fa0b48cddcf29ded4b81750e8713a65c76
|
|
7
|
+
data.tar.gz: 634879c4e7919e28094f963e5d6e44511e4a2ce48c0ef622fc1178c0c297779f4a020588835d4ed778188661f927c9709186bbfdda44356ba8cd38cde363045e
|
data/lib/parquet/version.rb
CHANGED
data/red-parquet.gemspec
CHANGED
|
@@ -29,7 +29,7 @@ Gem::Specification.new do |spec|
|
|
|
29
29
|
]
|
|
30
30
|
spec.version = version_components.compact.join(".")
|
|
31
31
|
spec.homepage = "https://arrow.apache.org/"
|
|
32
|
-
spec.authors = ["Apache
|
|
32
|
+
spec.authors = ["The Apache Software Foundation"]
|
|
33
33
|
spec.email = ["dev@arrow.apache.org"]
|
|
34
34
|
|
|
35
35
|
spec.summary = "Red Parquet is the Ruby bindings of Apache Parquet"
|
|
@@ -27,6 +27,16 @@ class TestArrayStatistics < Test::Unit::TestCase
|
|
|
27
27
|
@statistics = loaded_table[:int64].data.chunks[0].statistics
|
|
28
28
|
end
|
|
29
29
|
|
|
30
|
+
def test_null_count
|
|
31
|
+
assert do
|
|
32
|
+
@statistics.has_null_count?
|
|
33
|
+
end
|
|
34
|
+
assert do
|
|
35
|
+
@statistics.null_count_exact?
|
|
36
|
+
end
|
|
37
|
+
assert_equal(1, @statistics.null_count)
|
|
38
|
+
end
|
|
39
|
+
|
|
30
40
|
def test_distinct_count
|
|
31
41
|
assert do
|
|
32
42
|
not @statistics.has_distinct_count?
|
data/test/test-arrow-table.rb
CHANGED
|
@@ -17,15 +17,22 @@
|
|
|
17
17
|
|
|
18
18
|
class TestBooleanStatistics < Test::Unit::TestCase
|
|
19
19
|
def setup
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
20
|
+
Tempfile.create(["data", ".parquet"]) do |file|
|
|
21
|
+
array = Arrow::BooleanArray.new([nil, false, true])
|
|
22
|
+
table = Arrow::Table.new("boolean" => array)
|
|
23
|
+
Parquet::ArrowFileWriter.open(table.schema, file.path) do |writer|
|
|
24
|
+
chunk_size = 1024
|
|
25
|
+
writer.write_table(table, chunk_size)
|
|
26
|
+
writer.close
|
|
27
|
+
end
|
|
28
|
+
Parquet::ArrowFileReader.open(file.path) do |reader|
|
|
29
|
+
@statistics =
|
|
30
|
+
reader.metadata.get_row_group(0).get_column_chunk(0).statistics
|
|
31
|
+
yield
|
|
32
|
+
@statistics = nil
|
|
33
|
+
end
|
|
34
|
+
GC.start # Ensure freeing @statistics that refers file.path.
|
|
35
|
+
end
|
|
29
36
|
end
|
|
30
37
|
|
|
31
38
|
def test_min
|
metadata
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: red-parquet
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version:
|
|
4
|
+
version: 23.0.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
|
-
- Apache
|
|
7
|
+
- The Apache Software Foundation
|
|
8
8
|
bindir: bin
|
|
9
9
|
cert_chain: []
|
|
10
10
|
date: 1980-01-02 00:00:00.000000000 Z
|
|
@@ -15,14 +15,14 @@ dependencies:
|
|
|
15
15
|
requirements:
|
|
16
16
|
- - '='
|
|
17
17
|
- !ruby/object:Gem::Version
|
|
18
|
-
version:
|
|
18
|
+
version: 23.0.0
|
|
19
19
|
type: :runtime
|
|
20
20
|
prerelease: false
|
|
21
21
|
version_requirements: !ruby/object:Gem::Requirement
|
|
22
22
|
requirements:
|
|
23
23
|
- - '='
|
|
24
24
|
- !ruby/object:Gem::Version
|
|
25
|
-
version:
|
|
25
|
+
version: 23.0.0
|
|
26
26
|
- !ruby/object:Gem::Dependency
|
|
27
27
|
name: bundler
|
|
28
28
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -113,7 +113,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
113
113
|
- !ruby/object:Gem::Version
|
|
114
114
|
version: '0'
|
|
115
115
|
requirements: []
|
|
116
|
-
rubygems_version:
|
|
116
|
+
rubygems_version: 3.6.7
|
|
117
117
|
specification_version: 4
|
|
118
118
|
summary: Red Parquet is the Ruby bindings of Apache Parquet
|
|
119
119
|
test_files:
|