aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe/src/package/version
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-06-06 15:16:07 +0900
committernsfisis <nsfisis@gmail.com>2026-06-06 15:17:00 +0900
commit1e7aabcae1b2139aa20a80fbf303c74388933f55 (patch)
tree07c5f4e7502841fef21909b2aa8269e6e71fb2a3 /crates/shirabe/src/package/version
parentadba8b1969a3f40245324d7feb5905693ca65d5e (diff)
downloadphp-shirabe-1e7aabcae1b2139aa20a80fbf303c74388933f55.tar.gz
php-shirabe-1e7aabcae1b2139aa20a80fbf303c74388933f55.tar.zst
php-shirabe-1e7aabcae1b2139aa20a80fbf303c74388933f55.zip
fix(array-dumper): emit package links and require Link pretty constraint
Resolve the phase-b TODO that left the supported-link-types loop as dead code (links were always an empty Vec), so requires/conflicts/provides/ replaces/require-dev are dumped again via PackageInterface::get_links_for_type, matching the PHP magic-call loop. Every Link in production is constructed with a pretty constraint (all ArrayLoader/AliasPackage/PlatformRepository/InstalledRepository sites pass one), so make Link::pretty_constraint a required String instead of Option<String>. get_pretty_constraint() now returns &str directly rather than anyhow::Result<&str>, dropping the unreachable UnexpectedValueException guard, and all call sites are updated. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Diffstat (limited to 'crates/shirabe/src/package/version')
-rw-r--r--crates/shirabe/src/package/version/version_selector.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/shirabe/src/package/version/version_selector.rs b/crates/shirabe/src/package/version/version_selector.rs
index 9e41f97..ecf08b5 100644
--- a/crates/shirabe/src/package/version/version_selector.rs
+++ b/crates/shirabe/src/package/version/version_selector.rs
@@ -200,7 +200,7 @@ impl VersionSelector {
pkg.get_pretty_version(),
link.get_description(),
link.get_target(),
- link.get_pretty_constraint().unwrap_or_default(),
+ link.get_pretty_constraint(),
reason
),
true,