AcceptEncodingWireTests fail on Windows, 15 of 16, with a connection reset
I maintainer di solito rispondono entro 1 giorno
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 62/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- csharp
- Ambito
- testing-qa
Direzione di ricerca
I test che falliscono si trovano in AcceptEncodingWireTests (riga 162 di AcceptEncodingWireTests.cs) e nell'helper di test CapturingServer.DrainBodyAsync. Leggi DrainBodyAsync e verifica perché ritorna in anticipo quando non c'è Content-Length, lasciando non letti i corpi chunked. Esegui la classe di test filtrata su Windows per confermare che 15 test su 16 falliscono. Il lavoro è completato quando il caso chunked legge l'intero corpo e tutti i 16 test passano.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Describe the bug
Running the AcceptEncodingWireTests class on Windows fails 15 tests, yielding SocketException 10054; only the compression-off test passes. These tests need no ClickHouse server.
Steps to reproduce
On Windows, from the repository root:
dotnet test ClickHouse.Driver.Tests/ClickHouse.Driver.Tests.csproj --framework net10.0 -c Release --filter "FullyQualifiedName~AcceptEncodingWireTests"
Expected behaviour
All 16 tests pass
Root cause
- When compression is enabled the driver sends the body through CompressedContent without a known length. The request becomes chunked and has no Content-Length.
- CapturingServer.DrainBodyAsync returns early when there's no Content-Length, leaving the body unread.
- The server writes its response and closes the socket with unread data. Windows resets the connection and the client fails before reading a response
- The test that passes explicitly turns compression off, so there is a Content-Length
Transfer-Encoding: chunked | Content-Type: text/sql | Content-Encoding: gzip
Error log
System.Net.Http.HttpRequestException : An error occurred while sending the request.
----> System.IO.IOException : Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host.
----> System.Net.Sockets.SocketException : An existing connection was forcibly closed by the remote host.
SocketErrorCode: ConnectionReset
ErrorCode: 10054
at System.Net.Http.HttpConnection.InitialFillAsync(Boolean async)
at ClickHouse.Driver.Tests.Http.AcceptEncodingWireTests.WireAcceptEncodingAsync(...) AcceptEncodingWireTests.cs:line 162
Configuration
Environment
- Client version: main at commit 63dc6d3
- Language version: C#
- .NET version: runtime 10.0.15, SDK 10.0.404
- OS: Windows 11, build 10.0.26300, x64
Additional context
The tests were added in #490 and appear never to have passed on Windows. The test workflows run on Linux and macOS, which is why CI doesn't show it. I have a fix for the test helper and will open a pull request.
- Lingua principale
- C#
- Stelle
- 101
- Fork
- 28
- Merge medio
- 2g 11h
- PR unite (30g)
- 30
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di ClickHouse/clickhouse-cs
-
tests
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
ClickHouse/clickhouse-cs#754 ·
I maintainer di solito rispondono entro 1 giorno
-
bug data-types native-format
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
ClickHouse/clickhouse-cs#730 ·
I maintainer di solito rispondono entro 1 giorno
-
bug data-types
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
ClickHouse/clickhouse-cs#720 ·
I maintainer di solito rispondono entro 1 giorno
-
ClickHouseDataSource: DisposeAsync() (and await using) does not dispose the owned ClickHouseClient/HttpClientForse già presa Una pull request collegata a questa issue è aperta o già unita. Apertaapi-diagnostics bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
ClickHouse/clickhouse-cs#689 ·
I maintainer di solito rispondono entro 1 giorno
-
Every query fails with Code 164 (READONLY) for a readonly = 1 user: the driver always sends enable_http_compression and input_format_binary_read_json_as_string as settingsForse già presa @polyglotAI-bot l’ha presa 51 giorni fa. Apertabug configuration
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
ClickHouse/clickhouse-cs#659 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di ClickHouse/clickhouse-cs
Issue simili
-
bug effort:S P3
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
nightscout/nocturne#4563 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
-
good first issue
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
KnifeLemon/Filee#1887 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
launcher item missingAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
Realm667/WolfenDoom#1758 ·