Skip to content
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(rules): don't descend into automatic subdirs infinitely #7208

Conversation

anmonteiro
Copy link
Collaborator

No description provided.

@rgrinberg
Copy link
Member

For anyone reading, this PR does two things:

  1. The rules no longer tell the engine about fake directories with rules such as .bin/.bin. This isn't really an observable change, and "infinite descent" occurs if you try to traverse all the directories with rules in them. Thankfully, dune doesn't do this anywhere at the moment.

  2. Another example of the rules reporting fake sub directories with rules to the engine is in the melange stanza. For example, if we had a stanza such as (melage.emit (target foo)), then foo/ would be reported as a directory for all the rules under emit. This would mess up stale artifact deletion.

@anmonteiro this reminds me, shall we officially forbid nested melange.emit stanzas?

@rgrinberg rgrinberg merged commit 53f0674 into ocaml:main Mar 2, 2023
@anmonteiro anmonteiro deleted the anmonteiro/filter-automatic-subdirs-in-gen-rules branch March 2, 2023 19:23
@anmonteiro
Copy link
Collaborator Author

@anmonteiro this reminds me, shall we officially forbid nested melange.emit stanzas?

Adding to my list.

jchavarri added a commit to jchavarri/dune that referenced this pull request Nov 15, 2023
* main: (56 commits)
  feature: add terminal ui backend based on NoTTY (ocaml#6996)
  doc(coq): update documentation about coqdep
  fix(rules): don't descend into automatic subdirs infinitely (ocaml#7208)
  benchmark: add warm run (ocaml#7198)
  test: vendored and public libs (ocaml#7197)
  test: use sh in concurrent test (ocaml#7205)
  fix: custom log file path (ocaml#7200)
  test(melange): add test exercising ocaml#7104 (ocaml#7204)
  test(melange): add a test that introduces rules in the target dir (ocaml#7196)
  test: duplicate packages in vendor dir (ocaml#7194)
  melange: interpret `melc --where` as a list of `:`-separated paths (ocaml#7176)
  perf: add synthetic benchmark (ocaml#7189)
  Test case for bug report (ocaml#6725)
  Add test illustrating ocaml#6575 (ocaml#6576)
  chore: add rule streaming proposal (ocaml#7195)
  test(stdlib): merge wrapped/unwrapped tests
  test: move all stdlib tests
  fix: allow unwrapped libraries with `(stdlib ..)`
  test: demonstrate crash in modules.ml when `(stdlib .. )` used with `(wrapped false)`
  fix(install): respect display options (ocaml#7116)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants