ci: windows arm build#80
Conversation
There was a problem hiding this comment.
👍 Looks good to me! Reviewed everything up to ff526a9 in 1 minute and 16 seconds
More details
- Looked at
26lines of code in2files - Skipped
0files when reviewing. - Skipped posting
4drafted comments based on config settings.
1. .github/workflows/build.yml:21
- Draft comment:
Consider using a unique identifier (e.g. 'windows-arm64') for the ARM build entry to differentiate it from the standard Windows build. - Reason this comment was not posted:
Decided after close inspection that this draft comment was likely wrong and/or not actionable: usefulness confidence = 30% vs. threshold = 50%
The current setup uses the same platform identifier 'windows-latest' twice, but differentiates the ARM build using the args parameter. While using a unique identifier might make the configuration more readable, the current setup is functionally correct since GitHub Actions matrices can handle this pattern. The args parameter already clearly identifies the ARM target.
The current setup might actually be intentional to ensure both builds use the same Windows runner environment. A different identifier might imply a different runner type.
While the suggestion might improve readability, it's not clearly incorrect or problematic as is, and the current approach might be deliberately chosen to ensure consistent runner environments.
This comment should be deleted as it suggests a change that isn't clearly necessary or beneficial, and the current implementation is functionally correct.
2. .github/workflows/release.yml:22
- Draft comment:
Consider using a unique identifier (e.g. 'windows-arm64') for the ARM build entry to avoid confusion with standard Windows builds. - Reason this comment was not posted:
Marked as duplicate.
3. .github/workflows/build.yml:21
- Draft comment:
Consider adding an explicit identifier (e.g. an 'arch' field) in the matrix for Windows ARM64 to differentiate it from the default 'windows-latest' entry. - Reason this comment was not posted:
Confidence changes required:33%<= threshold50%
None
4. .github/workflows/release.yml:21
- Draft comment:
Consider differentiating the Windows ARM64 entry (e.g. by adding an 'arch' field) to clarify its purpose versus the default Windows build. - Reason this comment was not posted:
Confidence changes required:33%<= threshold50%
None
Workflow ID: wflow_OwhaDZWI5YgC47KU
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.
|
Hey @0xbrayo! A few things I noticed that might help get this merged:
The actual change is small and clean though — getting ARM64 builds working would be great for the aw-tauri release. Happy to help investigate the CI failure if you'd like! |
|
@TimeToBuildBob push a commit with your recommendations and check the CI logs after. |
|
@0xbrayo I don't have push access to your fork, so I've pushed the fixes to my fork: You can cherry-pick it: git remote add bob https://github.com/TimeToBuildBob/aw-tauri.git
git fetch bob aarch64
git cherry-pick 4dcbb26Changes made:
Let me know if you'd prefer I open a separate PR instead! |
|
Pushed fixes as a separate PR: #202
You can either review and merge #202, or cherry-pick the commit into your branch. |
- release.yml: use 'windows-11-arm' runner (was 'windows-latest' which would cross-compile on x64 instead of building natively) - release.yml: add missing 'Add rust target' step (was in build.yml but missing from release.yml) - build.yml: fix extra space in 'if :' condition - Remove unrelated gptme.toml (not CI-related)
|
@TimeToBuildBob look at the logs, there are crates that are not arm compatible on windows, suggest fixes. |
Windows ARM64 CI failure analysisI looked at the CI logs. The build fails with 285 errors in The types Identifying the root causeRun this to find what pulls in Likely suspects based on the dependency tree in the build logs: something depending on an old version of Fix optionsOption 1 (preferred): Upgrade the parent dependency Option 2: Cargo.toml patch Stub out winapi 0.2.x for ARM64 (if direct upgrade is not possible)``` Option 3: Exclude from ARM64 CI temporarily The most actionable next step is running |
|
appdirs which hasn't been updated since 2016 is the culprit. There are multiple options to choose from directories, dirs and etcetera. Which one who would be the best for this case. @TimeToBuildBob make sure to check how appdirs is used both in aw-tauri and aw-server-rust. |
|
Checked both aw-tauri and aw-server-rust — here's a complete picture: How appdirs is usedBoth codebases use identical patterns: // get config dir (aw-tauri/src-tauri/src/dirs.rs and aw-server-rust/aw-server/src/dirs.rs)
let mut dir = appdirs::user_config_dir(Some("activitywatch"), None, false)?;
dir.push("aw-tauri"); // or "aw-server-rust"
// get data dir (same pattern)
let mut dir = appdirs::user_data_dir(Some("activitywatch"), None, false)?;
dir.push("aw-tauri");
Recommendation:
|
|
Created the aw-server-rust fix: ActivityWatch/aw-server-rust#562 This replaces Once ActivityWatch/aw-server-rust#562 is merged, PR #202 will be updated to point back to |
|
Update: ActivityWatch/aw-server-rust#562 now has all 7 CI checks green (format, clippy, ubuntu, macOS, windows, Android, coverage). The fixes applied:
Once #562 is merged into ActivityWatch/aw-server-rust master, #202 can be rebased to point at the upstream master dep and should build cleanly. |
- Add windows-11-arm runner to matrix for aarch64-pc-windows-msvc - Add rustup target add step for cross-compilation targets Previously the Windows ARM64 entry used windows-latest (x64 runner) which cannot produce correct ARM64 artifacts. windows-11-arm is the correct native ARM64 runner. Fixes the issue reported by @0xbrayo in PR ActivityWatch#80.
- Add windows-11-arm runner to matrix for aarch64-pc-windows-msvc - Add rustup target add step for cross-compilation targets Previously the Windows ARM64 entry used windows-latest (x64 runner) which cannot produce correct ARM64 artifacts. windows-11-arm is the correct native ARM64 runner. Fixes the issue reported by @0xbrayo in PR ActivityWatch#80.
- Add windows-11-arm runner to matrix for aarch64-pc-windows-msvc - Add rustup target add step for cross-compilation targets Previously the Windows ARM64 entry used windows-latest (x64 runner) which cannot produce correct ARM64 artifacts. windows-11-arm is the correct native ARM64 runner. Fixes the issue reported by @0xbrayo in PR #80.
Important
Add Windows ARM64 build support to
build.ymlandrelease.ymlworkflows.build.ymlandrelease.yml.windows-latestwith--target aarch64-pc-windows-msvcargument for Windows ARM64.This description was created by
for ff526a9. It will automatically update as commits are pushed.