Apache DataFusion SQL Query Engine
Test: Add checks to sqllogictest temporary file creations (#17017)
Yongting Youbb2d90ed1543
diff --git a/Cargo.lock b/Cargo.lockindex 353466d6ce..b31913c31a 100644--- a/Cargo.lock+++ b/Cargo.lock@@ -149,9 +149,9 @@ checksum = "4b46cbb362ab8752921c97e041f5e366ee6297bd428a31275b9fcf1e380f7299"[[package]]name = "anstream"-version = "0.6.19"+version = "0.6.20"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "301af1932e46185686725e0fad2f8f2aa7da69dd70bf6ecc44d6b703844a3933"+checksum = "3ae563653d1938f79b1ab1b5e668c87c76a9930414574a6583a7b7e11a8e6192"dependencies = ["anstyle","anstyle-parse",@@ -179,29 +179,29 @@ dependencies = [[[package]]name = "anstyle-query"-version = "1.1.3"+version = "1.1.4"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "6c8bdeb6047d8983be085bab0ba1472e6dc604e7041dbf6fcd5e71523014fae9"+checksum = "9e231f6134f61b71076a3eab506c379d4f36122f2af15a9ff04415ea4c3339e2"dependencies = [- "windows-sys 0.59.0",+ "windows-sys 0.60.2",][[package]]name = "anstyle-wincon"-version = "3.0.9"+version = "3.0.10"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "403f75924867bb1033c59fbf0797484329750cfbe3c4325cd33127941fabc882"+checksum = "3e0633414522a32ffaac8ac6cc8f748e090c5717661fddeea04219e2344f5f2a"dependencies = ["anstyle","once_cell_polyfill",- "windows-sys 0.59.0",+ "windows-sys 0.60.2",][[package]]name = "anyhow"-version = "1.0.98"+version = "1.0.99"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "e16d2d3311acee920a9eb8d33b8cbc1787ce4a264e85f964c2404b969bdcd487"+checksum = "b0674a1ddeecb70197781e945de4b3b8ffb61fa939a5597bcf48503737663100"[[package]]name = "apache-avro"@@ -295,7 +295,7 @@ dependencies = ["chrono","chrono-tz","half",- "hashbrown 0.15.4",+ "hashbrown 0.15.5","num",]@@ -564,7 +564,7 @@ checksum = "3b43422f69d8ff38f95f1b2bb76517c91589a924d1559a0e935d7c8ce0274c11"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -575,7 +575,7 @@ checksum = "e539d3fca749fcee5236ab05e93a52867dd549cc157c8cb7f99595f3cedffdb5"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -601,9 +601,9 @@ checksum = "c08606f8c3cbf4ce6ec8e28fb0014a2c086708fe954eaa885384a6165172e7e8"[[package]]name = "aws-config"-version = "1.8.3"+version = "1.8.5"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "c0baa720ebadea158c5bda642ac444a2af0cdf7bb66b46d1e4533de5d1f449d0"+checksum = "c478f5b10ce55c9a33f87ca3404ca92768b144fc1bfdede7c0121214a8283a25"dependencies = ["aws-credential-types","aws-runtime",@@ -666,9 +666,9 @@ dependencies = [[[package]]name = "aws-runtime"-version = "1.5.9"+version = "1.5.10"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "b2090e664216c78e766b6bac10fe74d2f451c02441d43484cd76ac9a295075f7"+checksum = "c034a1bc1d70e16e7f4e4caf7e9f7693e4c9c24cd91cf17c2a0b21abaebc7c8b"dependencies = ["aws-credential-types","aws-sigv4",@@ -690,9 +690,9 @@ dependencies = [[[package]]name = "aws-sdk-sso"-version = "1.78.0"+version = "1.80.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "dbd7bc4bd34303733bded362c4c997a39130eac4310257c79aae8484b1c4b724"+checksum = "e822be5d4ed48fa7adc983de1b814dea33a5460c7e0e81b053b8d2ca3b14c354"dependencies = ["aws-credential-types","aws-runtime",@@ -712,9 +712,9 @@ dependencies = [[[package]]name = "aws-sdk-ssooidc"-version = "1.79.0"+version = "1.81.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "77358d25f781bb106c1a69531231d4fd12c6be904edb0c47198c604df5a2dbca"+checksum = "66aa7b30f1fac6e02ca26e3839fa78db3b94f6298a6e7a6208fb59071d93a87e"dependencies = ["aws-credential-types","aws-runtime",@@ -734,9 +734,9 @@ dependencies = [[[package]]name = "aws-sdk-sts"-version = "1.80.0"+version = "1.82.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "06e3ed2a9b828ae7763ddaed41d51724d2661a50c45f845b08967e52f4939cfc"+checksum = "2194426df72592f91df0cda790cb1e571aa87d66cecfea59a64031b58145abe3"dependencies = ["aws-credential-types","aws-runtime",@@ -757,9 +757,9 @@ dependencies = [[[package]]name = "aws-sigv4"-version = "1.3.3"+version = "1.3.4"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "ddfb9021f581b71870a17eac25b52335b82211cdc092e02b6876b2bcefa61666"+checksum = "084c34162187d39e3740cb635acd73c4e3a551a36146ad6fe8883c929c9f876c"dependencies = ["aws-credential-types","aws-smithy-http",@@ -790,9 +790,9 @@ dependencies = [[[package]]name = "aws-smithy-http"-version = "0.62.2"+version = "0.62.3"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "43c82ba4cab184ea61f6edaafc1072aad3c2a17dcf4c0fce19ac5694b90d8b5f"+checksum = "7c4dacf2d38996cf729f55e7a762b30918229917eca115de45dfa8dfb97796c9"dependencies = ["aws-smithy-runtime-api","aws-smithy-types",@@ -861,9 +861,9 @@ dependencies = [[[package]]name = "aws-smithy-runtime"-version = "1.8.5"+version = "1.8.6"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "660f70d9d8af6876b4c9aa8dcb0dbaf0f89b04ee9a4455bea1b4ba03b15f26f6"+checksum = "9e107ce0783019dbff59b3a244aa0c114e4a8c9d93498af9162608cd5474e796"dependencies = ["aws-smithy-async","aws-smithy-http",@@ -1061,7 +1061,7 @@ dependencies = ["regex","rustc-hash 1.1.0","shlex",- "syn 2.0.104",+ "syn 2.0.105","which",]@@ -1151,7 +1151,7 @@ dependencies = ["serde_json","serde_repr","serde_urlencoded",- "thiserror 2.0.12",+ "thiserror 2.0.14","tokio","tokio-util","tower-service",@@ -1190,7 +1190,7 @@ dependencies = ["proc-macro-crate","proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -1321,9 +1321,9 @@ checksum = "37b2a672a2cb129a2e41c10b1224bb368f9f37a2b16b612598138befd7b37eb5"[[package]]name = "cc"-version = "1.2.30"+version = "1.2.32"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "deec109607ca693028562ed836a5f1c4b8bd77755c4e132fc5ce11b0b6211ae7"+checksum = "2352e5597e9c544d5e6d9c95190d5d27738ade584fa8db0a16e130e5c2b5296e"dependencies = ["jobserver","libc",@@ -1427,9 +1427,9 @@ dependencies = [[[package]]name = "clap"-version = "4.5.44"+version = "4.5.45"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "1c1f056bae57e3e54c3375c41ff79619ddd13460a17d7438712bd0d83fda4ff8"+checksum = "1fc0e74a703892159f5ae7d3aac52c8e6c392f5ae5f359c70b5881d60aaac318"dependencies = ["clap_builder","clap_derive",@@ -1449,14 +1449,14 @@ dependencies = [[[package]]name = "clap_derive"-version = "4.5.41"+version = "4.5.45"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "ef4f52386a59ca4c860f7393bcf8abd8dfd91ecccc0f774635ff68e92eeef491"+checksum = "14cb31bb0a7d536caef2639baa7fad459e15c3144efefa6dbd1c84562c4739f6"dependencies = ["heck 0.5.0","proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -1556,9 +1556,12 @@ dependencies = [[[package]]name = "const_panic"-version = "0.2.13"+version = "0.2.14"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "b98d1483e98c9d67f341ab4b3915cfdc54740bd6f5cccc9226ee0535d86aa8fb"+checksum = "bb8a602185c3c95b52f86dc78e55a6df9a287a7a93ddbcf012509930880cf879"+dependencies = [+ "typewit",+][[package]]name = "constant_time_eq"@@ -1633,7 +1636,7 @@ dependencies = ["anes","cast","ciborium",- "clap 4.5.44",+ "clap 4.5.45","criterion-plot","futures","is-terminal",@@ -1776,7 +1779,7 @@ dependencies = ["proc-macro2","quote","strsim",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -1787,7 +1790,7 @@ checksum = "fc34b93ccb385b40dc71c6fceac4b2ad23662c7eeb248cf10d529b7e055b6ead"dependencies = ["darling_core","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -1962,7 +1965,7 @@ dependencies = ["async-trait","aws-config","aws-credential-types",- "clap 4.5.44",+ "clap 4.5.45","ctor","datafusion","dirs",@@ -2401,7 +2404,7 @@ version = "49.0.0"dependencies = ["datafusion-expr","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -2657,7 +2660,7 @@ dependencies = ["bigdecimal","bytes","chrono",- "clap 4.5.44",+ "clap 4.5.45","datafusion","datafusion-spark","datafusion-substrait",@@ -2670,13 +2673,14 @@ dependencies = ["object_store","postgres-protocol","postgres-types",+ "regex","rust_decimal","sqllogictest","sqlparser","tempfile","testcontainers","testcontainers-modules",- "thiserror 2.0.12",+ "thiserror 2.0.14","tokio","tokio-postgres",]@@ -2785,7 +2789,7 @@ checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -2841,7 +2845,7 @@ dependencies = ["enum-ordinalize","proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -2879,7 +2883,7 @@ checksum = "0d28318a75d4aead5c4db25382e8ef717932d0346600cacae6357eb5941bc5ff"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -3143,7 +3147,7 @@ checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -3252,9 +3256,9 @@ checksum = "07e28edb80900c19c28f1072f2e8aeca7fa06b23cd4169cefe1af5aa3260783f"[[package]]name = "glob"-version = "0.3.2"+version = "0.3.3"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "a8d1add55171497b4705a648c6b583acafb01d58050a51727785f0b2c8e0a2b2"+checksum = "0cc23270f6e1808e30a928bdc84dea0b9b4136a8bc82338574f23baf47bbd280"[[package]]name = "globset"@@ -3271,9 +3275,9 @@ dependencies = [[[package]]name = "h2"-version = "0.4.11"+version = "0.4.12"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "17da50a276f1e01e0ba6c029e47b7100754904ee8a278f886546e98575380785"+checksum = "f3c0b69cfcb4e1b9f1bf2f53f95f766e4661169728ec61cd3fe5a0166f2d1386"dependencies = ["atomic-waker","bytes",@@ -3320,9 +3324,9 @@ dependencies = [[[package]]name = "hashbrown"-version = "0.15.4"+version = "0.15.5"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "5971ac85611da7067dbfcabef3c70ebb5606018acd9e2a3903a0da507521e0d5"+checksum = "9229cfe53dfd69f0609a49f65461bd93001ea1ef889cd5529dd176593f5338a1"dependencies = ["allocator-api2","equivalent",@@ -3708,7 +3712,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"checksum = "fe4cd85333e22411419a0bcae1297d25e58c9443848b11dc6a86fefe8c78a661"dependencies = ["equivalent",- "hashbrown 0.15.4",+ "hashbrown 0.15.5","serde",]@@ -3870,7 +3874,7 @@ checksum = "03343451ff899767262ec32146f6d559dd759fdadf42ff0e227c7c48f72594b4"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -3971,9 +3975,9 @@ dependencies = [[[package]]name = "libbz2-rs-sys"-version = "0.2.1"+version = "0.2.2"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "775bf80d5878ab7c2b1080b5351a48b2f737d9f6f8b383574eebcc22be0dfccb"+checksum = "2c4a545a15244c7d945065b5d392b2d2d7f21526fba56ce51467b06ed445e8f7"[[package]]name = "libc"@@ -4061,7 +4065,7 @@ checksum = "5297962ef19edda4ce33aaa484386e0a5b3d7f2f4e037cbeee00503ef6b29d33"dependencies = ["anstream","anstyle",- "clap 4.5.44",+ "clap 4.5.45","escape8259",]@@ -4415,7 +4419,7 @@ dependencies = ["serde","serde_json","serde_urlencoded",- "thiserror 2.0.12",+ "thiserror 2.0.14","tokio","tracing","url",@@ -4525,7 +4529,7 @@ dependencies = ["flate2","futures","half",- "hashbrown 0.15.4",+ "hashbrown 0.15.5","lz4_flex","num","num-bigint",@@ -4563,7 +4567,7 @@ dependencies = ["regex","regex-syntax","structmeta",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -4632,7 +4636,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"checksum = "54acf3a685220b533e437e264e4d932cfbdc4cc7ec0cd232ed73c08d03b8a7ca"dependencies = ["fixedbitset",- "hashbrown 0.15.4",+ "hashbrown 0.15.5","indexmap 2.10.0","serde",]@@ -4690,7 +4694,7 @@ checksum = "6e918e4ff8c4549eb882f14b3a4bc8c8bc93de829416eacf579f1207a8fbf861"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -4763,7 +4767,7 @@ dependencies = ["heck 0.5.0","proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -4868,7 +4872,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"checksum = "ff24dfcda44452b9816fff4cd4227e1bb73ff5a2f1bc1105aa92fb8565ce44d2"dependencies = ["proc-macro2",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -4906,9 +4910,9 @@ dependencies = [[[package]]name = "proc-macro2"-version = "1.0.95"+version = "1.0.97"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "02b3e5e68a3a1a02aad3ec490a98007cbc13c37cbe84a3cd7b8e406d76e7f778"+checksum = "d61789d7719defeb74ea5fe81f2fdfdbd28a803847077cecce2ff14e1472f6f1"dependencies = ["unicode-ident",]@@ -4939,7 +4943,7 @@ dependencies = ["prost","prost-types","regex",- "syn 2.0.104",+ "syn 2.0.105","tempfile",]@@ -4953,7 +4957,7 @@ dependencies = ["itertools 0.14.0","proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5049,7 +5053,7 @@ dependencies = ["proc-macro2","pyo3-macros-backend","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5062,7 +5066,7 @@ dependencies = ["proc-macro2","pyo3-build-config","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5073,9 +5077,9 @@ checksum = "5a651516ddc9168ebd67b24afd085a718be02f8858fe406591b013d101ce2f40"[[package]]name = "quick-xml"-version = "0.38.0"+version = "0.38.1"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "8927b0664f5c5a98265138b7e3f90aa19a6b21353182469ace36d4ac527b7b1b"+checksum = "9845d9dccf565065824e69f9f235fafba1587031eda353c1f1561cd6a6be78f4"dependencies = ["memchr","serde",@@ -5095,7 +5099,7 @@ dependencies = ["rustc-hash 2.1.1","rustls","socket2 0.5.10",- "thiserror 2.0.12",+ "thiserror 2.0.14","tokio","tracing","web-time",@@ -5116,7 +5120,7 @@ dependencies = ["rustls","rustls-pki-types","slab",- "thiserror 2.0.12",+ "thiserror 2.0.14","tinyvec","tracing","web-time",@@ -5238,9 +5242,9 @@ dependencies = [[[package]]name = "rayon"-version = "1.10.0"+version = "1.11.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "b418a60154510ca1a002a752ca9714984e21e4241e804d32555251faf8b78ffa"+checksum = "368f01d005bf8fd9b1206fb6fa653e6c4a81ceb1466406b81792d87c5677a58f"dependencies = ["either","rayon-core",@@ -5248,9 +5252,9 @@ dependencies = [[[package]]name = "rayon-core"-version = "1.12.1"+version = "1.13.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "1465873a3dfdaa8ae7cb14b4383657caab0b3e8a0aa9ae8e04b044854c8dfce2"+checksum = "22e18b0f0062d30d4230b2e85ff77fdfe4326feb054b9783a3460d8435c8ab91"dependencies = ["crossbeam-deque","crossbeam-utils",@@ -5273,7 +5277,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"checksum = "76009fbe0614077fc1a2ce255e3a1881a2e3a3527097d5dc6d8212c585e7e38b"dependencies = ["quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5296,13 +5300,13 @@ dependencies = [[[package]]name = "redox_users"-version = "0.5.1"+version = "0.5.2"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "78eaea1f52c56d57821be178b2d47e09ff26481a6042e8e042fcb0ced068b470"+checksum = "a4e608c6638b9c18977b00b475ac1f28d14e84b27d8d42f70e0bf1e3dec127ac"dependencies = ["getrandom 0.2.16","libredox",- "thiserror 2.0.12",+ "thiserror 2.0.14",][[package]]@@ -5322,7 +5326,7 @@ checksum = "1165225c21bff1f3bbce98f5a1f889949bc902d3575308cc7b0de30b4f6d27c7"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5366,7 +5370,7 @@ version = "0.10.4"source = "registry+https://github.com/rust-lang/crates.io-index"checksum = "145bb27393fe455dd64d6cbc8d059adfa392590a45eadf079c01b11857e7b010"dependencies = [- "hashbrown 0.15.4",+ "hashbrown 0.15.5","memchr",]@@ -5396,9 +5400,9 @@ dependencies = [[[package]]name = "reqwest"-version = "0.12.22"+version = "0.12.23"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "cbc931937e6ca3a06e3b6c0aa7841849b160a90351d6ab467a8b9b9959767531"+checksum = "d429f34c8092b2d42c7c93cec323bb4adeb7c67698f70839adec842ec10c7ceb"dependencies = ["base64 0.22.1","bytes",@@ -5511,7 +5515,7 @@ dependencies = ["regex","relative-path","rustc_version",- "syn 2.0.104",+ "syn 2.0.105","unicode-ident",]@@ -5523,7 +5527,7 @@ checksum = "b3a8fb4672e840a587a66fc577a5491375df51ddb88f2a2c2a792598c326fe14"dependencies = ["quote","rand 0.8.5",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5656,9 +5660,9 @@ dependencies = [[[package]]name = "rustversion"-version = "1.0.21"+version = "1.0.22"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "8a0d197bd2c9dc6e53b84da9556a69ba4cdfab8619eb41a8bd1cc2027a0f6b1d"+checksum = "b39cdef0fa800fc44525c84ccb54a029961a8215f9619753635a9c0d2538d46d"[[package]]name = "rustyline"@@ -5751,7 +5755,7 @@ dependencies = ["proc-macro2","quote","serde_derive_internals",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5768,9 +5772,9 @@ checksum = "1c107b6f4780854c8b126e228ea8869f4d7b71260f962fefb57b996b8959ba6b"[[package]]name = "security-framework"-version = "3.2.0"+version = "3.3.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "271720403f46ca04f7ba6f55d438f8bd878d6b8ca0a1046e8228c4145bcbb316"+checksum = "80fb1d92c5028aa318b4b8bd7302a5bfcf48be96a37fc6fc790f806b0004ee0c"dependencies = ["bitflags 2.9.1","core-foundation",@@ -5830,7 +5834,7 @@ checksum = "5b0276cf7f2c73365f7157c8123c21cd9a50fbbd844757af28ca1f5925fc2a00"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5841,7 +5845,7 @@ checksum = "18d26a20a969b9e3fdf2fc2d9f21eda6c40e2de84c9408bb5d3b05d499aae711"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5864,7 +5868,7 @@ checksum = "175ee3e80ae9982737ca543e96133087cbd9a485eecc3bc4de9c1a37b47ea59c"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5876,7 +5880,7 @@ dependencies = ["proc-macro2","quote","serde",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5920,7 +5924,7 @@ dependencies = ["darling","proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -5975,9 +5979,9 @@ checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64"[[package]]name = "signal-hook-registry"-version = "1.4.5"+version = "1.4.6"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "9203b8055f63a2a00e2f593bb0510367fe707d7ff1e5c872de2f537b339e5410"+checksum = "b2a4719bff48cee6b39d12c020eeb490953ad2443b7055bd0b21fca26bd8c28b"dependencies = ["libc",]@@ -6077,7 +6081,7 @@ dependencies = ["similar","subst","tempfile",- "thiserror 2.0.12",+ "thiserror 2.0.14","tracing",]@@ -6100,7 +6104,7 @@ checksum = "da5fc6819faabb412da764b99d3b713bb55083c11e7e0c00144d386cd6a1939c"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -6154,7 +6158,7 @@ dependencies = ["proc-macro2","quote","structmeta-derive",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -6165,7 +6169,7 @@ checksum = "152a0b65a590ff6c3da95cabe2353ee04e6167c896b28e3b14478c2636c922fc"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -6208,7 +6212,7 @@ dependencies = ["proc-macro2","quote","rustversion",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -6242,7 +6246,7 @@ dependencies = ["serde","serde_json","serde_yaml",- "syn 2.0.104",+ "syn 2.0.105","typify","walkdir",]@@ -6266,9 +6270,9 @@ dependencies = [[[package]]name = "syn"-version = "2.0.104"+version = "2.0.105"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "17b6f705963418cdb9927482fa304bc562ece2fdd4f616084c50b7023b435a40"+checksum = "7bc3fcb250e53458e712715cf74285c1f889686520d79294a9ef3bd7aa1fc619"dependencies = ["proc-macro2","quote",@@ -6292,7 +6296,7 @@ checksum = "728a70f3dbaf5bab7f0c4b1ac8d7ae5ea60a4b5549c8a5914361c99147a709d2"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -6372,7 +6376,7 @@ dependencies = ["serde","serde_json","serde_with",- "thiserror 2.0.12",+ "thiserror 2.0.14","tokio","tokio-stream","tokio-tar",@@ -6409,11 +6413,11 @@ dependencies = [[[package]]name = "thiserror"-version = "2.0.12"+version = "2.0.14"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "567b8a2dae586314f7be2a752ec7474332959c6460e02bde30d702a66d488708"+checksum = "0b0949c3a6c842cbde3f1686d6eea5a010516deb7085f79db747562d4102f41e"dependencies = [- "thiserror-impl 2.0.12",+ "thiserror-impl 2.0.14",][[package]]@@ -6424,18 +6428,18 @@ checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]name = "thiserror-impl"-version = "2.0.12"+version = "2.0.14"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "7f7cf42b4507d8ea322120659672cf1b9dbb93f8f2d4ecfd6e51350ff5b17a1d"+checksum = "cc5b44b4ab9c2fdd0e0512e6bece8388e214c0749f5862b114cc5b7a25daf227"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -6561,7 +6565,7 @@ checksum = "6e06d43f1345a3bcd39f6a56dbb7dcab2ba47e68e8ac134855e7e2bdbaf8cab8"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -6753,7 +6757,7 @@ checksum = "81383ab64e72a7a8b8e13130c49e3dab29def6d0c7d76a03087b3cf71c5c6903"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -6841,7 +6845,7 @@ checksum = "f9534daa9fd3ed0bd911d462a37f172228077e7abf18c18a5f67199d959205f8"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -6850,6 +6854,12 @@ version = "1.18.0"source = "registry+https://github.com/rust-lang/crates.io-index"checksum = "1dccffe3ce07af9386bfd29e80c0ab1a8205a2fc34e4bcd40364df902cfa8f3f"+[[package]]+name = "typewit"+version = "1.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "97e72ba082eeb9da9dc68ff5a2bf727ef6ce362556e8d29ec1aed3bd05e7d86a"+[[package]]name = "typify"version = "0.4.2"@@ -6875,8 +6885,8 @@ dependencies = ["semver","serde","serde_json",- "syn 2.0.104",- "thiserror 2.0.12",+ "syn 2.0.105",+ "thiserror 2.0.14","unicode-ident",]@@ -6893,7 +6903,7 @@ dependencies = ["serde","serde_json","serde_tokenstream",- "syn 2.0.104",+ "syn 2.0.105","typify-impl",]@@ -6998,9 +7008,9 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821"[[package]]name = "uuid"-version = "1.17.0"+version = "1.18.0"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "3cf4199d1e5d15ddd86a694e4d0dffa9c323ce759fea589f00fef9d81cc1931d"+checksum = "f33196643e165781c20a5ead5582283a7dacbb87855d867fbc2df3f81eddc1be"dependencies = ["getrandom 0.3.3","js-sys",@@ -7097,7 +7107,7 @@ dependencies = ["log","proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105","wasm-bindgen-shared",]@@ -7132,7 +7142,7 @@ checksum = "8ae87ea40c9f689fc23f209965b6fb8a99ad69aeeb0231408be24920604395de"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105","wasm-bindgen-backend","wasm-bindgen-shared",]@@ -7167,7 +7177,7 @@ checksum = "17d5042cc5fa009658f9a7333ef24291b1291a25b6382dd68862a7f3b969f69b"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -7217,11 +7227,11 @@ dependencies = [[[package]]name = "whoami"-version = "1.6.0"+version = "1.6.1"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "6994d13118ab492c3c80c1f81928718159254c53c472bf9ce36f8dae4add02a7"+checksum = "5d4a4db5077702ca3015d3d02d74974948aba2ad9e12ab7df718ee64ccd7e97d"dependencies = [- "redox_syscall 0.5.17",+ "libredox","wasite","web-sys",]@@ -7311,7 +7321,7 @@ checksum = "a47fddd13af08290e67f4acabf4b459f647552718f683a7b415d290ac744a836"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -7322,7 +7332,7 @@ checksum = "bd9211b69f8dcdfa817bfd14bf1c97c9188afa36f4750130fcdf3f400eca9fa8"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -7614,7 +7624,7 @@ checksum = "38da3c9736e16c5d3c8c597a9aaa5d1fa565d0532ae05e27c24aa62fb32c0ab6"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105","synstructure",]@@ -7635,7 +7645,7 @@ checksum = "9ecf5b4cc5364572d7f4c329661bcc82724222973f2cab6f050a4e5c22f75181"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]@@ -7655,7 +7665,7 @@ checksum = "d71e5d6e06ab090c67b5e44993ec16b72dcbaabc526db883a360057678b48502"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105","synstructure",]@@ -7678,9 +7688,9 @@ dependencies = [[[package]]name = "zerovec"-version = "0.11.2"+version = "0.11.4"source = "registry+https://github.com/rust-lang/crates.io-index"-checksum = "4a05eb080e015ba39cc9e23bbe5e7fb04d5fb040350f99f34e338d5fdd294428"+checksum = "e7aa2bd55086f1ab526693ecbe444205da57e25f4489879da80635a46d90e73b"dependencies = ["yoke","zerofrom",@@ -7695,7 +7705,7 @@ checksum = "5b96237efa0c878c64bd89c436f661be4e46b2f3eff1ebb976f7ef2321d2f58f"dependencies = ["proc-macro2","quote",- "syn 2.0.104",+ "syn 2.0.105",][[package]]diff --git a/datafusion-testing b/datafusion-testingindex aed98a3bd7..e9f9e22ccf 160000--- a/datafusion-testing+++ b/datafusion-testing@@ -1 +1 @@-Subproject commit aed98a3bd7b7b9dc82da514ec876e8fe6fa7e10e+Subproject commit e9f9e22ccf09145a7368f80fd6a871f11e2b4481diff --git a/datafusion/sqllogictest/Cargo.toml b/datafusion/sqllogictest/Cargo.tomlindex 1f73f17701..7efc275743 100644--- a/datafusion/sqllogictest/Cargo.toml+++ b/datafusion/sqllogictest/Cargo.toml@@ -81,6 +81,7 @@ postgres = [[dev-dependencies]env_logger = { workspace = true }+regex = { workspace = true }tokio = { workspace = true, features = ["rt-multi-thread"] }[[test]]diff --git a/datafusion/sqllogictest/bin/sqllogictests.rs b/datafusion/sqllogictest/bin/sqllogictests.rsindex a4b85bdd1d..8dc2f15eef 100644--- a/datafusion/sqllogictest/bin/sqllogictests.rs+++ b/datafusion/sqllogictest/bin/sqllogictests.rs@@ -42,6 +42,7 @@ use crate::postgres_container::{};use datafusion::common::runtime::SpawnedTask;use std::ffi::OsStr;+use std::fs;use std::path::{Path, PathBuf};#[cfg(feature = "postgres")]@@ -124,6 +125,20 @@ async fn run_tests() -> Result<()> {let start = Instant::now();let test_files = read_test_files(&options)?;++ // Perform scratch file sanity check+ let scratch_errors = scratch_file_check(&test_files)?;+ if !scratch_errors.is_empty() {+ eprintln!("Scratch file sanity check failed:");+ for error in &scratch_errors {+ eprintln!(" {error}");+ }++ eprintln!("\nTemporary file check failed. Please ensure that within each test file, any scratch file created is placed under a folder with the same name as the test file (without extension).\nExample: inside `join.slt`, temporary files must be created under `.../scratch/join/`\n");++ return exec_err!("sqllogictests scratch file check failed");+ }+let num_tests = test_files.len();let errors: Vec<_> = futures::stream::iter(test_files).map(|test_file| {@@ -738,3 +753,67 @@ impl Options {}}}++/// Performs scratch file check for all test files.+///+/// Scratch file rule: In each .slt test file, the temporary file created must+/// be under a folder that is has the same name as the test file.+/// e.g. In `join.slt`, temporary files must be created under `.../scratch/join/`+///+/// See: <https://github.com/apache/datafusion/tree/main/datafusion/sqllogictest#running-tests-scratchdir>+///+/// This function searches for `scratch/[target]/...` patterns and verifies+/// that the target matches the file name.+///+/// Returns a vector of error strings for incorrectly created scratch files.+fn scratch_file_check(test_files: &[TestFile]) -> Result<Vec<String>> {+ let mut errors = Vec::new();++ // Search for any scratch/[target]/... patterns and check if they match the file name+ let scratch_pattern = regex::Regex::new(r"scratch/([^/]+)/").unwrap();++ for test_file in test_files {+ // Get the file content+ let content = match fs::read_to_string(&test_file.path) {+ Ok(content) => content,+ Err(e) => {+ errors.push(format!(+ "Failed to read file {}: {}",+ test_file.path.display(),+ e+ ));+ continue;+ }+ };++ // Get the expected target name (file name without extension)+ let expected_target = match test_file.path.file_stem() {+ Some(stem) => stem.to_string_lossy().to_string(),+ None => {+ errors.push(format!("File {} has no stem", test_file.path.display()));+ continue;+ }+ };++ let lines: Vec<&str> = content.lines().collect();++ for (line_num, line) in lines.iter().enumerate() {+ if let Some(captures) = scratch_pattern.captures(line) {+ if let Some(found_target) = captures.get(1) {+ let found_target = found_target.as_str();+ if found_target != expected_target {+ errors.push(format!(+ "File {}:{}: scratch target '{}' does not match file name '{}'",+ test_file.path.display(),+ line_num + 1,+ found_target,+ expected_target+ ));+ }+ }+ }+ }+ }++ Ok(errors)+}diff --git a/datafusion/sqllogictest/test_files/dictionary.slt b/datafusion/sqllogictest/test_files/dictionary.sltindex d241e61f33..9e8a394940 100644--- a/datafusion/sqllogictest/test_files/dictionary.slt+++ b/datafusion/sqllogictest/test_files/dictionary.slt@@ -456,4 +456,4 @@ statement okCREATE TABLE test0 AS VALUES ('foo',1), ('bar',2), ('foo',3);statement ok-COPY (SELECT arrow_cast(column1, 'Dictionary(Int32, Utf8)') AS column1, column2 FROM test0) TO 'test_files/scratch/copy/part_dict_test' STORED AS PARQUET PARTITIONED BY (column1);+COPY (SELECT arrow_cast(column1, 'Dictionary(Int32, Utf8)') AS column1, column2 FROM test0) TO 'test_files/scratch/dictionary/part_dict_test' STORED AS PARQUET PARTITIONED BY (column1);diff --git a/datafusion/sqllogictest/test_files/limit.slt b/datafusion/sqllogictest/test_files/limit.sltindex 77850c6ae7..d6b7559111 100644--- a/datafusion/sqllogictest/test_files/limit.slt+++ b/datafusion/sqllogictest/test_files/limit.slt@@ -799,7 +799,7 @@ CREATE TABLE src_table (# File 1:query ICOPY (SELECT * FROM src_table where part_key = 1)-TO 'test_files/scratch/parquet/test_limit_with_partitions/part-0.parquet'+TO 'test_files/scratch/limit/test_limit_with_partitions/part-0.parquet'STORED AS PARQUET;----3@@ -807,7 +807,7 @@ STORED AS PARQUET;# File 2:query ICOPY (SELECT * FROM src_table where part_key = 2)-TO 'test_files/scratch/parquet/test_limit_with_partitions/part-1.parquet'+TO 'test_files/scratch/limit/test_limit_with_partitions/part-1.parquet'STORED AS PARQUET;----4@@ -815,7 +815,7 @@ STORED AS PARQUET;# File 3:query ICOPY (SELECT * FROM src_table where part_key = 3)-TO 'test_files/scratch/parquet/test_limit_with_partitions/part-2.parquet'+TO 'test_files/scratch/limit/test_limit_with_partitions/part-2.parquet'STORED AS PARQUET;----3@@ -827,7 +827,7 @@ CREATE EXTERNAL TABLE test_limit_with_partitionsvalue INT)STORED AS PARQUET-LOCATION 'test_files/scratch/parquet/test_limit_with_partitions/';+LOCATION 'test_files/scratch/limit/test_limit_with_partitions/';query TTexplain@@ -853,7 +853,7 @@ physical_plan01)ProjectionExec: expr=[1 as foo]02)--SortPreservingMergeExec: [part_key@0 ASC NULLS LAST], fetch=103)----SortExec: TopK(fetch=1), expr=[part_key@0 ASC NULLS LAST], preserve_partitioning=[true]-04)------DataSourceExec: file_groups={3 groups: [[WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_limit_with_partitions/part-0.parquet], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_limit_with_partitions/part-1.parquet], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_limit_with_partitions/part-2.parquet]]}, projection=[part_key], file_type=parquet, predicate=DynamicFilterPhysicalExpr [ true ]+04)------DataSourceExec: file_groups={3 groups: [[WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/limit/test_limit_with_partitions/part-0.parquet], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/limit/test_limit_with_partitions/part-1.parquet], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/limit/test_limit_with_partitions/part-2.parquet]]}, projection=[part_key], file_type=parquet, predicate=DynamicFilterPhysicalExpr [ true ]query Iwith selection as (diff --git a/datafusion/sqllogictest/test_files/listing_table_statistics.slt b/datafusion/sqllogictest/test_files/listing_table_statistics.sltindex 7203767345..37daf551c2 100644--- a/datafusion/sqllogictest/test_files/listing_table_statistics.slt+++ b/datafusion/sqllogictest/test_files/listing_table_statistics.slt@@ -17,10 +17,10 @@# Test file with different schema order but generating correct statistics for tablestatement ok-COPY (SELECT * FROM values (1, 'a'), (2, 'b') t(int_col, str_col)) to 'test_files/scratch/table/1.parquet';+COPY (SELECT * FROM values (1, 'a'), (2, 'b') t(int_col, str_col)) to 'test_files/scratch/listing_table_statistics/1.parquet';statement ok-COPY (SELECT * FROM values ('c', 3), ('d', -1) t(str_col, int_col)) to 'test_files/scratch/table/2.parquet';+COPY (SELECT * FROM values ('c', 3), ('d', -1) t(str_col, int_col)) to 'test_files/scratch/listing_table_statistics/2.parquet';statement okset datafusion.execution.collect_statistics = true;@@ -29,13 +29,13 @@ statement okset datafusion.explain.show_statistics = true;statement ok-create external table t stored as parquet location 'test_files/scratch/table';+create external table t stored as parquet location 'test_files/scratch/listing_table_statistics';query TTexplain format indent select * from t;----logical_plan TableScan: t projection=[int_col, str_col]-physical_plan DataSourceExec: file_groups={2 groups: [[WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/table/1.parquet], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/table/2.parquet]]}, projection=[int_col, str_col], file_type=parquet, statistics=[Rows=Exact(4), Bytes=Exact(212), [(Col[0]: Min=Exact(Int64(-1)) Max=Exact(Int64(3)) Null=Exact(0)),(Col[1]: Min=Exact(Utf8View("a")) Max=Exact(Utf8View("d")) Null=Exact(0))]]+physical_plan DataSourceExec: file_groups={2 groups: [[WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/listing_table_statistics/1.parquet], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/listing_table_statistics/2.parquet]]}, projection=[int_col, str_col], file_type=parquet, statistics=[Rows=Exact(4), Bytes=Exact(212), [(Col[0]: Min=Exact(Int64(-1)) Max=Exact(Int64(3)) Null=Exact(0)),(Col[1]: Min=Exact(Utf8View("a")) Max=Exact(Utf8View("d")) Null=Exact(0))]]statement okdrop table t;diff --git a/datafusion/sqllogictest/test_files/push_down_filter.slt b/datafusion/sqllogictest/test_files/push_down_filter.sltindex 6e2972d96a..c5009c248c 100644--- a/datafusion/sqllogictest/test_files/push_down_filter.slt+++ b/datafusion/sqllogictest/test_files/push_down_filter.slt@@ -175,7 +175,7 @@ CREATE TABLE src_table (# File 1:query ICOPY (SELECT * FROM src_table where part_key = 1)-TO 'test_files/scratch/parquet/test_filter_with_limit/part-0.parquet'+TO 'test_files/scratch/push_down_filter/test_filter_with_limit/part-0.parquet'STORED AS PARQUET;----3@@ -183,7 +183,7 @@ STORED AS PARQUET;# File 2:query ICOPY (SELECT * FROM src_table where part_key = 2)-TO 'test_files/scratch/parquet/test_filter_with_limit/part-1.parquet'+TO 'test_files/scratch/push_down_filter/test_filter_with_limit/part-1.parquet'STORED AS PARQUET;----4@@ -191,7 +191,7 @@ STORED AS PARQUET;# File 3:query ICOPY (SELECT * FROM src_table where part_key = 3)-TO 'test_files/scratch/parquet/test_filter_with_limit/part-2.parquet'+TO 'test_files/scratch/push_down_filter/test_filter_with_limit/part-2.parquet'STORED AS PARQUET;----3@@ -203,14 +203,14 @@ CREATE EXTERNAL TABLE test_filter_with_limitvalue INT)STORED AS PARQUET-LOCATION 'test_files/scratch/parquet/test_filter_with_limit/';+LOCATION 'test_files/scratch/push_down_filter/test_filter_with_limit/';query TTexplain select * from test_filter_with_limit where value = 2 limit 1;----physical_plan01)CoalescePartitionsExec: fetch=1-02)--DataSourceExec: file_groups={3 groups: [[WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_filter_with_limit/part-0.parquet], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_filter_with_limit/part-1.parquet], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/parquet/test_filter_with_limit/part-2.parquet]]}, projection=[part_key, value], limit=1, file_type=parquet, predicate=value@1 = 2, pruning_predicate=value_null_count@2 != row_count@3 AND value_min@0 <= 2 AND 2 <= value_max@1, required_guarantees=[value in (2)]+02)--DataSourceExec: file_groups={3 groups: [[WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/push_down_filter/test_filter_with_limit/part-0.parquet], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/push_down_filter/test_filter_with_limit/part-1.parquet], [WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/push_down_filter/test_filter_with_limit/part-2.parquet]]}, projection=[part_key, value], limit=1, file_type=parquet, predicate=value@1 = 2, pruning_predicate=value_null_count@2 != row_count@3 AND value_min@0 <= 2 AND 2 <= value_max@1, required_guarantees=[value in (2)]query IIselect * from test_filter_with_limit where value = 2 limit 1;