Skip to content

Start the dev database with wasp start - #4914

Open
infomiho wants to merge 1 commit into
issue-4479-static-compilefrom
issue-4479-foreground-db
Open

infomiho wants to merge 1 commit into
issue-4479-static-compilefrom
issue-4479-foreground-db

Conversation

@infomiho

@infomiho infomiho commented Sep 28, 2026 •

Copy link
Copy Markdown
Member

Description

wasp start now starts the managed PostgreSQL dev database if the app needs one and it isn't running, and stops it on exit.

It skips starting one when the app uses SQLite, DATABASE_URL is set, or the database is already running. In that last case it waits for the database to accept connections and leaves it running on exit.

wasp start takes the same --db-port, --db-image and --db-volume-mount-path flags as wasp start db.

Part of #4479.

Agreement

  • This is a small, obvious fix (typo, docs corrections, clear small bug with a test).
  • A maintainer agreed on the approach beforehand:

Type of change

  • 🔧 Just code/docs improvement
  • 🐞 Bug fix
  • 🚀 New/improved feature
  • 💥 Breaking change

Checklist

  • I tested my change in a Wasp app to verify that it works as intended.

  • 🧪 Tests and apps:

    • I added unit tests for my change.
    • (if you fixed a bug) I added a regression test for the bug I fixed.
    • (if you added/updated a feature) I added/updated e2e tests in examples/kitchen-sink/e2e-tests.
    • (if you added/updated a feature) I updated the starter templates in waspc/data/Cli/templates, as needed.
    • (if you added/updated a feature) I updated the example apps in examples/, as needed.
      • (if you updated examples/tutorials) I updated the tutorial in the docs (and vice versa).
  • 📜 Documentation:

    • (if you added/updated a feature) I added/updated the documentation in web/docs/.
  • 🆕 Changelog: (if change is more than just code/docs improvement)

    • I updated waspc/ChangeLog.md with a user-friendly description of the change.
    • (if you did a breaking change) I added a step to the current migration guide in web/docs/migration-guides/.
    • I bumped the version in waspc/waspc.cabal to reflect the changes I introduced.

@pkg-pr-new

pkg-pr-new Bot commented Sep 28, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

@wasp/spec

npx https://pkg.pr.new/@wasp/spec@4914

@wasp/cli

npx https://pkg.pr.new/@wasp/cli@4914

@wasp/cli-darwin-arm64-unknown

npx https://pkg.pr.new/@wasp/cli-darwin-arm64-unknown@4914

@wasp/cli-linux-arm64-glibc

npx https://pkg.pr.new/@wasp/cli-linux-arm64-glibc@4914

@wasp/cli-linux-x64-glibc

npx https://pkg.pr.new/@wasp/cli-linux-x64-glibc@4914

@wasp/cli-linux-x64-musl

npx https://pkg.pr.new/@wasp/cli-linux-x64-musl@4914

commit: b7d1445

@infomiho
infomiho temporarily deployed to railway-deploy-test September 29, 2026 09:06 — with GitHub Actions Inactive
@infomiho
infomiho force-pushed the issue-4479-foreground-db branch from 08489d4 to fc8f764 Compare September 29, 2026 11:00
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Sep 29, 2026 •

Copy link
Copy Markdown

Deploying wasp-docs-on-main with  Cloudflare Pages  Cloudflare Pages

Latest commit: 5bdb821
Status: ✅  Deploy successful!
Preview URL: https://b5525535.wasp-docs-on-main.pages.dev
Branch Preview URL: https://issue-4479-foreground-db.wasp-docs-on-main.pages.dev

View logs

