npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@pretendonetwork/error-codes

v1.0.2

Published

Translated error code information for the Wii U and 3DS

Downloads

187

Readme

Error Codes

Translated JSON files for known error codes used by the Wii U and 3DS

Path Structure

There are paths: modules and codes. The data folder contains the error code data. The root of the data folder contains the modules. Inside each module folder are the translation files for the module and folders for each of the module's error codes. Inside each module error code folder are the translation files for the error. Example path structure:

data
├── 102
│   ├── en_US.json
│   ├── 2482
│   │   └── en_US.json
│   ├── 2483
│   │   └── en_US.json
│   └── etc
└── 103
    ├── en_US.json
    ├── 0504
    │   └── en_US.json
    ├── 1101
    │   └── en_US.json
    └── etc

Translation Files

Each translation file is a JSON object named using standard locale names. The contents of each file contains strings intended for both use in our Discord bot Bandwidth and our websites support pages. Due to this each file may have many strings, some of which may seem redundant.

Each file starts with 1 or 2 objects, each with 1 key each. The first object key is the module ID. If the translation file is for a module, there is only this top level object. If the translation file is for an error the second object's key is the error code. This may seem redundant, and it is. This is done so that translation tools such as the in-development Locali by NeatoJS can index each string as module.string_name and module.error.string_name. Example object structures:

{
	"102": {
		"name": "act",
		"description": "Nintendo Network Accounts",
		"system": "Wii U"
	}
}
{
	"102": {
		"2802": {
			"name": "BANNED_ACCOUNT_ALL",
			"message": "This Nintendo Network ID\ncannot be used.\n\nPlease make a note of the error code\nand visit support.nintendo.com.",
			"short_description": "Your account is permanently banned from all aspects of the network.",
			"long_description": "The account you are trying to use has been permanently banned from all aspects of the network. This includes, but is not limited to:\n\n- Miiverse\n- Game servers\n- 3rd party services which opt-in to respecting network bans",
			"short_solution": "Not applicable.",
			"long_solution": "Not applicable.",
			"support_link": "https://preten.do/102-2802"
		}
	}
}

Module translation file fields

| Name | Description | | ------------- | ------------------------------------------------- | | name | The name of the sysmodule | | description | A short description of what the sysmodule handles | | system | The system the sysmodule is for |

Error translation file fields

| Name | Description | | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------ | | name | The internal name of the error. Not all errors have an internal name. If missing, Unknown | | message | The message exactly as it appears on the console. If there is no relevant translation for the message, use the en_US version | | short_description | A short description of the error. Intended to be used by the Discord bot. Plain text | | long_description | A longer, more detailed, description of the error. Intended to be used by the website. Markdown | | short_solution | A short solution for the error. Intended to be used by the Discord bot. Plain text | | long_solution | A longer, more detailed, solution for the error. Intended to be used by the website. Markdown | | support_link | Link to a relevant support page for the error. Typically the website, but does not have to be |

Utility functions

The main purpose of this repository is to maintain the JSON translation files. However 2 utility functions are also included for JavaScript/TypeScript projects.

  • getModuleInfo(sysmodule, locale) - Returns the module information for the locale, or null if not found
  • getErrorInfo(sysmodule, code, locale) - Returns the error information (including the module information) for the locale. Returns null if either the module or error code is not found
  • getAllErrors() - Returns an array of all error codes for all modules in the form MODULE-CODE