-
Notifications
You must be signed in to change notification settings - Fork 409
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix #3026 #3043
Fix #3026 #3043
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, so far we used the exact opposite approach : since the files can be shared between build trees (think hardlinks), we explicitely REMOVE the write permissions when promoting them. We discussed and documented that altering produced files was probably a bad idea anyway as the build should be a computational graph.
IMO I don't think we should do this, or maybe only in copy mode (as opposed to hardlink).
In any case, if we want those write permissions, we should not remove them when caching rather that re-adding them when pulling, and redocument it correctly.
Yes, for promotion to the shared cache removing write permissions is the right thing to do. Here, it is for promotion to the source tree, i.e. when we have a rule with Another option to avoid #3043 would be to make dune delete the files before doing a promotion. But in any case it feels like whether we are using the shared cache or not shouldn't affect the read-only status of files copied to the source tree. |
Oh, absolutely then, sorry didn't notice this was about the "other" promotion. Maybe we should call the cache operation "caching a file" instead of promoting to avoid such confusion. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Indeed, that's a good idea! |
Signed-off-by: Jeremie Dimino <[email protected]>
Signed-off-by: Jeremie Dimino <[email protected]>
…lugin, dune-private-libs and dune-glob (2.2.0) CHANGES: - `dune test` is now a command alias for `dune runtest`. This is to make the CLI less idiosyncratic (ocaml/dune#3006, @shonfeder) - Allow to set menhir flags in the `env` stanza using the `menhir_flags` field. (ocaml/dune#2960, fix ocaml/dune#2924, @bschommer) - By default, do not show the full command line of commands executed by `dune` when `dune` is executed inside `dune`. This is to make integration tests more reproducible (ocaml/dune#3042, @diml) - `dune subst` now works even without opam files (ocaml/dune#2955, fixes ocaml/dune#2910, @fangyi-zhou and @diml) - Hint when trying to execute an executable defined in the current directory without using the `./` prefix (ocaml/dune#3041, fixes ocaml/dune#1094, @voodoos). - Extend the list of modifiers that can be nested under `with-accepted-exit-codes` with `chdir`, `setenv`, `ignore-<outputs>`, `with-stdin-from` and `with-<outputs>-to` (ocaml/dune#3027, fixes ocaml/dune#3014, @voodoos) - It is now an error to have a preprocessing dependency on a ppx rewriter library that is not marked as `(kind ppx_rewriter)` (ocaml/dune#3039, @snowleopard). - Fix permissions of files promoted to the source tree when using the shared cache. In particular, make them writable by the user (ocaml/dune#3043, fixes ocaml/dune#3026, @diml) - Only detect internal OCaml tools with `.opt` extensions. Previously, this detection applied to other binaries as well (@kit-ty-kate, @rgrinberg, ocaml/dune#3051). - Give the user a proper error message when they try to promote into a source directory that doesn't exist. (ocaml/dune#3073, fix ocaml/dune#3069, @rgrinberg) - Correctly build vendored packages in `-p` mode. These packages were incorrectly filtered out before. (ocaml/dune#3705, @diml) - Do not install vendored packages (ocaml/dune#3704, @diml) - `make` now prints a message explaining the main targets available (ocaml/dune#3085, fix ocaml/dune#3078, @diml) - Add a `byte_complete` executable mode to build programs as self-contained bytecode programs (ocaml/dune#3076, fixes ocaml/dune#1519, @diml)
…lugin, dune-private-libs and dune-glob (2.2.0) CHANGES: - `dune test` is now a command alias for `dune runtest`. This is to make the CLI less idiosyncratic (ocaml/dune#3006, @shonfeder) - Allow to set menhir flags in the `env` stanza using the `menhir_flags` field. (ocaml/dune#2960, fix ocaml/dune#2924, @bschommer) - By default, do not show the full command line of commands executed by `dune` when `dune` is executed inside `dune`. This is to make integration tests more reproducible (ocaml/dune#3042, @diml) - `dune subst` now works even without opam files (ocaml/dune#2955, fixes ocaml/dune#2910, @fangyi-zhou and @diml) - Hint when trying to execute an executable defined in the current directory without using the `./` prefix (ocaml/dune#3041, fixes ocaml/dune#1094, @voodoos). - Extend the list of modifiers that can be nested under `with-accepted-exit-codes` with `chdir`, `setenv`, `ignore-<outputs>`, `with-stdin-from` and `with-<outputs>-to` (ocaml/dune#3027, fixes ocaml/dune#3014, @voodoos) - It is now an error to have a preprocessing dependency on a ppx rewriter library that is not marked as `(kind ppx_rewriter)` (ocaml/dune#3039, @snowleopard). - Fix permissions of files promoted to the source tree when using the shared cache. In particular, make them writable by the user (ocaml/dune#3043, fixes ocaml/dune#3026, @diml) - Only detect internal OCaml tools with `.opt` extensions. Previously, this detection applied to other binaries as well (@kit-ty-kate, @rgrinberg, ocaml/dune#3051). - Give the user a proper error message when they try to promote into a source directory that doesn't exist. (ocaml/dune#3073, fix ocaml/dune#3069, @rgrinberg) - Correctly build vendored packages in `-p` mode. These packages were incorrectly filtered out before. (ocaml/dune#3705, @diml) - Do not install vendored packages (ocaml/dune#3704, @diml) - `make` now prints a message explaining the main targets available (ocaml/dune#3085, fix ocaml/dune#3078, @diml) - Add a `byte_complete` executable mode to build programs as self-contained bytecode programs (ocaml/dune#3076, fixes ocaml/dune#1519, @diml)
Mark the files promoted to the source tree as writable by the user.