Skip to main content

ErrorCode

Electron APIs / recorder / ErrorCode

type ErrorCode =
| -1001
| -1000
| -999
| -998
| -997
| -996
| -12
| -11
| -10
| -8
| -7
| -4
| -1
| 0
| 1
| 2;

Enumeration of possible error codes returned by the recording system. Each error code represents a specific condition or failure during initialization, execution, or finalization of a recording session.

These codes help in identifying and handling recording-related issues.

CodeNameDescription
-1001UnknownGeneric unknown error.
-1000ProcessTerminatedOBS process crashed.
-999MissingBinariesMissing binaries required for recording.
-998ConnectionOBSErrorFailed to connect to the OBS process.
-997AlreadyRunningOperation attempted while recording is already running.
-996ElevationHelperMissingElevated game capture requested while the High Elevation Helper isn't installed.
-12SplitRecordingDisabledAttempted to split recording when split recording is disabled.
-11MissingOrInvalidParametersOne or more required parameters are missing or invalid.
-10NoActiveRecordingNo active recording session found.
-8EncoderErrorEncoder encountered an error.
-7NoDiskSpaceErrorNot enough disk space to complete the recording.
-4ProcessOutputErrorFailed to process or finalize the output video file.
-1BadPathErrorInvalid or inaccessible output file path.
0SuccessOperation succeeded.
1SuccessLowDiskSpaceOperation succeeded but stopped early due to low disk space.
2SuccessWithErrorReplay stopped while creating replay.

Example

function handleError(code: ErrorCode) {
if (code === -1000) {
console.error("OBS process crashed");
}
}