Skip to content

fix(document-ai): Downgrade p-queue package for CommonJS compatibility - #4348

Merged
angelcaamal merged 2 commits into
mainfrom
fix/docai-deps-p-queue
Jun 18, 2026
Merged

fix(document-ai): Downgrade p-queue package for CommonJS compatibility#4348
angelcaamal merged 2 commits into
mainfrom
fix/docai-deps-p-queue

Conversation

@angelcaamal

@angelcaamal angelcaamal commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

Description

This PR downgrades p-queue from ^8.0.0 to ^6.6.2. The version 8.0.0 is a pure ESM package, which is incompatible with our current CommonJS (require()) environment and caused ERR_REQUIRE_ESM errors during execution.

Changes

package.json

  • Downgraded p-queue from ^8.0.0 to ^6.6.2 to ensure compatibility with require().
    Fixes #

Note: Before submitting a pull request, please open an issue for discussion if you are not associated with Google.

Checklist

  • I have followed guidelines from CONTRIBUTING.MD and Samples Style Guide
  • Tests pass: npm test (see Testing)
  • Lint pass: npm run lint (see Style)
  • Required CI tests pass (see CI testing)
  • These samples need a new API enabled in testing projects to pass (let us know which ones)
  • These samples need a new/updated env vars in testing projects set to pass (let us know which ones)
  • This pull request is from a branch created directly off of GoogleCloudPlatform/nodejs-docs-samples. Not a fork.
  • This sample adds a new sample directory, and I updated the CODEOWNERS file with the codeowners for this sample
  • This sample adds a new sample directory, and I created GitHub Actions workflow for this sample
  • This sample adds a new Product API, and I updated the Blunderbuss issue/PR auto-assigner with the codeowners for this sample
  • Please merge this PR for me once it is approved

Note: Any check with (dev), (experimental), or (legacy) can be ignored and should not block your PR from merging (see CI testing).

@angelcaamal angelcaamal added samples Issues that are directly related to samples. api: documentai Issues related to the Document AI API. labels Jun 17, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request downgrades the p-queue dependency in document-ai/package.json from version ^8.0.0 to ^6.6.2. There are no review comments, and I have no feedback to provide.

@angelcaamal
angelcaamal marked this pull request as ready for review June 17, 2026 19:36
@angelcaamal
angelcaamal requested review from a team as code owners June 17, 2026 19:36

@Kef131 Kef131 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@angelcaamal
angelcaamal merged commit f711ad8 into main Jun 18, 2026
21 checks passed
@angelcaamal
angelcaamal deleted the fix/docai-deps-p-queue branch June 18, 2026 18:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: documentai Issues related to the Document AI API. samples Issues that are directly related to samples.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants