fix(apps): open app URL without config#4989
Merged
Merged
Conversation
465e5dc to
2c515f8
Compare
2c515f8 to
57a0ed3
Compare
dangra
approved these changes
Jul 9, 2026
There was a problem hiding this comment.
Pull request overview
Enables fly apps open -a <app> to still open the app in a browser when no local/remote app config can be loaded, by falling back to the default https://<app>.fly.dev/ URL (with a warning), while preserving config-derived URL behavior when config is available.
Changes:
- Add fallback behavior and warning output when remote app config can’t be loaded, and ignore mismatched local config when
-aselects a different app. - Refactor URL-opening logic into a shared helper to consistently apply relative-URI handling.
- Add focused unit tests covering fallback, warning output, relative URI parsing, local/remote config paths, and no-public-service behavior.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| internal/command/apps/open.go | Adds config-load fallback to default app hostname, ignores mismatched local config, and centralizes URL opening/relative-URI handling. |
| internal/command/apps/open_test.go | Adds targeted tests validating fallback behavior, warning output, relative URI handling, and local vs remote config selection. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
What
Allow
fly apps open -a <app>to open the defaulthttps://<app>.fly.dev/URL when flyctl cannot load app config.Why
Supplying
-acurrently still fails if no local/remote app config can be loaded, which makes the app flag feel ignored for a command whose main job is to open the app URL.How
Tests
Fixes #4215