@infomiho
infomiho temporarily deployed to railway-deploy-test September 29, 2026 11:37 — with GitHub Actions Inactive
@infomiho
infomiho force-pushed the issue-4479-foreground-db branch from fc8f764 to 4b5b7ce Compare September 30, 2026 12:04
@infomiho
infomiho changed the base branch from main to cli-signal-lifecycle September 30, 2026 12:05
@infomiho
infomiho added this pull request to stack #4934 September 30, 2026 12:05
@infomiho
infomiho temporarily deployed to railway-deploy-test September 30, 2026 12:10 — with GitHub Actions Inactive
@infomiho
infomiho removed this pull request from stack #4934 September 30, 2026 13:55
@infomiho
infomiho force-pushed the issue-4479-foreground-db branch from 4b5b7ce to 499bda2 Compare September 30, 2026 13:57
@infomiho
infomiho changed the base branch from cli-signal-lifecycle to main September 30, 2026 13:57
@infomiho
infomiho temporarily deployed to railway-deploy-test September 30, 2026 14:39 — with GitHub Actions Inactive
@infomiho
infomiho force-pushed the issue-4479-foreground-db branch from 9115c43 to f649d3b Compare October 5, 2026 10:30
@infomiho
infomiho temporarily deployed to fly-deploy-test October 5, 2026 10:33 — with GitHub Actions Inactive
@infomiho
infomiho temporarily deployed to railway-deploy-test October 5, 2026 10:33 — with GitHub Actions Inactive
@infomiho
infomiho force-pushed the issue-4479-foreground-db branch from f649d3b to 90179ba Compare October 5, 2026 15:07
@infomiho
infomiho changed the base branch from main to issue-4479-job-newlines October 5, 2026 15:09
@infomiho
infomiho added this pull request to stack #4957 October 5, 2026 15:09
@infomiho
infomiho temporarily deployed to fly-deploy-test October 5, 2026 15:11 — with GitHub Actions Inactive
@infomiho
infomiho force-pushed the issue-4479-foreground-db branch from 90179ba to 5881a04 Compare October 5, 2026 15:17
@infomiho
infomiho had a problem deploying to railway-deploy-test October 5, 2026 15:23 — with GitHub Actions Failure
@infomiho
infomiho force-pushed the issue-4479-foreground-db branch 2 times, most recently from b681c8a to 7741f7c Compare October 19, 2026 11:48

@infomiho infomiho left a comment •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Startup changes stay here. The module moves are in #5064.

getDatabaseForSession (ReusedDatabase db) = db
getDatabaseForSession (StartedDatabase db _ _) = db

additionalInfoLines :: Dev.Postgres.DevDbSpec -> [String]

@infomiho infomiho Oct 19, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Moved unchanged out of startPostgresDevDb.

dbDockerImage = fromMaybe (fst defaultPostgresDockerImageSpec) options.dbImage
dbDockerVolumeMountPath = fromMaybe (snd defaultPostgresDockerImageSpec) options.dbVolumeMountPath

resolveDevDbPort :: Command PortNumber

@infomiho infomiho Oct 19, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Same port selection, now reads options.dbPort.

Docker.stopDatabase containerId `finally` (liftIO (cancel databaseJob) `finally` Docker.removeContainer containerId)
release _ = return ()

preparePostgresDevDb :: Path' Abs (Dir WaspProjectDir) -> String -> DbStartOptions -> DatabaseStartPolicy -> Command PreparedDatabase

@infomiho infomiho Oct 19, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Based on startPostgresDevDb. Now chooses whether to start or reuse the database.

throwIfExeIsNotAvailable
"docker"
"To run PostgreSQL dev database, Wasp needs `docker` installed and in PATH."
startPostgresDevDb :: Path' Abs (Dir WaspProjectDir) -> String -> DbStartOptions -> Command ()

@infomiho infomiho Oct 19, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Now waits for PostgreSQL to be ready, cleans up on exit, and reports container exits as errors.

import qualified Wasp.Message as Msg
import Wasp.Util.Docker (DockerImageName)

ensureDockerDaemonAvailable :: Command ()

@infomiho infomiho Oct 19, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Docker helpers moved here.

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.

From where? I can't find these functions anywhere else in the changelog.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Bad wording on my part, we moved throwIfExeIsNotAvailable for docker from start dev DB here, but also added some new Docker helpers.

@pullfrog pullfrog 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.

✅ No new issues found.

Reviewed changes Reviewed b3b9567, the behavioral change since the last incremental pass at 761f5fc, with the full PR diff as context.

  • Removed the application-database readiness dependency: Replaced the application DB query with pg_isready against postgres, preserving the published-port check and allowing Prisma to recreate a missing managed database.
  • Added recovery coverage: Added a Docker scenario that drops the application database before both migration and reset, then checks container ownership and cleanup behavior.

