Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

`dotnet format style --verify-no-changes` fails with naming violations and unnecessary imports

Aperta Adatta ai principianti
#624 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 7 giorni

@nmummau ci sta già lavorando.

Dal 20/10/2026.

  • #625 di @nmummau — aperta

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
80/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
csharp
Ambito
tooling

Direzione di ricerca

Inizia dai file elencati: i quattro file della libreria principale con diagnostiche IDE1006 e i cinque file di test con diagnostiche IDE0005. Leggi il .editorconfig del repository ed esamina i campi indicati, il parametro del costruttore e le direttive using; verifica come Analyzed.cs viene compilato dai test dell’analizzatore. Esegui dotnet format style --verify-no-changes dalla directory principale del repository per confermare il completamento, quindi verifica che i test dell’analizzatore continuino a passare.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Describe the bug

Running the style verification command from the repository root reports IDE1006 naming violations in four core library files and IDE0005 errors in five test files. The source does not satisfy the repository's existing .editorconfig rules, causing the verification command to fail.

To reproduce

  1. Use an Eventuous checkout at revision 60a76433.

  2. From the repository root, run:

    dotnet format style --verify-no-changes
    
  3. Observe the naming warnings and unnecessary-using errors below.

Expected behavior

The command exits successfully without reporting style violations or requiring source changes. The existing analyzer tests should continue to pass.

Actual behavior

The command reports the following diagnostics. Paths are relative to the repository root; repeated diagnostics and project-path suffixes have been omitted for readability. Line numbers refer to the affected revision.

src/Core/src/Eventuous.Diagnostics/EventuousDiagnostics.cs(18,38): warning IDE1006: Naming rule violation: These words must begin with upper case characters: listener
src/Core/src/Eventuous.Persistence/ExpectedStreamVersion.cs(14,36): warning IDE1006: Naming rule violation: The first word, 'Value', must begin with a lower case character
src/Core/src/Eventuous.Serialization/EventSerializer.cs(13,30): warning IDE1006: Naming rule violation: Prefix '_' is not expected
src/Core/src/Eventuous.Shared/TypeMap/TypeMap.cs(51,25): warning IDE1006: Naming rule violation: Prefix '_' is not expected
src/Core/test/Eventuous.Tests.Shared.Analyzers/Analyzed.cs(4,1): error IDE0005: Using directive is unnecessary.
src/Postgres/test/Eventuous.Tests.Postgres/Subscriptions/GapSkipTimeoutTest.cs(5,1): error IDE0005: Using directive is unnecessary.
src/Postgres/test/Eventuous.Tests.Postgres/Subscriptions/GapAgeReleaseWhileRunningTest.cs(5,1): error IDE0005: Using directive is unnecessary.
src/Postgres/test/Eventuous.Tests.Postgres/Subscriptions/GapRemediationBeforeSkipTest.cs(5,1): error IDE0005: Using directive is unnecessary.
src/Sqlite/test/Eventuous.Tests.Sqlite/Metrics/MetricsFixture.cs(9,1): error IDE0005: Using directive is unnecessary.

Environment

  • OS: Linux
  • .NET SDK: 10.0.201
  • Solution: Eventuous.slnx
  • Affected projects target net10.0, net9.0, and net8.0; diagnostics repeat across target frameworks.

Additional context

The naming violations concern the static fields listener, _default, and _index, and the StreamReadPosition constructor parameter Value. The public Value property is separate from the constructor parameter.

Analyzed.cs is also loaded directly as source by the analyzer tests. Its System, System.Collections.Generic, and System.Threading.Tasks imports duplicate SDK implicit usings during a normal project build, but the standalone Roslyn compilation needs equivalent imports. Removing the redundant directives should preserve that test compilation context.

Lingua principale
C#
Stelle
512
Fork
99
Merge medio
5g 6h
PR unite (30g)
5

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Eventuous/eventuous

Tutte le issue di Eventuous/eventuous

Issue simili

Altre issue su C#

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.