xihaian251 commented on PR #946: URL: https://github.com/apache/burr/pull/946#issuecomment-6543176214
I found one additional issue in `join_within` while testing the #319 integration on Windows. Under concurrent directory creation, I ran 8 threads creating 3 applications each across 4 partitions. In 2 of 6 rounds, `join_within` intermittently raised `InvalidIdentifier` for a target that was still inside the project directory. Instrumentation showed that an immediate retry succeeded with the same resolved path strings. This appears to be a transient inconsistency in `os.path.realpath`'s path representation during concurrent directory creation, rather than an actual containment violation. In my #319 integration candidate, a single re-check in the caller avoids this false rejection while still rejecting genuine path escapes. I believe the more appropriate long-term fix would be in the shared `join_within` helper itself. One possible approach is to normalize both resolved paths with `os.path.normcase` and retry the containment comparison once. Another possibility worth considering is `os.path.samestat`. I haven't modified your branch or opened a separate PR for this. I wanted to share the reproducible behavior first and get your thoughts on the appropriate fix. Thanks! -- 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]