The earlier readiness finding is addressed and its thread is resolved. PostgreSQL's documented pg_isready contract supports the new check. The new regression scenario could not be executed here: ./run test:waspc:e2e failed before compilation with Error: [Cabal-7107], unknown package: with-utf8; Docker also reported Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@pullfrog pullfrog 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.

✅ No new issues found.

Reviewed changes Reviewed the readiness simplification in 3e7a627, following the naming-only change in d54bd41, with the full PR diff as context.

  • Simplified readiness polling: Removed the separate published-host-port probe and retried the in-container PostgreSQL TCP readiness check directly, preserving missing-application-database recovery.
  • Clarified readiness names: Renamed the private readiness helpers and local result to distinguish PostgreSQL availability from host-port reachability before removing the latter check.

Checked Docker startup ordering and the official PostgreSQL image's socket-only initialization server; no concrete startup regression was identified. Docker integration tests could not run: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running? Haskell tests were not rerun in this pass.

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@pullfrog pullfrog 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.

Important

Concurrent commands can now share an automatically started database without coordinating its lifetime, allowing one command to stop PostgreSQL while another still needs it.

Reviewed changes Reviewed the integration with the new compilation-locking model since the previous review at 3e7a627, using the complete PR diff for context.

  • Adapted DB command locking: Removed the session-wide project lock and used waitEnsureCompile to prepare generated code before running database actions.
  • Preserved watcher integration: Kept automatic database startup inside wasp start's watcher lock and retained the database URL in startup output.

Docker integration verification was blocked: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running? The concurrency finding is based on the command-admission and cleanup paths; Haskell tests were not rerun.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using gpt-6.1-sol | 𝕏

Comment thread waspc/cli/src/Wasp/Cli/Command/Db.hs Resolved

@sodic sodic 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.

I thought about the current system and have two main reservations. You'll know the two important comments when you see them :)

import qualified Wasp.Message as Msg
import Wasp.Util.Docker (DockerImageName)

ensureDockerDaemonAvailable :: Command ()

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.

From where? I can't find these functions anywhere else in the changelog.

Comment thread waspc/cli/exe/Main.hs
import Wasp.Cli.Command.BuildStart (buildStart)
import qualified Wasp.Cli.Command.Call as Command.Call
import Wasp.Cli.Command.Clean (clean)
import Wasp.Cli.Command.Compile (compileCommand)

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.

Some questions wrt the description. Ill ask them here so it's easier to reply

It doesn't auto-start the DB if it's already running or DATABASE_URL is specified

Does it say so?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Comment thread waspc/src/Wasp/Util/IO/Retry.hs Outdated
retry pauseStrategy maxNumRetries = retryWithCallback pauseStrategy maxNumRetries (\_ _ -> pure ())

-- | Repeats a check until it returns True or the retries are exhausted.
retryUntil :: (MonadRetry m) => PauseStrategy -> Natural -> m Bool -> m Bool

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.

Why does this return a boolean? I'd expect the return type to match retry, otherwise we are losing information, right?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

This is for the case where we don't care about the result or failure. We just want to wait until an action finishes and wonder if it succeeds. It's a specialization of retry above and I think it's fine if it gives you less information - you opt into that by using this 🤷‍♂️

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Compare:

ready <- Retry.retryUntil (Retry.constPause 1000000) 59 $ isPostgresAcceptingConnections devDbSpec
unless ready $ do
	(_, output, errors) <- readProcessWithExitCode "docker" ["logs", "--tail", "30", devDbSpec.dockerContainerName] ""
	ioError $ userError $ printf "PostgreSQL did not become ready. Check the logs below, then try again.\n%s%s" output errors

vs.

Retry.retry (Retry.constPause 1000000) 59 (checkPostgresAcceptsConnections devDbSpec) >>= \case
	Right () -> return ()
	Left _ -> do
		(_, output, errors) <- readProcessWithExitCode "docker" ["logs", "--tail", "30", devDbSpec.dockerContainerName] ""
		ioError $ userError $ printf "PostgreSQL did not become ready. Check the logs below, then try again.\n%s%s" output errors

I found that it improved readability for me.

