I can’t pass the test build_solutions_rust https://gitlab.com/autonomicmind/challenges/-/jobs/628059433 my code compiles and even pass the linter, but I’m having this error in the test. and I don’t know why. Any help would be appreciated.
Hi @perceived-doubt, seems like rustfmt is complaning about some lines not being properly indented.
Hi @infinite-loop I’m pretty sure my identation is correct (4 spaces) and the thing is, locally, rustfmt does not complain. I’m running $ rustfmt --check dfuribez.rs am I missing any flag or something?
4 spaces is not correct! the default indentation level is … ? 4 or ?
only for certain languages is 4, and just because of…
read the code of the CI and the rustfmt config
Hi @blue-snot according to the documentation the standard indentation should be four spaces https://github.com/rust-dev-tools/fmt-rfcs/blob/master/guide/guide.md#indentation-and-line-width
I’m going to read the CI code, thanks
Edit: Oh, I see it now, the CI is configured for two spaces as identation, thanks.
each language define his own flavor, but i am referring to our style guideline
Also, this is the current config for rustfmt: https://gitlab.com/autonomicmind/challenges/-/blob/master/build/builders/solutions/rust/builder.sh#L5
Not adding such config explains why it passes locally but fails on both local and gitlab jobs.