The error message in case of invalid package manifest in require-valid-changelog was incomplete. The user couldn't understand what is missing from the error message. This change will allow user to understand what is missing in package manifest which triggered invalid package manifest error.
Error message now.
Error: The package does not have a well-formed manifest. This is not the fault of the changelog, but this rule requires a valid package manifest.
at Object.execute (/Users/dck/Workspace/metamask/temp/module-lint/src/rules/require-valid-changelog.ts:40:15)
at async executeRule (/Users/dck/Workspace/metamask/temp/module-lint/src/execute-rules.ts:198:38)
at async executeRuleNodes (/Users/dck/Workspace/metamask/temp/module-lint/src/execute-rules.ts:168:7)
at async executeRule (/Users/dck/Workspace/metamask/temp/module-lint/src/execute-rules.ts:218:9)
at async executeRuleNodes (/Users/dck/Workspace/metamask/temp/module-lint/src/execute-rules.ts:168:7)
at async executeRules (/Users/dck/Workspace/metamask/temp/module-lint/src/execute-rules.ts:137:38)
at async lintProject (/Users/dck/Workspace/metamask/temp/module-lint/src/lint-project.ts:56:35)
at async /Users/dck/Workspace/metamask/temp/module-lint/src/main.ts:212:14
Error message with this change.
Error: Missing `exports`; Missing `module`.
The package does not have a well-formed manifest. This is not the fault of the changelog, but this rule requires a valid package manifest.
at Object.execute (/Users/dck/Workspace/metamask/temp/module-lint/src/rules/require-valid-changelog.ts:40:15)
at async executeRule (/Users/dck/Workspace/metamask/temp/module-lint/src/execute-rules.ts:198:38)
at async executeRuleNodes (/Users/dck/Workspace/metamask/temp/module-lint/src/execute-rules.ts:168:7)
at async executeRule (/Users/dck/Workspace/metamask/temp/module-lint/src/execute-rules.ts:218:9)
at async executeRuleNodes (/Users/dck/Workspace/metamask/temp/module-lint/src/execute-rules.ts:168:7)
at async executeRules (/Users/dck/Workspace/metamask/temp/module-lint/src/execute-rules.ts:137:38)
at async lintProject (/Users/dck/Workspace/metamask/temp/module-lint/src/lint-project.ts:56:35)
at async /Users/dck/Workspace/metamask/temp/module-lint/src/main.ts:212:14
The error message in case of invalid package manifest in require-valid-changelog was incomplete. The user couldn't understand what is missing from the error message. This change will allow user to understand what is missing in package manifest which triggered invalid package manifest error.
Error message now.
Error message with this change.