Skip to content

Feat: add default-variable fallback when override-resolved artifact URL fails#7

Merged
CodeWithKyrian merged 1 commit into
mainfrom
fix/default-vars-fallback-on-override-miss
Mar 31, 2026
Merged

Feat: add default-variable fallback when override-resolved artifact URL fails#7
CodeWithKyrian merged 1 commit into
mainfrom
fix/default-vars-fallback-on-override-miss

Conversation

@CodeWithKyrian

Copy link
Copy Markdown
Owner

This PR updates artifact URL resolution to retry with package default variables when the override-resolved URL is invalid, unresolved, or unavailable. If the default-based URL resolves successfully, Composer installs from that URL; if it also fails, behavior falls back to the existing Composer dist/source path.

Motivation and Context

Consumers can provide override variables that resolve to a non-existent artifact variant even when the package default variant exists and is valid for the same platform. Previously, that scenario could drop directly to base Composer fallback behavior. This change improves resilience by attempting a sensible in-plugin fallback first (defaults + {version}), so users are more likely to get a usable platform artifact without manual intervention.

What's Changed

  • Updated installer URL resolution flow to attempt primary candidate using defaults + app overrides + {version}.
  • Added retry candidate using defaults only + {version} when an override-based resolution fails.
  • Kept final fallback behavior unchanged when both candidates fail.
  • Added explicit logging for override failure and default-variable fallback usage.
  • Updated README placeholder behavior section to document the new retry flow.

Breaking Changes

None.

@CodeWithKyrian CodeWithKyrian changed the title fix: fallback to default artifact vars when override URL is unavailable Feat: add default-variable fallback when override-resolved artifact URL fails Mar 31, 2026
@CodeWithKyrian CodeWithKyrian merged commit 4590dec into main Mar 31, 2026
8 checks passed
@CodeWithKyrian CodeWithKyrian deleted the fix/default-vars-fallback-on-override-miss branch March 31, 2026 21:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant