-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Add more context to quit_if_file_exists
in configure.py
& delete config.toml in CI
#112916
Conversation
(rustbot has picked a reviewer for you, use r? to override) |
This comment has been minimized.
This comment has been minimized.
That's not correct, the |
Hm, it does not for me...
And that's it. I'll try to see what's going on with the script, maybe I'm just missing an environment variable or something |
That's the container running but encountering an error. |
I'm not sure what it's talking about
Trying to chase it down |
It was just a dirty obj directory. The error message is kind of subtle and doesn't provide any context, I'm surprised more people don't hit this issue. So I adjusted this PR to make the error stand out more and suggest checking that directory. Is that suitable, or would it be better to verify this directory doesn't exist in |
quit_if_file_exists
in configure.py
@rustbot ready |
quit_if_file_exists
in configure.py
quit_if_file_exists
in configure.py
☔ The latest upstream changes (presumably #112779) made this pull request unmergeable. Please resolve the merge conflicts. |
This doesn't seem right to me, it should be fine to re-run a given docker image in the same directory without purging the cache. Maybe the previous error message for an existing config.toml is misleading and (for example) should be dropped if we're going to create the same file? |
Do you or others also run into this error if running twice? It’s a bit weird that this hasn’t been addressed in some way or another, unless there’s something about my setup that makes me hit it for some reason. I can adjust this to just delete the config file and whatever else is needed to not conflict. |
What command are you running? |
Same script but with x86_64-gnu, my output is in the comment above #112916 (comment) |
Ah, I see, I think I had an old branch. The error seems new as of #110123 - I'm not sure that it should be an error, as the last comment on that PR suggests -- at minimum, we should silence that error during CI docker builds. |
Hm, yeah that is interesting to see the context. What do you think would be best? I think having a nicer error message is nice at a minimum, but I’ll update this PR to whatever makes the most sense. cc @jyn514 since you were involved in the PR that Mark linked |
i think we should change the CI image to run |
(i think my ideal behavior here would be "edit the file in place, keeping any existing settings, and only error if a setting conflicts", but that's too complicated to do in python and we can't move it to rust because it happens too early.) |
I think it's also true that every other configure I've worked with has overwritten the configuration in place with no warning. I'm not convinced humans are often running configure and automation rarely wants to extend previous state I think. Anyway, I'm fine with updating CI to delete configuration. That seems like a reasonable approach. |
@tgross35 Can you update this PR to remove the file just before this line: https://github.com/rust-lang/rust/blob/master/src/ci/run.sh#L174 ? I think that's the right place for this delta to work best. |
Whoops forgot about this one, yes will do that change soon |
Currently, having a dirty `obj/` directory is sufficient to abort CI tests. This results in errors like the following: ``` ... == end clock drift check == sccache: Starting the server... configure: error: Existing 'config.toml' detected. == clock drift check == ... ``` This is subtle and doesn't give a good idea as to what causes the issue. With this patch, the error becomes more prominent and a resolution is suggested: ``` == end clock drift check == sccache: Starting the server... configure: ERROR: Existing 'config.toml' detected. Exiting Is objdir '/home/tmgross/projects/rust/obj' clean? == clock drift check == ```
@Mark-Simulacrum this should be all set @rustbot ready |
@bors r+ rollup=iffy |
quit_if_file_exists
in configure.py
quit_if_file_exists
in configure.py
& delete config.toml in CI
☀️ Test successful - checks-actions |
Finished benchmarking commit (2aae331): comparison URL. Overall result: ❌ regressions - no action needed@rustbot label: -perf-regression Instruction countThis is a highly reliable metric that was used to determine the overall result at the top of this comment.
Max RSS (memory usage)ResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 650.942s -> 650.283s (-0.10%) |
If the
obj
directory isn't empty, the error message is subtle and not very helpful:This makes it stand out and suggests how to resolve the issue: