This repository was archived by the owner on Mar 24, 2026. It is now read-only.
Repository navigation
use db.getSiblingDB in mongo create.js - #6731
Merged
Merged
Conversation
…lways work correctly (does not work on windows 10)
Contributor
Author
|
I don't think this will ever pass CI, but several mongo implementations succeeded with no issue. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When running mongodb.dockerfile locally on windows, I noticed that it was creating a database named test instead of hello_world which caused all of the validations to fail when run.
I changed the create.js script to use db.getSiblingDb("hello_world") instead of use hello_world and that resolved the issue. This should work identically in all cases where it was already working.
https://docs.mongodb.com/manual/reference/method/db.getSiblingDB/