Skip to content

Commit df0e700

Browse files
authored
bugfix: Ensure both trace fields are set if tracing is used (#117)
Why === If `tracing` is set, we expect `traceparent` and `tracestate` to be non-null on the server side. If there is no tracestate, an empty string is sufficient. What changed ============ - Default `traceparent` and `tracestate` to empty strings Test plan ========= - Tracing should work without the TS server rejecting these messages
1 parent cafcc18 commit df0e700

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

replit_river/rpc.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,8 +88,8 @@ class ControlMessageHandshakeResponse(BaseModel):
8888

8989

9090
class PropagationContext(BaseModel):
91-
traceparent: Optional[str] = None
92-
tracestate: Optional[str] = None
91+
traceparent: str = Field(default="")
92+
tracestate: str = Field(default="")
9393

9494

9595
class TransportMessage(BaseModel):

0 commit comments

Comments
 (0)