Repository navigation
fix(site): say "not published" when site open has no published URL - #694
Merged
Merged
Conversation
Contributor
🚀 Package Preview Available!Install this PR's preview build with npm: npm i @base44-preview/cli@0.3.1-pr.694.631024ePrefer not to change any import paths? Install using npm alias so your code still imports npm i "base44@npm:@base44-preview/cli@0.3.1-pr.694.631024e"Or add it to your {
"dependencies": {
"base44": "npm:@base44-preview/cli@0.3.1-pr.694.631024e"
}
}
Preview published to npm registry — try new features instantly! |
netanelgilad
previously approved these changes
Nov 5, 2026
`site open` surfaced the published-URL lookup's 404 as "Error fetching site URL: App not found", which reads as a wrong app id. The endpoint answers only for live apps, so a 404 there means the app was never published. The command now fails with AppNotPublishedError ("This app has not been published yet, so it has no site URL") and a hint to publish; any other lookup error passes through unchanged.
Task: https://b44sync.base44.app/rd-hub/tasks/BASE-36419
File: https://github.com/base44-dev/suss-tasks/blob/f43f67162bbbe2f43c461f10b31b2bbf13d3bc17/cli/exec_unpublished_app_not_found%F0%9F%9A%AA/site_open_not_published_message.md
gate: tests/cli/site_open.spec.ts
agent: exec.unpublished
davidsu
force-pushed
the
fix/site-open-unpublished-message
branch
from
November 8, 2026 19:54
f6736c9 to
5bf436e
Compare
talge-a11y
approved these changes
Nov 9, 2026
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Note
Description
base44 site openon an app that was never published failed with "Error fetching site URL: App not found", which reads as if the app id were wrong. The published-URL endpoint only answers for live apps, so a 404 from it means "not published" — the command now says exactly that and hints at publishing. Any other lookup failure (e.g. a 500) still surfaces the server's own error unchanged.Related Issue
Follow-up to #693 (BUG-893). Task: BASE-36419
Type of Change
Changes Made
AppNotPublishedError(codeAPP_NOT_PUBLISHED, aUserError) inpackages/cli/src/core/errors.ts, with the message "This app has not been published yet, so it has no site URL" and a hint pointing atbase44 deploy.site openwrapsgetSiteUrl()ingetPublishedSiteUrl(), which maps anApiErrorwith status 404 toAppNotPublishedErrorand rethrows every other error untouched.docs/error-handling.md.Fixedentry toCHANGELOG.md.base44 deployhint, and the absence of "App not found"; a new 500 case asserts the server error still comes through and the "not published" wording does not.Testing
npm test)Checklist
docs/(AGENTS.md) if I made architectural changesAdditional Notes
The 404 → "not published" mapping lives in the
site opencommand rather than ingetSiteUrl(), so other callers of the URL lookup keep their current error behaviour. If more commands need the same treatment, the mapping is the natural thing to lift intocore/project/.🤖 Generated by Claude | 2026-11-04 18:55 UTC | b9f40b5