Error Message
Dep Statements Missing.
Symptom
The dependency declaration is missing.
Possible Causes
Dependencies used in the code are not declared in dependencies or dynamicDependencies in the oh-package.json5 file.
Solution
Ensure that the imported dependencies are declared in dependencies or dynamicDependencies in the oh-package.json5 file. For details, see ensure_dependency_include.
Error Message
Key Path Is Empty Or NotFound.
Symptom
The private key path is empty or not found.
Possible Causes
The private key path is not configured in the .ohpmrc file.
Solution
Configure a valid private key path in the .ohpmrc file.
Error Message
Private Key File Not Exist.
Symptom
The private key file does not exist.
Possible Causes
The private key file pointed to by the path configured in the .ohpmrc file does not exist, or the configured path is incorrect.
Solution
Check the private key path configuration in the .ohpmrc file and ensure that the path points to an existing private key file.
Error Message
Key Path Is DirError.
Symptom
The private key path is incorrect.
Possible Causes
In the .ohpmrc file, key_path is set to a folder path instead of a file path.
Solution
Ensure that the private key file path configured in .ohpmrc points to the target private key file.
Error Message
Publish Id Is Empty.
Symptom
The publish ID is not configured.
Possible Causes
The publish_id field is not configured in the .ohpmrc file.
Solution
Configure the publish_id field in the .ohpmrc file.
Error Message
Private Key Content Is Empty.
Symptom
The private key file is empty.
Possible Causes
The private key file is empty.
Solution
Regenerate the private key file.
Error Message
Not Support PrivateKey.
Symptom
The private key is not supported.
Possible Causes
The key_path field in the .ohpmrc file specifies the path of the private key file. However, the private key file does not exist in the path or is corrupted.
Solution
Ensure that the configured private key file path points to the correct private key file.
Error Message
Hsp File Is Empty.
Symptom
The HSP file is empty.
Possible Causes
The HSP file is empty.
Solution
Ensure that the HSP file contains valid content.
Error Message
Invalid Tgz File.
Symptom
The TGZ file is invalid.
Possible Causes
The TGZ file at the specified path does not contain an .hsp file.
Solution
Check the path to the TGZ file and ensure that the file at the path contains an .hsp file.
Error Message
Build Tgz Metadata Failed.
Symptom
Failed to build TGZ metadata.
Possible Causes
The field configuration is incorrect.
Solution
Check the oh-package.json5 file and ensure that all fields are configured correctly.
Error Message
Pkg Is Locked.
Symptom
The dependency package is locked.
Possible Causes
The package is locked after three failed upload attempts.
Solution
Try again later.
Error Message
Over Maximum Length Error.
Symptom
The length of a configured value exceeds the maximum limit.
Possible Causes
name, email, or url under the author field in the module-level oh-package.json5 file exceeds the maximum length limit.
Solution
Check the value lengths and ensure that they fall within the allowed ranges. The length of name must be within [1,128], email within [1,64], and url within [1,256].
Error Message
Parse Source File Error.
Symptom
Failed to parse the source file.
Possible Causes
The format of the .ohpmrc configuration file is incorrect.
Solution
Ensure that the content and format of the configuration file are correct.
Error Message
Check Compatibility Field Error.
Symptom
Failed to check the compatibility fields.
Possible Causes
The oh-package.json5 file does not contain the required compatibility fields.
Solution
Ensure that the oh-package.json5 file contains the required compatibility fields.