Conversation
|
47662ec to
322c5ab
Compare
|
Hm okay this gives a big speed-up but a test is failing |
|
I think the small runner on the @MichaReiser would you be interested in investigating if this is a real bug with Dev Drives? I'm not sure if there are known issues with the file watcher? I'm happy to procure more logs if you tell me how. Or I can test a minimal snippet, if you can extract the core folder-watching behavior or point me to it? |
| @@ -0,0 +1,62 @@ | |||
| # Configures a drive for testing in CI. | |||
There was a problem hiding this comment.
Scary, but just copied over from uv.
052303b to
4977a38
Compare
|
Glorious, here are the logs |
|
(they don't seem helpful — not sure how to get more...) |
How dare you! I improved them a lot and I think there's some useful content in them. The specific test tests if the file watcher correctly handles the case where an entire directory gets deleted, specifically the Now, we could fix the test to expect the events for one of the files instead of the directories, and I suspect it would then pass just fine on all platforms. However, this reveals a more fundamental problem with changing to dev drives: Windows's file-watching API returns different events depending on whether the path is a dev drive or not. Migrating to a dev drive would, therefore, remove the coverage for regular Windows drives, which I consider fairly important. That means I'm not sure if we should change our runner to use dev drivers. Is there a way to only use a dev drive for some directories, e.g., not the directory created by tempdir? |
.github/workflows/ci.yaml
Outdated
| RED_KNOT_LOG: debug | ||
| RUST_LOG: debug |
There was a problem hiding this comment.
This should not be needed when you use testing::setup_tracing() It always writes the logs and they should be visible if the test fails
| } else { | ||
| # The size (20 GB) is chosen empirically to be large enough for our | ||
| # workflows; larger drives can take longer to set up. | ||
| $Volume = New-VHD -Path C:/ruff_dev_drive.vhdx -SizeBytes 20GB | |
There was a problem hiding this comment.
We can probably get away with a smaller drive for Ruff.
There was a problem hiding this comment.
I actually tried 5 GB then 10 GB and both ran out of space during compilation.
|
|
||
| # Note we use `Get-PSDrive` is not sufficient because the drive letter is assigned. | ||
| if (Test-Path "D:\") { | ||
| Write-Output "Using existing drive at D:" |
There was a problem hiding this comment.
A beautiful mix of space and tab indentation. hehe
|
Funny, I read as: we expected these changes but did not observe them. Now I see — the message is much more helpful read that way. |
Yeah I agree coverage for a regular drive seems important. It sounds like it'd actually be important to get both coverage for a Dev Drive and the regular file system. I can own that.
Yeah, but then we'll probably miss out on the benefits. I can explore. |
|
That's fair. There's definetely still room for improvement. Ideally, the message would also say which event we expected. But it's much better than in the past where it just told you: Too bad, didn't work 😆 |
|
Thanks for taking a look Micha. I see this as relatively low priority, but I can explore it in my spare time, |
|
Thank you. Excluding the temp directory might be fine for Ruff. We don't write as many files as you do in uv. It's only a handful tests that make use of temp (although I don't know if cargo or other tools make heavy use of temp) |
I really misunderstood this in #15664 (comment)
|
From 6m 15s -> 3m 54s (total runtime) See also astral-sh/uv#14122 We don't use a Dev Drive here so this is trivial (ref #15664)
61f58df to
6965001
Compare
This reverts commit 82dc27f.
CodSpeed Performance ReportMerging #15664 will not alter performanceComparing Summary
|
|
I'll close this as it looks pretty stale but please re-open it if you think we should keep this around. |
Investigating the benefits of this here.
Requires Windows 2025, switching over in #15661