Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
e4b584f
remove null bitmaps for union types
trxcllnt Aug 11, 2023
5e5c555
make test data generators more deterministic
trxcllnt Aug 11, 2023
5412d60
don't use silent jest reporter in verbose mode
trxcllnt Aug 11, 2023
b224ea0
re-enable generated-data SparseUnion test
trxcllnt Aug 11, 2023
946cf23
fix #37063
trxcllnt Aug 11, 2023
2ce877a
fix lint
trxcllnt Aug 11, 2023
86c421c
enable JS union integration tests
trxcllnt Aug 24, 2023
4990418
fix the create:testdata npm script
trxcllnt Aug 24, 2023
72fa4a1
make the bin scripts work again
trxcllnt Aug 24, 2023
7942eb2
update the vscode debug launch configs
trxcllnt Aug 24, 2023
78dfefa
length == nullCount for Null types
trxcllnt Aug 24, 2023
36d5e6e
Fix TYPE -> TYPE_ID and UnionMode casing when round-tripping through …
trxcllnt Aug 24, 2023
852372d
fix nested-dictionary integration test
trxcllnt Aug 24, 2023
ccf19bb
Enforce map child field names. Fixes #17168
trxcllnt Aug 24, 2023
c9df206
generate all the files the JS version passes
trxcllnt Aug 24, 2023
6bb6a4b
un-skip integration tests that JS now passes, don't use duplicate fie…
trxcllnt Aug 24, 2023
0b0698d
fix lint
trxcllnt Aug 24, 2023
6ea5772
update status.rst
trxcllnt Aug 24, 2023
8cec388
fix dictionary and visitor tests
trxcllnt Aug 25, 2023
6dd7199
fix lint
trxcllnt Aug 25, 2023
d24462b
skip testing JS against older union formats
trxcllnt Aug 25, 2023
a058f8d
update customMetadata -> metadata
trxcllnt Aug 26, 2023
3e3ae09
don't write nullcount into union field nodes
trxcllnt Aug 26, 2023
5d1c224
JSON metadata is now a list of objects with key/value fields
trxcllnt Aug 27, 2023
636d77d
fix lint
trxcllnt Aug 27, 2023
04b53c1
update IPC metadata versions
trxcllnt Aug 27, 2023
19a2eb1
skip pre-1.0.0 IPC integration tests
trxcllnt Aug 27, 2023
a268912
revert find-replace error
trxcllnt Sep 7, 2023
33d9666
support older metadata versions' union layout
trxcllnt Sep 7, 2023
2893a92
re-enable older JS union integration tests
trxcllnt Sep 7, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 16 additions & 23 deletions dev/archery/archery/integration/datagen.py
Original file line number Diff line number Diff line change
Expand Up @@ -1556,18 +1556,18 @@ def generate_nested_large_offsets_case():

