Mongo shell no longer shows contents of defaultPrompt() at interactive shell prompt

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Minor - P4
    • 8.3.0-rc0
    • Affects Version/s: None
    • Component/s: Shell
    • None
    • DevProd Correctness
    • Fully Compatible
    • ALL
    • Correctness 2025-08-25
    • None
    • 3
    • Hour
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The __prompt__ variable must be globally set for execPrompt() to correctly read the value and display it. The changes from 17b2ea1 as part of SERVER-105603 made its usage within __promptWrapper__() become a module-scoped variable.

      This has no functional impact but it is convenient within an interactive mongo shell session to see the connection state, for example:

      MongoDB Enterprise rs:PRIMARY>
      

              Assignee:
              Steve McClure
              Reporter:
              Max Hirschhorn
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: