-
Notifications
You must be signed in to change notification settings - Fork 54
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
Update windows crate to v0.48 #257
Conversation
Hello @paul-hansen, thank you for this PR.
|
Done, thanks for the heads up. Haven't used release-please before, will know to keep an eye out for it now 👍 I did run |
@paul-hansen Thanks for this update. Please revert your Cargo.lock changes, then run |
Updated cargo.lock file with minimal changes. |
@paul-hansen I just approved the GitHub Actions workflow for you. But I can tell you now that the tests in the accesskit_windows crate don't compile. |
My bad, didn't realize |
@mwcampbell just a heads up I think your CI might not be checking the tests in |
Looks like the error the
This happens when |
Added a CI step that should only run on the windows matrix to run the tests for |
I had separately debugged that issue with |
My PR is #261, so once that lands, you can rebase ahead of it and things should be good. |
Since #261 is a change that's exactly the same as a change in this PR, I don't think there would be a conflict, but do lmk if I need to do anything. |
@paul-hansen Please rebase your branch on top of the latest commit in main, just to make sure this PR passes the updated CI. I'm sorry I've been slow to handle this PR; I won't delay any further, but I think it's good to do the rebase to be sure before we merge. Thanks. |
This reverts commit c973828.
.github/workflows/ci.yml
Outdated
@@ -64,5 +64,12 @@ jobs: | |||
with: | |||
command: test | |||
|
|||
- name: cargo test -p accesskit_windows | |||
if: matrix.os == 'windows-2019' | |||
uses: actions-rs/cargo@v1 |
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.
This should no longer use any actions-rs
stuff… just run the cargo command directly.
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.
Actually, could you pass —workspace
to the existing test run instead
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.
I don't think that works because it also runs the windows tests on non-windows platforms and mac tests on the windows platform.
At least when I run it locally I get this error
--> C:\Users\Paul\.cargo\registry\src\index.crates.io-6f17d22bba15001f\objc2-0.3.0-beta.3.patch-leaks.2\src\foundation\mod.rs:102:36
|
102 | #[link(name = "Foundation", kind = "framework")]
For more information about this error, try `rustc --explain E0455`.
error: could not compile `objc2` (lib) due to previous error
"Foundation" sounds like an Apple thing I think.
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.
I can try it though if you want
No worries! Rebased. On main now I noticed that
|
You mean that you saw those tests fail when running them manually, not in CI, right? If so, then what Windows version were you running them on, and did you do other things while waiting for the tests to build and run? The only time I've seen those tests fail, since getting them to pass in the first place, was if I did something else while waiting, because then the test window wouldn't grab focus. |
Windows 11 Pro 22H2 22621.2070 I was running them manually yes, though I didn't do anything between runs. I was running it from the clion's built in terminal with |
I do all my work from Command Prompt, so I hadn't considered that working in an IDE like CLion (or for that matter, probably VSCode) would be a problem. It doesn't surprise me, though. Windows's rules for whether a new window automatically gets focus are complicated, and it's likely that a new window opened by an application launched from a terminal embedded in some other application wouldn't grab focus as a window launched from the built-in terminal does. As long as the tests consistently pass in CI, I think we'll have to accept this as a known issue. |
Looks like proc-macro2 updated again since I made this PR. Removed my change to the lock file for that so generate-headers is working again. Looking good on my end again let me know if anyone sees anything else though. |
@waywardmonkeys Please let us know when you're satisfied with the CI change. As soon as I get your approval on that, I'm ready to merge. |
Please try the |
Trying it but I think it will fail (see comment in thread), I'll revert if it fails. |
Ah, right, so I am okay with however it ends up. |
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.
Approved after the likely revert of the test change.
Approved in advance so I can sleep. :) |
This reverts commit d2e23c9.
It did fail, reverted now. Failed run was here: https://github.com/AccessKit/accesskit/actions/runs/5800495126/job/15722882417?pr=257
1pm here, hi from the other side of the world 👋 Sorry for keeping you up, appreciated your help though! |
Your Windows-specific check in the CI is good enough for now, but soon we will be better off adding the adapter package name in the test matrix, so we can easily run tests for every adapter on their respective platforms. |
Looking to reduce binary size and compile times on Windows by only having one version of the windows crate in my apps.
Should the cargo.lock file be removed from this repo? I was under the impression it normally should be ignored for libraries and it is the bulk of the lines changed in this PR.