Comment thread waspc/cli/src/Wasp/Cli/Command/Start.hs Outdated
start :: Arguments -> Command ()
start = withArguments startArgsParser $ \args ->
ProjectLock.acquireWatcher $ \projectLock -> do
ProjectLock.acquireWatcher $ \projectLock -> Start.Db.withDevDb args.dbStartOptions $ \managedDb -> do

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.

If the database is a "proper component" of an app, along the server and the client, why does it get special treatment with this decorator? We don't do withDevServer and withDevClient.

I'd expect the database to be started in the same way the client and server are started.

Comment thread waspc/cli/exe/Main.hs Outdated
Comment on lines +246 to +259
" --create-only",
" --db-port <port>",
" --db-image <image>",
" --db-volume-mount-path <path>"
],
cmd " studio GUI for inspecting your database.",
"",
title "DATABASE OPTIONS",
" --db-port <port> Host port when starting managed PostgreSQL.",
" --db-image <image> Docker image when starting managed PostgreSQL.",
" --db-volume-mount-path <path>",
" Data path inside a new PostgreSQL container.",
" These options also work with reset, seed, migrate-dev, and studio.",
"",

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.

We have some repetition here. Can we do something about that? RAW

Comment thread waspc/cli/exe/Main.hs Outdated
"migrate-dev" : optionalMigrateArgs -> runCommand $ withArguments Command.Db.Migrate.migrateArgsParser Command.Db.Migrate.migrateDev optionalMigrateArgs
"seed" : seedArgs -> runCommand $ withArguments Command.Db.Seed.seedArgsParser Command.Db.Seed.seed seedArgs
"studio" : studioArgs -> runCommand $ withArguments (ArgsParser "wasp db studio" (pure ())) (const Command.Db.Studio.studio) studioArgs
"reset" : resetArgs -> runCommandThatRequiresDbRunning Command.Db.Reset.resetArgsParser Command.Db.Reset.reset resetArgs

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.

If I got it right, we lose this thing later, right?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Nope, this is the final form. It's a useful helper that adding parser options that configure the dev database + it ensures the dev database is running.

Comment thread waspc/cli/src/Wasp/Cli/Command/Start.hs Outdated
Comment on lines +72 to +75
let databaseUrlLine = case managedDb of
Nothing -> ""
Just db -> printf " ℹ Database: %s\n" (Dev.Postgres.getDevConnectionUrl db)
cliSendMessageC $ Msg.Info $ showRunConfigUrls runConfigs <> databaseUrlLine

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.

Hm, something smells here. Similarly to the decorator, it's strange to see that the database has its own special handling.

I am guessing this is the explanation: #4914 (comment)

If so, I suggest we start with that refactor, not the other way around. So:

  1. First, we figure out how to make the database a first-class component of our apps (or as close as possible). Not an extra weird dragon next to the server and the client. Do do this, we'll have to untangle the current mess of abstractions and adapt existing commands to fit that.
  2. Then we add the new functionality to Wasp start. If database is an equal/first-class component. It should be easy and straightforward.

I think this is the way to go because it will clean up the relationship between different app components and will make most future things much easier (deployment, swapping parts, starting up parts independently, everything).

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

This is def the worst fitting code. It super special handling of database next to client and server. I agree!

Carlos started working on unifying client + server + db into the run configs here: #5130

I'll ask him if we can push that work first, so I can have a better case.

Comment on lines +75 to +83
data DbStartOptions = DbStartOptions
{ dbPort :: Maybe PortNumber,
dbImage :: DockerImageName,
dbVolumeMountPath :: DockerVolumeMountPath
dbImage :: Maybe DockerImageName,
dbVolumeMountPath :: Maybe DockerVolumeMountPath
}
deriving (Eq, Show)

dbStartOptionsParser :: Opt.Parser DbStartOptions
dbStartOptionsParser =

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.

Since this is now a general thing shared by two commands, and since wasp start is not implemented as "just run wasp db start on the side, I believe these deserve both a new name and a new location. I'm guessing that's what happens here: Startup changes stay here. The module moves are in #5064.

In case you haven't, please check if there's precedent on how we handle these things in the codebase (i.e., arguments that are shared between commands).

In the future, if possible, I'd do the move first and then add the stuff. I know it's not practical most of the time because of the way a system evolves, so no worries.

Now the more important question, could we share more of the functionality between the two commands? I'd expect it to be more modular, like this:

Current system

The current system only supports running the commands independently: first run wasp start db and then run wasp start.

Option 1 - Running the commands independently:

  1. User runs wasp start db.
  2. Wasp runs the startDatabaseProcedure.
  3. User runs wasp start.
  4. Wasp does the startClientAndServerProcedure.
  5. Internally, the startClientAndServerProcedure picks up the already running dev database.

New system

The new system supports both running the commands independently and running a bundled command.

Option 1 - Running the commands independently -> Same as before, no changes.

Option 2- Running the bundled command:

  1. User runs wasp start.
  2. Wasp runs the startDatabaseProcedure.
  3. Wasp does the startClientAndServerProcedure.
  4. Internally, the startClientAndServerProcedure picks up the already running dev database.

The only change I expected is that wasp starts gets the second step. The last two steps should work as they always have.

Comment thread waspc/cli/tests/DbMigrateTest.hs Outdated

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.

What's this? We haven't done anything with the migrations, right?

@infomiho infomiho Nov 2, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

All database commands now get their options + dev database options. But it's a silly test to add as it tests the parser library, I think my guard was down here for "is this really needed" question. Dropping it!

@pullfrog pullfrog 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.

✅ No new issues found.

Reviewed changes Reviewed the merge integration in a0993d9 since the last incremental pass at 5dc4db8, along with the comment-only change since the prior substantive Pullfrog review.

  • Reused the shared Docker daemon check: Database startup now calls checkDockerDaemonConnection, retaining the executable check and providing the upstream daemon-start guidance and Docker error details.
  • Preserved upstream CLI integration: Retained the legacyVersionsNote import required by the updated installation guidance.
  • Expanded test-helper documentation: Explained why database tests stop PostgreSQL directly and wait for Wasp cleanup.

Validation was static; tests were not rerun in this pass.

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@pullfrog pullfrog 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.

✅ No new issues found.

Reviewed changes Reviewed the merge integration in 7baa976 since the prior Pullfrog review at a0993d9.

  • Adapted database jobs: Migrated image pulling, attached PostgreSQL execution, and Studio to the upstream Job API, removing the custom Docker output reader while retaining lifecycle cleanup.
  • Restored interrupted-start recovery: Removed stale stopped containers before creation without force-removing running databases.
  • Integrated signal-cleanup coverage: Added an isolated SIGINT/SIGTERM scenario with a live database session and stale-container restart, and updated process matching for docker start --attach.

Validation: all 55 CLI tests and 686 compiler/unit tests passed. cabal build waspc-e2e-tests wasp-cli succeeded. Docker integration tests could not run because Docker reported Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@infomiho

infomiho commented Nov 4, 2026 •

Copy link
Copy Markdown
Member Author

@sodic I'm taking this over from Carlos: #5130

This drops the double analysis caveat I mentioned in the body (yay!) and moves the database into the runtime config (moving it closer to being a proper component).

I know you'd want the database not to be special but there are some reasons for it still needing a bit of different handling:

  • it needs to start before the server (client and server never really depended on each other)
  • it has to be stopped in a clean up after Wasp gets the signal to exit

This gives is a sort of different lifecycle than server + client.

On the other note, the system is built so that wasp db start and wasp start use the same systems i.e. the independent command just start the same thing as "bundled" wasp start command. I'll reply to the specific comments in more detail, but I'll do that after I finish the PR above :)

@pullfrog pullfrog 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.

✅ No new issues found.

Reviewed changes Reviewed the rewritten incremental delta on the new database-lifecycle base, including the narrowed automatic-start scope.

  • Reused shared database lifecycle handling: Wrapped wasp start compilation and runtime in managed PostgreSQL startup, while leaving custom databases, SQLite, and already-running containers alone.
  • Preserved compilation diagnostics: Added preliminary analysis for database selection and retained normal compilation to report analysis failures; the deliberate duplicate analysis remains documented for a later stack change.
  • Updated startup options and output: Composed the database options into wasp start, displayed managed connection URLs, and updated CLI help, connection guidance, and the changelog. Database commands no longer automatically start PostgreSQL in this version.
  • Added startup lifecycle coverage: Added a PostgreSQL app-start/SIGINT/container-removal scenario and assigned database ports separately for parallel start tests.

