Skip to content
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

issue rolling into google3 #3959

Open
devoncarew opened this issue Jan 6, 2025 · 4 comments
Open

issue rolling into google3 #3959

devoncarew opened this issue Jan 6, 2025 · 4 comments

Comments

@devoncarew
Copy link
Member

We have an issue rolling dartdoc into the sdk due to a failure rolling into google3. The roll CL is:

https://dart-review.googlesource.com/c/sdk/+/403181

The failure is visible in c-build; it looks like perhaps an infrastructure issue? INTERNAL Failed to apply patch ... .../dart/dartdoc/lib/resources/styles.css: Cannot apply hunk .... I see that lib/resources/styles.css changed quite a bit in recent PRs (#3919 and #3920), but I don't see any internal patch to the file that we'd be conflicting with.

cc @iinozemtsev and @srawlins

@srawlins
Copy link
Member

srawlins commented Jan 6, 2025

Yikes good catch Devon. I will look this week into fixing the patch (I'll also look into whether it's still needed); probably a bit of wiring is needed for the new Sass stuff.

@iinozemtsev
Copy link
Member

I also don't see any internal patches and the file contents in g3 seems to match exactly to git contents at metadata revision, looking

@iinozemtsev
Copy link
Member

iinozemtsev commented Jan 7, 2025

This is a quite hilarious bug in our rolling infra and I didn't expect to face something like this in 2025 :)

lib/resources/styles.css starts with EF BB BF bytes, but you won't see it almost anywhere, because it's a UTF-8 encoded byte order mark, and at least in Dart it is discarded at the beginning of an input during UTF-8 decoding.

However git diff includes this into added/removed lines, and it is not discarded, since it is not at the beginning of an input (though you can't really see it in github UI, so I've added a text):

diff --git a/lib/resources/styles.css b/lib/resources/styles.css
index 919c4544..be7cdce7 100644
--- a/lib/resources/styles.css
+++ b/lib/resources/styles.css
@@ -1 +1 @@
-(BOM is Here!).light-theme...
+(BOM is Here!).light-theme...

As a result, our infra cannot find an original fragment (with BOM) trying to patch a file contents (without BOM), I'll make a fix.

@devoncarew
Copy link
Member Author

Wow - that's a subtle issue. Thanks for running this down!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants