Skip to content

Commit

Permalink
fix: double config prompting during upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
regisb committed May 30, 2023
1 parent 03eaf1f commit 288f42b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tutor/commands/compose.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,8 @@ def launch(
run_for_prod = context_name != "dev"

utils.warn_macos_docker_memory()

# Upgrade has to run before configuration
interactive_upgrade(context, not non_interactive, run_for_prod)
interactive_configuration(context, not non_interactive, run_for_prod)

Expand Down Expand Up @@ -163,10 +165,11 @@ def interactive_upgrade(
)

# Update env and configuration
interactive_configuration(context, interactive, run_for_prod)
# Don't run in interactive mode, otherwise users gets prompted twice.
interactive_configuration(context, False, run_for_prod)

# Post upgrade
if run_upgrade_from_release and interactive:
if interactive:
question = f"""Your platform is being upgraded from {run_upgrade_from_release.capitalize()}.
If you run custom Docker images, you must rebuild them now by running the following command in a different shell:
Expand Down

0 comments on commit 288f42b

Please sign in to comment.