Skip to content

Commit ac25452

Browse files
committed
make up a SpanInFlight
1 parent e8c1a41 commit ac25452

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Diff for: ghcide/src/Development/IDE/Core/Tracing.hs

+2-2
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ import Ide.Types (PluginId (..))
4646
import Language.LSP.Types (NormalizedFilePath,
4747
fromNormalizedFilePath)
4848
import Numeric.Natural (Natural)
49-
import OpenTelemetry.Eventlog (Instrument, SpanInFlight,
49+
import OpenTelemetry.Eventlog (Instrument, SpanInFlight (..),
5050
Synchronicity (Asynchronous),
5151
addEvent, beginSpan, endSpan,
5252
mkValueObserver, observe,
@@ -69,7 +69,7 @@ otTracedHandler requestType label act
6969
-- Add an event so all requests can be quickly seen in the viewer without searching
7070
runInIO <- askRunInIO
7171
liftIO $ withSpan (fromString name) (\sp -> addEvent sp "" (fromString $ name <> " received") >> runInIO (act sp))
72-
| otherwise = act
72+
| otherwise = act (SpanInFlight 0)
7373

7474
otSetUri :: SpanInFlight -> Uri -> IO ()
7575
otSetUri sp (Uri t) = setTag sp "uri" (encodeUtf8 t)

0 commit comments

Comments
 (0)