Error Codes
This document lists errors that YaoXiang package manager may return and their handling methods.
Error List
E0100: Project Already Exists
Error: Project already exists: <path>Cause: The project directory you are trying to create already exists.
Handling Methods:
- Choose a different project name
- Delete or move the existing directory
E0101: Not a Valid Project
Error: Not a YaoXiang project: yaoxiang.toml not foundCause: The current directory or specified directory does not contain a yaoxiang.toml file.
Handling Methods:
- Make sure you are executing commands within the project directory
- Use
yaoxiang initto create a new project
E0102: Dependency Not Found
Error: Dependency not found: <name>Cause: Attempting to operate on a dependency that does not exist.
Handling Methods:
- Check if the dependency name is spelled correctly
- Use
yaoxiang listto view existing dependencies
E0103: Dependency Already Exists
Error: Dependency already exists: <name>Cause: Attempting to add a dependency that already exists.
Handling Methods:
- If you need to update the version, first use
yaoxiang rmto remove it - Or simply use the existing dependency
E0104: Invalid Manifest Format
Error: Invalid yaoxiang.toml format: <details>Cause: The yaoxiang.toml file format is incorrect.
Handling Methods:
- Check if the TOML syntax is correct
- Ensure all required fields are present
- Check for syntax errors (such as missing quotes, commas, etc.)
E0105: IO Error
Error: IO error: <details>Cause: File read/write operation failed.
Common Causes:
- Insufficient disk space
- Insufficient permissions
- File is occupied by another program
Handling Methods:
- Check disk space
- Check file permissions
- Close other programs that may be occupying the file
E0106: TOML Parse Error
Error: TOML parse error: <details>Cause: TOML file format error.
Handling Methods:
- Validate TOML syntax
- Check if special characters are properly escaped
Frequently Asked Questions
Q: What should I do if dependency installation fails?
- Check network connection
- Confirm the dependency name and version are correct
- Try using
yaoxiang updateto refresh
Q: What should I do if I encounter version conflicts?
Check if there are incompatible dependency version requirements in yaoxiang.toml.
Q: What if the vendor directory is corrupted?
Delete the vendor directory and run yaoxiang install again.
