Select which package(s) are affected
livekit-server-sdk
Describe the bug
When polling listEgress() after a file egress completes, EgressInfo.fileResults (the non-deprecated replacement for result.file) is always an empty array even when status === EGRESS_COMPLETE. The only way to retrieve the output file location is via the deprecated result.file field (egress.result.value.location).
The @livekit/protocol types mark EgressInfo.result (cases file, stream, segments) as @deprecated in favour of fileResults, streamResults, and segmentResults respectively, but fileResults is never populated, making the migration impossible in practice.
Reproduction
const egresses = await egressClient.listEgress({ roomName });
const egress = egresses[0];
console.log(egress.status); // EgressStatus.EGRESS_COMPLETE
console.log(egress.fileResults); // [] — always empty
console.log(egress.result); // { case: 'file', value: { location: 's3://...', ... } }
Polling until EGRESS_COMPLETE and checking fileResults.length > 0 will never resolve. Using egress.result?.case === 'file' and reading egress.result.value.location works, despite being deprecated.
Logs
EgressInfo {
egressId: 'EG_zVMHov2jXiFC',
roomId: 'RM_igGNyycjLFf9',
roomName: 'room-e1574719-d2ef-4c73-a508-a7730ebb439f',
sourceType: 0,
status: 3,
startedAt: 1773081804987396000n,
endedAt: 1773081840286217000n,
updatedAt: 1773081840286217000n,
details: 'End reason: Source closed',
error: '',
errorCode: 0,
request: {
case: 'roomComposite',
value: RoomCompositeEgressRequest {
roomName: 'room-e1574719-d2ef-4c73-a508-a7730ebb439f',
layout: '',
audioOnly: true,
audioMixing: 0,
videoOnly: false,
customBaseUrl: '',
output: [Object],
options: [Object],
fileOutputs: [Array],
streamOutputs: [],
segmentOutputs: [],
imageOutputs: [],
webhooks: []
}
},
result: {
case: 'file',
value: FileInfo {
filename: 'path/file.ogg',
startedAt: 1773081806034656368n,
endedAt: 1773081839923884232n,
duration: 33889227864n,
size: 362298n,
location: '{s3link}/file.ogg'
}
},
streamResults: [],
fileResults: [],
segmentResults: [],
imageResults: [],
manifestLocation: '{s3bucketlink}/EG_zVMHov2jXiFC.json',
backupStorageUsed: false
}
System Info
System:
OS: macOS 26.3.1
CPU: (10) arm64 Apple M5
Memory: 64.94 MB / 16.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 22.21.1 - /Users/tanmaydeshmukh/.nvm/versions/node/v22.21.1/bin/node
npm: 10.9.4 - /Users/tanmaydeshmukh/.nvm/versions/node/v22.21.1/bin/npm
npmPackages:
@livekit/agents: 1.0.43 => 1.0.43
@livekit/agents-plugin-cartesia: 1.0.43 => 1.0.43
@livekit/agents-plugin-deepgram: 1.0.43 => 1.0.43
@livekit/agents-plugin-openai: 1.0.43 => 1.0.43
@livekit/agents-plugin-silero: 1.0.43 => 1.0.43
livekit-server-sdk: 2.15.0 => 2.15.0
LiveKit server version
LiveKit cloud
Severity
annoyance
Additional Information
No response
Select which package(s) are affected
livekit-server-sdk
Describe the bug
When polling
listEgress()after a file egress completes,EgressInfo.fileResults(the non-deprecated replacement forresult.file) is always an empty array even whenstatus === EGRESS_COMPLETE. The only way to retrieve the output file location is via the deprecatedresult.filefield (egress.result.value.location).The
@livekit/protocoltypes markEgressInfo.result(casesfile,stream,segments) as@deprecatedin favour offileResults,streamResults, andsegmentResultsrespectively, butfileResultsis never populated, making the migration impossible in practice.Reproduction
Polling until
EGRESS_COMPLETEand checkingfileResults.length > 0will never resolve. Usingegress.result?.case === 'file'and readingegress.result.value.locationworks, despite being deprecated.Logs
EgressInfo { egressId: 'EG_zVMHov2jXiFC', roomId: 'RM_igGNyycjLFf9', roomName: 'room-e1574719-d2ef-4c73-a508-a7730ebb439f', sourceType: 0, status: 3, startedAt: 1773081804987396000n, endedAt: 1773081840286217000n, updatedAt: 1773081840286217000n, details: 'End reason: Source closed', error: '', errorCode: 0, request: { case: 'roomComposite', value: RoomCompositeEgressRequest { roomName: 'room-e1574719-d2ef-4c73-a508-a7730ebb439f', layout: '', audioOnly: true, audioMixing: 0, videoOnly: false, customBaseUrl: '', output: [Object], options: [Object], fileOutputs: [Array], streamOutputs: [], segmentOutputs: [], imageOutputs: [], webhooks: [] } }, result: { case: 'file', value: FileInfo { filename: 'path/file.ogg', startedAt: 1773081806034656368n, endedAt: 1773081839923884232n, duration: 33889227864n, size: 362298n, location: '{s3link}/file.ogg' } }, streamResults: [], fileResults: [], segmentResults: [], imageResults: [], manifestLocation: '{s3bucketlink}/EG_zVMHov2jXiFC.json', backupStorageUsed: false }System Info
System: OS: macOS 26.3.1 CPU: (10) arm64 Apple M5 Memory: 64.94 MB / 16.00 GB Shell: 5.9 - /bin/zsh Binaries: Node: 22.21.1 - /Users/tanmaydeshmukh/.nvm/versions/node/v22.21.1/bin/node npm: 10.9.4 - /Users/tanmaydeshmukh/.nvm/versions/node/v22.21.1/bin/npm npmPackages: @livekit/agents: 1.0.43 => 1.0.43 @livekit/agents-plugin-cartesia: 1.0.43 => 1.0.43 @livekit/agents-plugin-deepgram: 1.0.43 => 1.0.43 @livekit/agents-plugin-openai: 1.0.43 => 1.0.43 @livekit/agents-plugin-silero: 1.0.43 => 1.0.43 livekit-server-sdk: 2.15.0 => 2.15.0LiveKit server version
LiveKit cloud
Severity
annoyance
Additional Information
No response