Skip to content

Conversation

Moumouls
Copy link
Member

@Moumouls Moumouls commented Sep 13, 2025

Pull Request

Issue

Closes: Mongodb runner clean issue

Approach

Update the package

Tasks

  • Add tests
  • Add changes to documentation (guides, repository pages, code comments)

Summary by CodeRabbit

  • Documentation

    • Added guidance for resolving ESRCH “kill” errors during tests, including a command to clean the MongoDB runner cache.
  • Chores

    • Updated development dependency for the MongoDB runner to the latest minor version.
    • Introduced a new npm script to prune the MongoDB runner cache, aiding in local test stability.

Copy link

parse-github-assistant bot commented Sep 13, 2025

🚀 Thanks for opening this pull request!

Copy link

coderabbitai bot commented Sep 13, 2025

📝 Walkthrough

Walkthrough

Documentation updated to include a troubleshooting step for MongoDB runner ESRCH errors. package.json updates bump mongodb-runner devDependency from 5.8.3 to 5.9.3 and add a new npm script clean:mongodb to prune the runner cache. No runtime code or API changes.

Changes

Cohort / File(s) Summary of changes
Documentation
CONTRIBUTING.md
Added instruction to run npm run clean:mongodb to clean mongodb-runner cache when encountering ESRCH kill errors during security testing.
Tooling & Scripts
package.json
Updated devDependency mongodb-runner from 5.8.3 → 5.9.3. Added script clean:mongodb -> "cross-env mongodb-runner prune".

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Pre-merge checks

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Description Check ⚠️ Warning The description uses the repository template but is incomplete and vague: the "Issue" field does not contain a proper issue link or number, the "Approach" section only says "Update the package" without detailing the actual changes, and the Tasks list marks "Add tests" as done despite the raw summary showing no test changes, so it does not provide sufficient context for reviewers. Add a linked issue or issue number under "Issue", expand "Approach" to enumerate the concrete changes (for example, bump mongodb-runner devDependency from 5.8.3 to 5.9.3, add the "clean:mongodb" npm script "cross-env mongodb-runner prune", and the CONTRIBUTING.md doc update), and update the Tasks checkboxes to reflect what was actually implemented (uncheck "Add tests" if none were added) and include any required security checklist entries.
✅ Passed checks (2 passed)
Check name Status Explanation
Title Check ✅ Passed The title "fix: Update mongodb runner to fix ESRCH error" is concise, specific, and accurately reflects the primary change in the changeset—updating mongodb-runner to address an ESRCH failure (the raw summary also shows an added clean script and docs), so it clearly communicates the main intent to reviewers.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.

Tip

👮 Agentic pre-merge checks are now available in preview!

Pro plan users can now enable pre-merge checks in their settings to enforce checklists before merging PRs.

  • Built-in checks – Quickly apply ready-made checks to enforce title conventions, require pull request descriptions that follow templates, validate linked issues for compliance, and more.
  • Custom agentic checks – Define your own rules using CodeRabbit’s advanced agentic capabilities to enforce organization-specific policies and workflows. For example, you can instruct CodeRabbit’s agent to verify that API documentation is updated whenever API schema files are modified in a PR. Note: Upto 5 custom checks are currently allowed during the preview period. Pricing for this feature will be announced in a few weeks.

Please see the documentation for more information.

Example:

reviews:
  pre_merge_checks:
    custom_checks:
      - name: "Undocumented Breaking Changes"
        mode: "warning"
        instructions: |
          Pass/fail criteria: All breaking changes to public APIs, CLI flags, environment variables, configuration keys, database schemas, or HTTP/GraphQL endpoints must be documented in the "Breaking Change" section of the PR description and in CHANGELOG.md. Exclude purely internal or private changes (e.g., code not exported from package entry points or explicitly marked as internal).

Please share your feedback with us on this Discord post.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@parseplatformorg
Copy link
Contributor

🎉 Snyk checks have passed. No issues have been found so far.

security/snyk check is complete. No issues have been found. (View Details)

@Moumouls Moumouls changed the title chore: update mongodb runner to fix ESRCH error fix: update mongodb runner to fix ESRCH error Sep 13, 2025
Copy link

I will reformat the title to use the proper commit message syntax.

@parse-github-assistant parse-github-assistant bot changed the title fix: update mongodb runner to fix ESRCH error fix: Update mongodb runner to fix ESRCH error Sep 13, 2025
@Moumouls
Copy link
Member Author

@mtrezza for current active contributors, they need to run the "clean:mongodb" script to prune some old ref, then the upgrade of the package seems to fix the issue 🎉

@Moumouls Moumouls changed the title fix: Update mongodb runner to fix ESRCH error fix: Update mongodb runner to fix ESRCH error when running tests Sep 13, 2025
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (2)
CONTRIBUTING.md (1)

518-519: Good addition; consider surfacing this under Troubleshooting, too.

The note is helpful and scoped. To improve discoverability, mirror this line under the “Troubleshooting” section (Lines 217–231) with the same command.

package.json (1)

140-146: Nice: dedicated cleanup script. Optional: add a “clean:testenv” combo.

A convenience alias helps when CI/local runs leave stale state. Example:

   "posttest": "cross-env mongodb-runner stop --all",
   "clean:mongodb": "cross-env mongodb-runner prune",
+  "clean:testenv": "cross-env mongodb-runner stop --all && cross-env mongodb-runner prune",
   "coverage": "cross-env MONGODB_VERSION=${MONGODB_VERSION:=8.0.4} MONGODB_TOPOLOGY=${MONGODB_TOPOLOGY:=standalone} TESTING=1 nyc jasmine",
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 82fdb0d and df884ec.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (2)
  • CONTRIBUTING.md (1 hunks)
  • package.json (2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (12)
  • GitHub Check: Node 20
  • GitHub Check: MongoDB 8, ReplicaSet
  • GitHub Check: PostgreSQL 15, PostGIS 3.4
  • GitHub Check: Docker Build
  • GitHub Check: MongoDB 7, ReplicaSet
  • GitHub Check: PostgreSQL 15, PostGIS 3.3
  • GitHub Check: Node 18
  • GitHub Check: PostgreSQL 17, PostGIS 3.5
  • GitHub Check: MongoDB 6, ReplicaSet
  • GitHub Check: PostgreSQL 15, PostGIS 3.5
  • GitHub Check: Redis Cache
  • GitHub Check: PostgreSQL 16, PostGIS 3.5
🔇 Additional comments (1)
package.json (1)

106-106: Provide upstream changelog/commit proving ESRCH ('kill ESRCH') fix in mongodb-runner v5.9.3

No release note or changelog entry explicitly mentions an ESRCH / "kill ESRCH" cleanup fix in v5.9.3. Add a direct link to the upstream changelog/commit/PR in the PR description (or a short note here) showing the fix so reviewers can verify the rationale for the version bump.

Copy link

codecov bot commented Sep 13, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.57%. Comparing base (82fdb0d) to head (df884ec).

Additional details and impacted files
@@            Coverage Diff             @@
##            alpha    #9860      +/-   ##
==========================================
- Coverage   92.99%   92.57%   -0.43%     
==========================================
  Files         187      187              
  Lines       15096    15096              
  Branches      174      174              
==========================================
- Hits        14039    13975      -64     
- Misses       1045     1105      +60     
- Partials       12       16       +4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants