Error Applet: Difference between revisions
No edit summary |
|||
| (One intermediate revision by the same user not shown) | |||
| Line 24: | Line 24: | ||
Depending on '''Type''', different error report fields will be attached and sent: | Depending on '''Type''', different error report fields will be attached and sent: | ||
* Type 0: | * Type 0: None; | ||
* Type 1: [[Error_Report_services# | * Type 1: [[Error_Report_services#FieldId|ServerFqdn]], [[Error_Report_services#FieldId|ServerIpAddress]], [7.0.0+] [[Error_Report_services#FieldId|ServerErrorCode]] and either [8.0.0+] [[Error_Report_services#FieldId|AkamaiReferenceId]], [13.0.0+] [[Error_Report_services#FieldId|LumenRequestId]] or [13.0.0+] [[Error_Report_services#FieldId|LlnwLlid]]; | ||
* Type 2: [[Error_Report_services# | * Type 2: [[Error_Report_services#FieldId|FileSystemPath]] and [[Error_Report_services#FieldId|ResultBacktrace]]; | ||
* Type 3: [[Error_Report_services# | * Type 3: [[Error_Report_services#FieldId|WebMediaPlayerOpenUrl]] and [[Error_Report_services#FieldId|WebMediaPlayerLastSocketErrors]]; | ||
* Type 4: [[Error_Report_services# | * Type 4: [5.0.0+] [[Error_Report_services#FieldId|LcsApplicationId]], [[Error_Report_services#FieldId|LcsContentMetaKeyIdList]], [[Error_Report_services#FieldId|LcsContentMetaKeyVersionList]], [[Error_Report_services#FieldId|LcsContentMetaKeyTypeList]], [[Error_Report_services#FieldId|LcsSenderFlag]], [[Error_Report_services#FieldId|LcsApplicationRequestFlag]], [[Error_Report_services#FieldId|LcsHasExFatDriverFlag]], [[Error_Report_services#FieldId|LcsIpAddress]] and [[Error_Report_services#FieldId|ResultBacktrace]]. | ||
* Type 5: [12.0.0+] [[Error_Report_services#FieldId|BrowserCertificateHostName]], [[Error_Report_services#FieldId|BrowserCertificateCommonName]] and [[Error_Report_services#FieldId|BrowserCertificateOrganizationalUnitName]]. | |||
= ErrorViewerStartupParamCommon = | = ErrorViewerStartupParamCommon = | ||
Latest revision as of 23:02, 2 March 2023
This is the applet presented when a title displays an error message. See Library Applets.
All errors displayed by this applet get logged and can be viewed under 'Settings' > 'Support' > 'Error History'.
On pre-5.0.0 the specified LanguageCode has to be valid, otherwise a fatal-error is thrown. With [5.0.0+] it will use en-US when the LanguageCode is invalid.
ErrorContext
This is "nn::err::ErrorContext". This is a 0x200-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x1 | Type |
| 0x1 | 0x7 | Padding |
| 0x8 | 0x1F4 | Data |
| 0x1FC | 0x4 | Result |
This is used to set specific error contexts for erpt:c.
Depending on Type, different error report fields will be attached and sent:
- Type 0: None;
- Type 1: ServerFqdn, ServerIpAddress, [7.0.0+] ServerErrorCode and either [8.0.0+] AkamaiReferenceId, [13.0.0+] LumenRequestId or [13.0.0+] LlnwLlid;
- Type 2: FileSystemPath and ResultBacktrace;
- Type 3: WebMediaPlayerOpenUrl and WebMediaPlayerLastSocketErrors;
- Type 4: [5.0.0+] LcsApplicationId, LcsContentMetaKeyIdList, LcsContentMetaKeyVersionList, LcsContentMetaKeyTypeList, LcsSenderFlag, LcsApplicationRequestFlag, LcsHasExFatDriverFlag, LcsIpAddress and ResultBacktrace.
- Type 5: [12.0.0+] BrowserCertificateHostName, BrowserCertificateCommonName and BrowserCertificateOrganizationalUnitName.
ErrorViewerStartupParamCommon
This is "nn::err::ErrorViewerStartupParamCommon". This is a 0x4-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x1 | ErrorType |
| 0x1 | 0x1 | IsJumpEnabled |
| 0x2 | 0x2 | Reserved |
ErrorViewerStartupParamForApplicationError
This is "nn::err::ErrorViewerStartupParamForApplicationError". This is a 0x1014-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | Common |
| 0x4 | 0x1 | Version |
| 0x5 | 0x3 | Reserved |
| 0x8 | 0x4 | ApplicationErrorCodeNumber |
| 0xC | 0x8 | LanguageCode |
| 0x14 | 0x800 | DialogMessage (UTF-8 string) |
| 0x814 | 0x800 | FullScreenMessage (UTF-8 string, displayed when the user clicks on "Details" and when not set this disables displaying "Details") |
[10.0.0+] GetMainAppletApplicationControlProperty is now used internally by the applet, on failure the applet will throw a fatalerr. Hence, ApplicationError can't be used from non-Applications (such as LibraryApplet) anymore.
ErrorViewerStartupParamForEula
This is "nn::err::ErrorViewerStartupParamForEula". This is a 0xC-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | Common |
| 0x4 | 0x1 | Version |
| 0x5 | 0x3 | Reserved |
| 0x8 | 0x4 | RegionCode |
- ErrorType = 3. Displays the EULA.
ErrorViewerStartupParamForParentalControl
This is "nn::err::ErrorViewerStartupParamForParentalControl". This is a 0xC-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | Common |
| 0x4 | 0x1 | Version |
| 0x5 | 0x3 | Reserved |
| 0x8 | 0x4 | PctlResultRestricted |
Used where a Result error would have been displayed with ErrorType=0, for module=PCTL errors with desc 100-119. For this the applet will display the following dialog (without report logging): "This software is restricted by Parental Controls".
ErrorViewerStartupParamForRecordedApplicationError
This is "nn::err::ErrorViewerStartupParamForRecordedApplicationError". This is a 0x820-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | Common |
| 0x4 | 0x1 | Version |
| 0x5 | 0x3 | Reserved |
| 0x8 | 0x4 | ApplicationErrorCodeNumber |
| 0xC | 0x4 | Reserved |
| 0x10 | 0x8 | TimeOfOccurrence (u64 PosixTime) |
| 0x18 | 0x8 | ApplicationErrorCodeCategory |
| 0x20 | 0x800 | Message (UTF-8 string) |
ErrorViewerStartupParamForRecordedSystemData
This is "nn::err::ErrorViewerStartupParamForRecordedSystemData". This is a 0x18-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | Common |
| 0x4 | 0x1 | Version |
| 0x5 | 0x3 | Reserved |
| 0x8 | 0x8 | ErrorCode |
| 0x10 | 0x8 | TimeOfOccurrence (u64 PosixTime) |
The applet does not log an error report for this. Used by qlaunch for viewing previously logged errors via the "View the Error" button.
ErrorViewerStartupParamForRecordedSystemError
This is "nn::err::ErrorViewerStartupParamForRecordedSystemError". This is a 0x818-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | Common |
| 0x4 | 0x1 | Version |
| 0x5 | 0x3 | Reserved |
| 0x8 | 0x8 | ErrorCode |
| 0x10 | 0x8 | TimeOfOccurrence (u64 PosixTime) |
| 0x18 | 0x800 | Message (UTF-8 string) |
ErrorViewerStartupParamForSystemData
This is "nn::err::ErrorViewerStartupParamForSystemData". This is a 0x14-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | Common |
| 0x4 | 0x1 | Version |
| 0x5 | 0x1 | HasResultBacktrace |
| 0x6 | 0x1 | IsErrorCode |
| 0x7 | 0x1 | [4.0.0+] HasErrorContext ([1.0.0-3.0.2] Reserved) |
| 0x8 | 0x8 | ErrorCode |
| 0x10 | 0x4 | Result |
ShowError: ErrorType=0, IsJumpEnabled={varies}, HasErrorContext={set when ErrorContext used}.
- If the input Result is 0xC8A2, the applet will display a special dialog regarding the current application requiring a software update, with buttons "Later" and "Restart". The official user-process name for this is
ShowUnacceptableApplicationVersionError. - [3.0.0+] There's also special dialog handling for Result 0xCAA2. The official user-process name for this is
ShowUnacceptableAddOnContentVersionError.
ErrorViewerStartupParamForSystemError
This is "nn::err::ErrorViewerStartupParamForSystemError". This is a 0x1018-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | Common |
| 0x4 | 0x1 | Version |
| 0x5 | 0x1 | [4.0.0+] HasErrorContext ([1.0.0-3.0.2] Reserved) |
| 0x6 | 0x2 | Reserved |
| 0x8 | 0x8 | ErrorCode |
| 0x10 | 0x8 | LanguageCode |
| 0x18 | 0x800 | DialogMessage (UTF-8 string) |
| 0x818 | 0x800 | FullScreenMessage (UTF-8 string, displayed when the user clicks on "Details" and when not set this disables displaying "Details") |
ErrorViewerStartupParamForSystemUpdateEula
This is "nn::err::ErrorViewerStartupParamForSystemUpdateEula". This is a 0xC-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | Common |
| 0x4 | 0x1 | Version |
| 0x5 | 0x3 | Reserved |
| 0x8 | 0x4 | RegionCode |
- ErrorType = 8. Displays the system-update EULA. Uses an additional IStorage containing EulaData, from Applet_Manager_services#CreateTransferMemoryStorage with flag=false.
ErrorViewerReturnValue
This is "nn::err::ErrorViewerReturnValue". This is a 0x2-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x1 | Version |
| 0x1 | 0x1 | Destination |
ApplicationErrorArg
This is "nn::err::ApplicationErrorArg". This is a 0x1014-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x1014 | StartupParam |
SystemErrorArg
This is "nn::err::SystemErrorArg". This is a 0x1028-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x1018 | StartupParam |
| 0x1018 | 0x9 | [4.0.0+] ServerCode |
| 0x1021 | 0x7 | [4.0.0+] Reserved |
ErrorType
This is "nn::err::ErrorType".
| Value | Description |
|---|---|
| 0 | SystemData |
| 1 | SystemError |
| 2 | ApplicationError |
| 3 | Eula |
| 4 | ParentalControl |
| 5 | RecordedSystemData |
| 6 | RecordedSystemError |
| 7 | RecordedApplicationError |
| 8 | SystemUpdateEula |
ErrorViewerJumpDestination
This is "nn::err::ErrorViewerJumpDestination".
| Value | Description |
|---|---|
| 0 | Nowhere |
| 1 | Set_SystemUpdate |
| 2 | Set_DataManagement |
| 3 | Set_InternetSetting |
| 4 | Cabinet_NfpDataSetting |
ErrorCode
This is "nn::err::ErrorCode". This is an u64.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | Category |
| 0x4 | 0x4 | Number |
ErrorCodeCategory
This is "nn::err::ErrorCodeCategory". This is an u32.
ErrorCodeNumber
This is "nn::err::ErrorCodeNumber". This is an u32.
ApplicationErrorCodeNumber
This is "nn::err::ApplicationErrorCodeNumber". This is an u32.
EulaData
This is "nn::err::EulaData". This is a 0x20000-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | DataCount |
| 0x4 | 0x3C | Reserved |
| 0x40 | 0x4 | Language |
| 0x44 | 0x4 | Reserved |
| 0x48 | 0x8 | Size |
| 0x50 | 0x1FFB0 | Body |
ResultBacktrace
This is "nn::err::ResultBacktrace". This is a 0x84-byte struct.
| Offset | Size | Description |
|---|---|---|
| 0x0 | 0x4 | Count |
| 0x4 | 0x4 * 32 | Array of Result |
Usage
User-processes should push a common arguments struct (version=0) as well as the Arg struct. Once the applet finishes running successfully, it may return an output storage in some cases. An u8 status value is located at +1, where non-zero indicates error.