def generate_unions_case():
fields = [
SparseUnionField('sparse', [get_field('f1', 'int32'),
get_field('f2', 'utf8')],
SparseUnionField('sparse_1', [get_field('f1', 'int32'),
get_field('f2', 'utf8')],
type_ids=[5, 7]),
DenseUnionField('dense', [get_field('f1', 'int16'),
get_field('f2', 'binary')],
DenseUnionField('dense_1', [get_field('f1', 'int16'),
get_field('f2', 'binary')],
type_ids=[10, 20]),
SparseUnionField('sparse', [get_field('f1', 'float32', nullable=False),
get_field('f2', 'bool')],
SparseUnionField('sparse_2', [get_field('f1', 'float32', nullable=False),
get_field('f2', 'bool')],
type_ids=[5, 7], nullable=False),
DenseUnionField('dense', [get_field('f1', 'uint8', nullable=False),
get_field('f2', 'uint16'),
NullField('f3')],
DenseUnionField('dense_2', [get_field('f1', 'uint8', nullable=False),
get_field('f2', 'uint16'),
NullField('f3')],
type_ids=[42, 43, 44], nullable=False),
]

Expand Down Expand Up @@ -1669,11 +1669,9 @@ def _temp_path():
.skip_category('C#')
.skip_category('JS'),

generate_null_case([10, 0])
.skip_category('JS'), # TODO(ARROW-7900)
generate_null_case([10, 0]),

generate_null_trivial_case([0, 0])
.skip_category('JS'), # TODO(ARROW-7900)
generate_null_trivial_case([0, 0]),

generate_decimal128_case(),

Expand All @@ -1699,8 +1697,7 @@ def _temp_path():

generate_non_canonical_map_case()
.skip_category('C#')
.skip_category('Java') # TODO(ARROW-8715)
.skip_category('JS'), # TODO(ARROW-8716)
.skip_category('Java'), # TODO(ARROW-8715)

generate_nested_case()
.skip_category('C#'),
Expand All @@ -1713,12 +1710,10 @@ def _temp_path():
.skip_category('JS'),

generate_unions_case()
.skip_category('C#')
.skip_category('JS'),
.skip_category('C#'),

generate_custom_metadata_case()
.skip_category('C#')
.skip_category('JS'),
.skip_category('C#'),

generate_duplicate_fieldnames_case()
.skip_category('C#')
Expand All @@ -1733,8 +1728,7 @@ def _temp_path():

generate_nested_dictionary_case()
.skip_category('C#')
.skip_category('Java') # TODO(ARROW-7779)
.skip_category('JS'),
.skip_category('Java'), # TODO(ARROW-7779)

generate_run_end_encoded_case()
.skip_category('C#')
Expand All @@ -1743,8 +1737,7 @@ def _temp_path():
.skip_category('Rust'),

generate_extension_case()
.skip_category('C#')
.skip_category('JS'),
.skip_category('C#'),
]

generated_paths = []
Expand Down
74 changes: 60 additions & 14 deletions dev/archery/archery/integration/runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@ def _gold_tests(self, gold_dir):
skip = set()
if name == 'union' and prefix == '0.17.1':
skip.add("Java")
skip.add("JS")
if prefix == '1.0.0-bigendian' or prefix == '1.0.0-littleendian':
skip.add("C#")
skip.add("Java")
Expand Down Expand Up @@ -495,33 +496,78 @@ def run_all_tests(with_cpp=True, with_java=True, with_js=True,


def write_js_test_json(directory):
datagen.generate_primitive_case([], name='primitive_no_batches').write(
os.path.join(directory, 'primitive-no-batches.json')
)
datagen.generate_primitive_case([17, 20], name='primitive').write(
os.path.join(directory, 'primitive.json')
)
datagen.generate_primitive_case([0, 0, 0], name='primitive_zerolength').write(
os.path.join(directory, 'primitive-empty.json')
)
# datagen.generate_primitive_large_offsets_case([17, 20]).write(
# os.path.join(directory, 'primitive-large-offsets.json')
# )
datagen.generate_null_case([10, 0]).write(
os.path.join(directory, 'null.json')
)
datagen.generate_null_trivial_case([0, 0]).write(
os.path.join(directory, 'null-trivial.json')
)
datagen.generate_decimal128_case().write(
os.path.join(directory, 'decimal128.json')
)
# datagen.generate_decimal256_case().write(
# os.path.join(directory, 'decimal256.json')
# )
datagen.generate_datetime_case().write(
os.path.join(directory, 'datetime.json')
)
# datagen.generate_duration_case().write(
# os.path.join(directory, 'duration.json')
# )
# datagen.generate_interval_case().write(
# os.path.join(directory, 'interval.json')
# )
# datagen.generate_month_day_nano_interval_case().write(
# os.path.join(directory, 'month_day_nano_interval.json')
# )
datagen.generate_map_case().write(
os.path.join(directory, 'map.json')
)
datagen.generate_non_canonical_map_case().write(
os.path.join(directory, 'non_canonical_map.json')
)
datagen.generate_nested_case().write(
os.path.join(directory, 'nested.json')
)
datagen.generate_decimal128_case().write(
os.path.join(directory, 'decimal.json')
datagen.generate_recursive_nested_case().write(
os.path.join(directory, 'recursive-nested.json')
)
datagen.generate_decimal256_case().write(
os.path.join(directory, 'decimal256.json')
# datagen.generate_nested_large_offsets_case().write(
# os.path.join(directory, 'nested-large-offsets.json')
# )
datagen.generate_unions_case().write(
os.path.join(directory, 'unions.json')
)
datagen.generate_datetime_case().write(
os.path.join(directory, 'datetime.json')
datagen.generate_custom_metadata_case().write(
os.path.join(directory, 'custom-metadata.json')
)
# datagen.generate_duplicate_fieldnames_case().write(
# os.path.join(directory, 'duplicate-fieldnames.json')
# )
datagen.generate_dictionary_case().write(
os.path.join(directory, 'dictionary.json')
)
datagen.generate_dictionary_unsigned_case().write(
os.path.join(directory, 'dictionary_unsigned.json')
os.path.join(directory, 'dictionary-unsigned.json')
)
datagen.generate_primitive_case([]).write(
os.path.join(directory, 'primitive_no_batches.json')
datagen.generate_nested_dictionary_case().write(
os.path.join(directory, 'dictionary-nested.json')
)
datagen.generate_primitive_case([7, 10]).write(
os.path.join(directory, 'primitive.json')
)
datagen.generate_primitive_case([0, 0, 0]).write(
os.path.join(directory, 'primitive-empty.json')
# datagen.generate_run_end_encoded_case().write(
# os.path.join(directory, 'run_end_encoded.json')
# )
datagen.generate_extension_case().write(
os.path.join(directory, 'extension.json')
)
18 changes: 9 additions & 9 deletions docs/source/status.rst
Original file line number Diff line number Diff line change
Expand Up @@ -32,19 +32,19 @@ Data Types
| Data type | C++ | Java | Go | JavaScript | C# | Rust | Julia | Swift |
| (primitive) | | | | | | | | |
+===================+=======+=======+=======+============+=======+=======+=======+=======+
| Null | ✓ | ✓ | ✓ | | ✓ | ✓ | ✓ | |
| Null | ✓ | ✓ | ✓ | | ✓ | ✓ | ✓ | |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Boolean | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Int8/16/32/64 | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| UInt8/16/32/64 | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Float16 | | | ✓ | | ✓ (1)| ✓ | ✓ | |
| Float16 | | | ✓ | | ✓ (1)| ✓ | ✓ | |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Float32/64 | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Decimal128 | ✓ | ✓ | ✓ | | ✓ | ✓ | ✓ | |
| Decimal128 | ✓ | ✓ | ✓ | | ✓ | ✓ | ✓ | |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Decimal256 | ✓ | ✓ | ✓ | | ✓ | ✓ | ✓ | |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
Expand All @@ -66,7 +66,7 @@ Data Types
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Utf8 | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Large Utf8 | ✓ | ✓ | ✓ | | | ✓ | ✓ | |
| Large Utf8 | ✓ | ✓ | ✓ | | | ✓ | ✓ | |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+

+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
Expand All @@ -83,16 +83,16 @@ Data Types
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Map | ✓ | ✓ | ✓ | ✓ | | ✓ | ✓ | |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Dense Union | ✓ | ✓ | ✓ | | | ✓ | ✓ | |
| Dense Union | ✓ | ✓ | ✓ | | | ✓ | ✓ | |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Sparse Union | ✓ | ✓ | ✓ | | | ✓ | ✓ | |
| Sparse Union | ✓ | ✓ | ✓ | | | ✓ | ✓ | |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+

+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Data type | C++ | Java | Go | JavaScript | C# | Rust | Julia | Swift |
| (special) | | | | | | | | |
+===================+=======+=======+=======+============+=======+=======+=======+=======+
| Dictionary | ✓ | ✓ (2) | ✓ | ✓ (2) | ✓ (2) | ✓ (2) | ✓ | |
| Dictionary | ✓ | ✓ (2) | ✓ | ✓ | ✓ (2) | ✓ (2) | ✓ | |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Extension | ✓ | ✓ | ✓ | | | ✓ | ✓ | |
+-------------------+-------+-------+-------+------------+-------+-------+-------+-------+
Expand Down Expand Up @@ -125,7 +125,7 @@ IPC Format
+-----------------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Replacement dictionaries | ✓ | ✓ | ✓ | | | | ✓ | |
+-----------------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Delta dictionaries | ✓ (1) | | ✓ (1) | | ✓ | | ✓ | |
| Delta dictionaries | ✓ (1) | | ✓ (1) | | ✓ | | ✓ | |
+-----------------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Tensors | ✓ | | | | | | | |
+-----------------------------+-------+-------+-------+------------+-------+-------+-------+-------+
Expand All @@ -135,7 +135,7 @@ IPC Format
+-----------------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Endianness conversion | ✓ (2) | | ✓ (2) | | | | | |
+-----------------------------+-------+-------+-------+------------+-------+-------+-------+-------+
| Custom schema metadata | ✓ | ✓ | ✓ | | ✓ | ✓ | ✓ | |
| Custom schema metadata | ✓ | ✓ | ✓ | | ✓ | ✓ | ✓ | |
+-----------------------------+-------+-------+-------+------------+-------+-------+-------+-------+

Notes:
Expand Down
6 changes: 3 additions & 3 deletions js/.eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -102,9 +102,9 @@ module.exports = {
"unicorn/text-encoding-identifier-case": "off",
"unicorn/prefer-top-level-await": "off",

"unicorn/consistent-destructuring": "warn",
"unicorn/no-array-reduce": ["warn", { "allowSimpleOperations": true }],
"unicorn/no-await-expression-member": "warn",
"unicorn/consistent-destructuring": "off",
"unicorn/no-array-reduce": "off",
"unicorn/no-await-expression-member": "off",
"unicorn/no-useless-undefined": "warn",
"unicorn/consistent-function-scoping": "warn",
"unicorn/prefer-math-trunc": "warn",
Expand Down
37 changes: 26 additions & 11 deletions js/.vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
"type": "node",
"request": "launch",
"name": "Debug Gulp Build",
"cwd": "${workspaceFolder}",
"program": "${workspaceFolder}/node_modules/gulp/bin/gulp.js",
"args": [
"build",
Expand All @@ -71,7 +72,7 @@
"type": "node",
"request": "launch",
"name": "Debug Unit Tests",
"cwd": "${workspaceRoot}",
"cwd": "${workspaceFolder}",
"console": "integratedTerminal",
"program": "${workspaceFolder}/node_modules/.bin/jest",
"skipFiles": [
Expand All @@ -96,47 +97,58 @@
"type": "node",
"request": "launch",
"name": "Debug Integration Tests",
"cwd": "${workspaceRoot}",
"cwd": "${workspaceFolder}",
"program": "${workspaceFolder}/bin/integration.js",
"skipFiles": [
"<node_internals>/**/*.js",
"${workspaceFolder}/node_modules/**/*.js"
],
"env": {
"NODE_NO_WARNINGS": "1",
"ARROW_JS_DEBUG": "src",
"TS_NODE_CACHE": "false"
},
"runtimeArgs": [
"-r",
"ts-node/register"
],
"args": [
"--mode",
"VALIDATE"
"VALIDATE",
"-j", "test/data/json/unions.json",
"-a", "./test/data/cpp/stream/struct_example.arrow"
]
},
{
"type": "node",
"request": "launch",
"name": "Debug Bundle",
"cwd": "${workspaceFolder}",
"program": "${input:BUNDLE_FILE}",
"request": "launch",
"skipFiles": [
"<node_internals>/**"
],
"type": "node"
]
},
{
"type": "node",
"request": "launch",
"name": "Debug Benchmarks",
"cwd": "${workspaceFolder}",
"program": "${workspaceFolder}/perf/index.ts",
"request": "launch",
"skipFiles": [
"<node_internals>/**",
"${workspaceFolder}/node_modules/**/*.js"
],
"runtimeArgs": [
"--loader",
"ts-node/esm/transpile-only"
],
"type": "node"
]
},
{
"type": "node",
"request": "launch",
"name": "Debug bin/arrow2csv",
"cwd": "${workspaceFolder}",
"env": {
"ARROW_JS_DEBUG": "src",
"TS_NODE_CACHE": "false"
Expand All @@ -160,6 +172,7 @@
"type": "node",
"request": "launch",
"name": "Debug bin/file-to-stream",
"cwd": "${workspaceFolder}",
"env": {
"ARROW_JS_DEBUG": "src",
"TS_NODE_CACHE": "false"
Expand All @@ -182,6 +195,7 @@
"type": "node",
"request": "launch",
"name": "Debug bin/stream-to-file",
"cwd": "${workspaceFolder}",
"env": {
"ARROW_JS_DEBUG": "src",
"TS_NODE_CACHE": "false"
Expand All @@ -204,6 +218,7 @@
"type": "node",
"request": "launch",
"name": "Debug bin/json-to-arrow",
"cwd": "${workspaceFolder}",
"env": {
"ARROW_JS_DEBUG": "src",
"TS_NODE_CACHE": "false"
Expand All @@ -230,6 +245,7 @@
"type": "node",
"request": "launch",
"name": "Debug bin/print-buffer-alignment",
"cwd": "${workspaceFolder}",
"env": {
"ARROW_JS_DEBUG": "src",
"TS_NODE_CACHE": "false"
Expand All @@ -251,10 +267,9 @@
"type": "node",
"name": "vscode-jest-tests",
"request": "launch",
"cwd": "${workspaceFolder}",
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"disableOptimisticBPs": true,
"cwd": "${workspaceFolder}",
"program": "${workspaceFolder}/node_modules/.bin/jest",
"runtimeArgs": [
"--experimental-vm-modules"
Expand Down
Loading