-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Run builds on both Mac OS and Linux #830
Conversation
This would have helped us catch #570.
d142758
to
630ff7c
Compare
@schultetwin1 or @ericye16, would you be able to help debug why the tests don't work on Mac OS? I was hoping they would run after #572, but now that I actually try running them, I see this error:
|
I'm not repro-ing these on my M1 Mac. However, based on some searching, I think this is rust-lang/rust#111487 On my local machine, the |
I tried a few workarounds and they're all failing. These comments in the stdc equivalent are a bit disheartening -- https://github.com/rust-lang/rust/blob/master/library/std/src/sys/unix/fs.rs#L694-L741 |
First (stupid) question, why are you creating |
I don't know how to create an |
Ok looks like you are correct, OsStr can't deal with 0 terminated strings by itself.. |
48ff8c3
to
0a143e8
Compare
@@ -142,7 +141,6 @@ mod tests { | |||
use std::error::Error; | |||
|
|||
#[test] | |||
#[cfg(not(miri))] |
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.
These might be nice to have, else cargo +nightly miri test
fails (at least on MacOS)
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.
Yes, the change is not bad in itself — I would just prefer to have it in a different PR and with an explanation for the students who end up reading it later.
The changes might be good, but I want to keep this PR small and focused. If we end up with the extra `cfg` statements, we should include a comment to let students know what they do: we’re targeting people new to Rust, so we need to be careful with explanations.
Sorry! I arrived late for the party! Glad to see that it is fixed now. I was actually getting a failed assertion error!!
|
Interesting! @domenukk showed me the same error in chat... looks like an off by one error to me, which is consistent with using the wrong layout. |
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.
LGTM :)
Looks like the CI is stuck. Not sure if re-running all jobs will fix that. We usually push a superficial commit to fix that. |
It's a bit more annoying here: I've marked the old "cargo" check as required — but this check is now replaced with two checks: "cargo (ubuntu-latest)" and "cargo (macos-latest)". Those checks are not yet required. Because we have all the translations (which also run |
More like an "off-by-a-lot" error with accidental memory laying around |
This would have helped us catch #570.