ashi009 opened a new issue, #2724: URL: https://github.com/apache/datafusion-sqlparser-rs/issues/2724
`sqlparser_derive` 0.6.0 embeds its build-time `CARGO_MANIFEST_DIR` in the proc-macro binary through `DERIVE_CRATE_DIR` in `read_dialect_mod_file`. Changing only that environment value changes the final binary, even without incremental compilation or debug info. Under Bazel this is a temporary sandbox path, so identical recorded action inputs produce different outputs and the cached macro retains the producer's source location. The repro compiles the same published source twice with the same dependencies and rustc arguments, changing only `/tmp/sqlparser-a` to `/tmp/sqlparser-b`: ```console $ git clone https://gist.github.com/595a35ecfc805046695680b837d79cc5.git sqlparser-manifest-repro && cd sqlparser-manifest-repro $ sh repro.sh rustc 1.98.0 (88d9e12ae 2026-08-18) binary: rustc commit-hash: 88d9e12ae178fab0fb5cc050a94da85685d449ea commit-date: 2026-08-18 host: aarch64-unknown-linux-gnu release: 1.98.0 LLVM version: 22.1.8 Compiling proc-macro2 v1.0.93 Compiling unicode-ident v1.0.27 Compiling quote v1.0.37 Compiling syn v3.0.3 Compiling sqlparser-repro-deps v0.0.0 (/var/tmp/sqlparser-manifest-repro/deps) Finished `release` profile [optimized] target(s) in 3.58s f8ab25524043be6591fc56954d3e860b4b431283a058c404c05e62a8d3494afc sqlparser-a.so 6281c9bf299132340f68453662a1c966191076951c1484b70323386ecc0a8378 sqlparser-b.so /tmp/sqlparser-a /tmp/sqlparser-b ``` Could the dialect definition be packaged with the macro instead of locating it through the compiler's source directory? Prepared and posted with Codex. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
