Skip to content

TypeError: Cannot read properties of null (reading 'author') #795

Description

@lockHrt

Affected Packages

pkg:@changesets/changelog-github

Problem

pnpx changeset version command is giving following error:

The following error was encountered while generating changelog entries
We have escaped applying the changesets, and no files should have been affected
🦋  error TypeError: Cannot read properties of null (reading 'author')
🦋  error     at Object.getInfo (project-name\node_modules\.pnpm\@changesets+get-github-info@0.5.0\node_modules\@changesets\get-github-info\dist\get-github-info.cjs.dev.js:228:12)
🦋  error     at processTicksAndRejections (node:internal/process/task_queues:96:5)
🦋  error     at async project-name\node_modules\.pnpm\@changesets+changelog-github@0.4.4\node_modules\@changesets\changelog-github\dist\changelog-github.cjs.dev.js:122:13
🦋  error     at async Object.getReleaseLine (project-name\node_modules\.pnpm\@changesets+changelog-github@0.4.4\node_modules\@changesets\changelog-github\dist\changelog-github.cjs.dev.js:99:19)
🦋  error     at async Promise.all (index 0)
🦋  error     at async generateChangesForVersionTypeMarkdown (project-name\node_modules\.pnpm\@changesets+apply-release-plan@6.0.0\node_modules\@changesets\apply-release-plan\dist\apply-release-plan.cjs.dev.js:188:22)
🦋  error     at async getChangelogEntry (project-name\node_modules\.pnpm\@changesets+apply-release-plan@6.0.0\node_modules\@changesets\apply-release-plan\dist\apply-release-plan.cjs.dev.js:243:109)
🦋  error     at async project-name\node_modules\.pnpm\@changesets+apply-release-plan@6.0.0\node_modules\@changesets\apply-release-plan\dist\apply-release-plan.cjs.dev.js:392:21
🦋  error     at async Promise.all (index 0)
🦋  error     at async Object.applyReleasePlan [as default] (project-name\node_modules\.pnpm\@changesets+apply-release-plan@6.0.0\node_modules\@changesets\apply-release-plan\dist\apply-release-plan.cjs.dev.js:287:31)
 ELIFECYCLE  Command failed with exit code 1.
  • The author field is present in all package.json files.
  • GITHUB_TOKEN is also set as env variable with Github PAT with both read:user and repo:status permissions.
  • config file:
{
 "$schema": "https://unpkg.com/@changesets/config@2.0.0/schema.json",
 "changelog": ["@changesets/changelog-github", { "repo": "another-dev/project-name" }],
 "commit": false,
 "fixed": [],
 "linked": [],
 "access": "restricted",
 "baseBranch": "main",
 "updateInternalDependencies": "patch",
 "ignore": []
}
  • tested v0.4.4 and v0.4.3 both giving same error.
  • System is windows 10 and node v16.14.2
  • pnpx changeset is working fine

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions