Open dirkweissenborn opened 2 years ago
cc @architkulkarni ?
Thanks @dirkweissenborn, could you please give an example? Are you saying this is a bug in how the pathspec
library interprets !
?
Sorry for not being more explicit.
The problem is that negation doesn't work. So writing something like "!.py" as a pattern to exclude should exclude everything but .py files. It doesn't. The reason it doesn't (i think) is the line i linked. The match is computed on the not negated pattern (".py") but the "include" attribute is not taken into consideration.
On Wed, Sep 14, 2022, 20:26 Archit Kulkarni @.***> wrote:
Thanks @dirkweissenborn https://github.com/dirkweissenborn, could you please give an example? Are you saying this is a bug in how the pathspec library interprets !?
— Reply to this email directly, view it on GitHub https://github.com/ray-project/ray/issues/28502#issuecomment-1247147641, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAKTUG5XD44N7OJ3B5MU72DV6IKF7ANCNFSM6AAAAAAQMGY64I . You are receiving this because you were mentioned.Message ID: @.***>
What happened + What you expected to happen
Ray doesn't respect negated patterns when setting up
excludes
in runtime_env. The reason is that includes is never used in the regex matcher here: https://github.com/ray-project/ray/blob/master/python/ray/_private/thirdparty/pathspec/pattern.py#L128Versions / Dependencies
2.0
Reproduction script
Not necessary.
Issue Severity
Medium: It is a significant difficulty but I can work around it.