Local CLI test attempts returned [timed out after 120000ms] during tool installation and cold Haskell dependency builds; a background continuation was stopped before tests ran. Docker E2E execution was unavailable: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@pullfrog pullfrog 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.

✅ No new issues found.

Reviewed changes Reviewed the delta since b7d1445, focusing on startup ordering and integration with the new migration-check base.

  • Removed duplicate analysis: Used the normal compilation's AppSpec to select the managed database, eliminating the preliminary analysis and helper wrapper.
  • Moved database startup after compilation: Kept runtime-config construction, connectivity checks, and app execution inside the managed database session.
  • Integrated migration warnings: Checked migrations after database startup and retained those warnings for the initial quiet-down output.

Validation was static; Haskell tests were not rerun. Docker E2E verification was unavailable: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@github-actions

Copy link
Copy Markdown
Contributor

This pull request is now stale.
That means that it hasn't seen any activity for a while, and needs to be updated or addressed before it can be merged.

Next steps if the PR is still relevant, and you are able to devote time to it:

  • If you received any questions or feedback, please address them.
  • Merge the latest main into your branch to ensure that you are up to date.
  • If you are still working on the changes, please leave a comment telling us so.
  • Otherwise, just leave a comment explaining why the PR is still relevant.

If no action is taken, this PR will be automatically closed in 7 days.

@pullfrog pullfrog 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.

✅ No new issues found.

Reviewed changes Reviewed the rebase integration since cd420d1, focusing on database lifecycle and migration-check dependencies now supplied by the base branch.

  • Reused upstream database support: Retained automatic startup through the shared lifecycle and database-classification modules, with their Cabal registration and standalone readiness tests preserved upstream.
  • Preserved startup ordering and diagnostics: Kept compilation before database startup, migration checks after readiness, and migration warnings in the initial quiet-down output.

Validation was static; tests were not rerun.

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@pullfrog pullfrog 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.

✅ No new issues found.

Approach: Sound — starting the managed database between analysis and generation lets setup check migrations without analyzing the project twice.

Reviewed changes Reviewed the incremental changes since b7d1125, focusing on the split-compilation integration and migration diagnostics.

  • Split initial compilation: Used analyzeForCompilation before database startup and finishCompilation inside the managed session, preserving prerequisites and failure cleanup.
  • Reused setup migration checks: Removed the separate startup check and retained migration warnings through compilation results, quiet-down output, and watcher recompilation.

Validation was static; Haskell and Docker tests were not rerun.

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@pullfrog pullfrog 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.

✅ No new issues found.

Approach: Sound — the refreshed base separates database checks from static compilation, so PostgreSQL can start after compilation without duplicate analysis.

Reviewed changes Reviewed the incremental delta since a5e7879, focusing on startup ordering and database diagnostics.

  • Completed compilation before database startup: Replaced split analysis/generation with ordinary compilation, leaving compilation failures outside the managed database session.
  • Integrated post-start database checks: Checked connectivity and migrations after readiness, preserving database warnings in initial output and the quiet-down buffer.
  • Retained session cleanup: Kept runtime configuration, database checks, and app execution inside the owned-container lifetime.

Validation was static; Haskell and Docker tests were not rerun.

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@pullfrog pullfrog 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.

✅ No new issues found.

Reviewed changes Reviewed the incremental delta since 89aa2a8, focusing on integration with the refreshed database-check API.

  • Updated startup database checks: Kept connectivity validation after readiness and passed the resolved run-config database URL directly to the migration-warning helper.
  • Reused shared warning output: Preserved migration warnings in startup output and the quiet-down buffer while adopting printWarningsIfAny.

Validation was static; Haskell and Docker tests were not rerun.

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

This branch was previously deployed

2 inactive (outdated) deployments
railway-deploy-test — b7d14453 Deployed Nov 6, 2026 by infomiho via deploy-test / Test Railway deployment #14844
fly-deploy-test — b7d14453 Deployed Nov 6, 2026 by infomiho via deploy-test / Test Fly deployment #14844
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip-ci Disables GitHub Workflows on this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants