PR suggestions generated by clang-tidy-review are taken from the exported fixes ('--export-fixes' option). For example:
- DiagnosticName: misc-const-correctness
DiagnosticMessage:
Message: 'variable ''isSyncPacket'' of type ''bool'' can be declared ''const'''
FilePath: '/Users/jmillan/src/mediasoup/worker/src/RTC/SvcConsumer.cpp'
FileOffset: 19028
Replacements:
- FilePath: '/Users/jmillan/src/mediasoup/worker/src/RTC/SvcConsumer.cpp'
Offset: 19033
Length: 0
ReplacementText: 'const '
Level: Warning
BuildDirectory: '/Users/jmillan/src/mediasoup/worker/out/Release/build'
These fixes do not consider the format defined in .clang-format, even though .clang-tidy indicates so via FormatStyle: file.
This is a known limitation as indicated here.
The problem is that the current flow is broken:
- Create a PR.
- clang-tidy-review github action runs.
- It suggests a code change (with wrong format)
- Suggestion is committed.
- GH actions are restarted.
- The GH action running clang-format fails.
PR suggestions generated by
clang-tidy-revieware taken from the exported fixes ('--export-fixes' option). For example:These fixes do not consider the format defined in .clang-format, even though .clang-tidy indicates so via
FormatStyle: file.This is a known limitation as indicated here.
The problem is that the current flow is broken: