Skip to content

[CI] clang-format action broken #97060

@nikic

Description

@nikic
Contributor

The code formatting action appears to be broken, and no longer reports incorrect formatting. See e.g. #97029, but I've noticed this in multiple PRs recently. Not sure when exactly it broke.

Activity

llvmbot

llvmbot commented on Jun 28, 2024

@llvmbot
Member

@llvm/issue-subscribers-infrastructure

Author: Nikita Popov (nikic)

The code formatting action appears to be broken, and no longer reports incorrect formatting. See e.g. https://github.com//pull/97029, but I've noticed this in multiple PRs recently. Not sure when exactly it broke.
tstellar

tstellar commented on Jun 28, 2024

@tstellar
Collaborator

Maybe this one: 5914a56 ?

It's not just that the comment is missing, the job is passing even if there is incorrect formatting, right?

nikic

nikic commented on Jun 28, 2024

@nikic
ContributorAuthor

Yeah, the job is passing.

7620fe0 is another possible culprit.

boomanaiden154

boomanaiden154 commented on Jun 28, 2024

@boomanaiden154
Contributor

I'll take a look.

boomanaiden154

boomanaiden154 commented on Jun 28, 2024

@boomanaiden154
Contributor

It doesn't even seem like the job is running currently? There are quite a few other jobs missing in new PRs as well. The last code formatting job currently ran 25+ minutes ago and PRs have definitely been updated more recently.

I also can't get the job to run on my fork currently.

It seems like maybe just pull_request jobs? All the pull_request_target jobs, like the PR labelers, seem to be working fine.

boomanaiden154

boomanaiden154 commented on Jun 28, 2024

@boomanaiden154
Contributor

https://www.githubstatus.com/incidents/9vwllhs2w1kj

I guess I'll wait for that to be fixed and then get to investigating.

tstellar

tstellar commented on Jun 28, 2024

@tstellar
Collaborator

Here is a job from a few hours ago that correctly failed: https://github.com/llvm/llvm-project/actions/runs/9714796529

boomanaiden154

boomanaiden154 commented on Jun 28, 2024

@boomanaiden154
Contributor

It correctly failed on my fork too: https://github.com/boomanaiden154/llvm-project/actions/runs/9716540595/job/26820327869?pr=48

I wonder if it's the one cpp file case?

boomanaiden154

boomanaiden154 commented on Jun 28, 2024

@boomanaiden154
Contributor

It's 7620fe0.

It breaks at least the one cpp file case.

I'll revert to get things back to the way they were and ping on the PR.

ldionne

ldionne commented on Jul 4, 2024

@ldionne
Member

It's 7620fe0.

It breaks at least the one cpp file case.

Do you mean the case where a single libc++ header is modified and that header has no extension?

I'll revert to get things back to the way they were and ping on the PR.

Thanks, I'll take a look. I was away at a WG21 meeting last week.

boomanaiden154

boomanaiden154 commented on Jul 4, 2024

@boomanaiden154
Contributor

Do you mean the case where a single libc++ header is modified and that header has no extension?

A single c++ file in llvm/. I haven't done a lot of investigation, but something like the following diff would pass even though clang format should fail it:

diff --git a/llvm/lib/CodeGen/MLRegAllocEvictAdvisor.cpp b/llvm/lib/CodeGen/MLRegAllocEvictAdvisor.cpp
index 5698f6d6fea00..2c3e0f782c567 100644
--- a/llvm/lib/CodeGen/MLRegAllocEvictAdvisor.cpp
+++ b/llvm/lib/CodeGen/MLRegAllocEvictAdvisor.cpp
@@ -10,6 +10,8 @@
 //
 //===----------------------------------------------------------------------===//
 
+// This line should never get through the formatting job clang-format please format this into something that is actually reasonable.
+
 #include "AllocationOrder.h"
 #include "RegAllocEvictionAdvisor.h"
 #include "RegAllocGreedy.h"
ldionne

ldionne commented on Jul 9, 2024

@ldionne
Member

@boomanaiden154 Thanks, investigating in #98227

ldionne

ldionne commented on Aug 29, 2024

@ldionne
Member

This should have been closed when I merged #98227.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

    Development

    No branches or pull requests

      Participants

      @tstellar@nikic@ldionne@EugeneZelenko@boomanaiden154

      Issue actions

        [CI] clang-format action broken · Issue #97060 · llvm/llvm-project