diff --git a/crates/horizon-port-pack/src/fetch.rs b/crates/horizon-port-pack/src/fetch.rs index f8f7b2dc7..f2803baa2 100644 --- a/crates/horizon-port-pack/src/fetch.rs +++ b/crates/horizon-port-pack/src/fetch.rs @@ -40,7 +40,7 @@ pub enum How { Downloaded, /// Copied from the player's folder. Local, - /// Only on CurseForge, whose downloads need an API key. + /// Only on CurseForge, whose downloads are coming soon (its API needs a paid key). NeedsKey, NotFound, Failed, @@ -52,7 +52,7 @@ impl How { How::Present => "already here", How::Downloaded => "downloaded", How::Local => "copied from your folder", - How::NeedsKey => "needs a CurseForge key", + How::NeedsKey => "CurseForge downloads coming soon", How::NotFound => "not found", How::Failed => "failed", } @@ -163,7 +163,7 @@ pub fn fetch( } write_json(&work.join("fetch.json"), &fetched)?; log(format!( - "jars: {} downloaded, {} copied, {} already here, {} need a CurseForge key, {} not found, {} failed", + "jars: {} downloaded, {} copied, {} already here, {} on CurseForge only (CurseForge downloads coming soon), {} not found, {} failed", fetched.count(How::Downloaded), fetched.count(How::Local), fetched.count(How::Present), diff --git a/docs/modpacks.md b/docs/modpacks.md index e233f176c..c15d0767e 100644 --- a/docs/modpacks.md +++ b/docs/modpacks.md @@ -326,8 +326,8 @@ Fabric API doesn't run (its id has a dash, which content mods can't use). A chec by SHA-1, or through a CurseForge app instance's `minecraftinstance.json`), else downloaded from the link the pack itself gives (a `.mrpack`'s, on the format's hosts only) or, for a CurseForge pack, the same file on Modrinth's public CDN, found by its SHA-1. A jar is kept only when its -hash matches. A file only CurseForge has is listed as needing a CurseForge API key (Ludovic's -decision; open question below), with the player's installed instance as the way round it. +hash matches. A file only CurseForge has is listed as "CurseForge downloads coming soon" (its API +needs a paid key; Ludovic, 2026-10-22), with the player's installed instance as the way round it. `/fetch.json` says what happened to each file. On All the Mods 10 8.3's CurseForge zip (2026-10-17): of the 54 data-tier content mods, 42 come from Modrinth's CDN (84 MB) and 12 need the key or the instance; `port` then carries the 42 over (0 ported, 42 partial: the harness is a @@ -1056,7 +1056,7 @@ What is missing, ranked by how much a player notices: 2026-10-22, Mac mini M4 Pro (offscreen, a debug launcher, release-profile `horizon-port-pack` and game), while other sessions kept the CPU at 85 to 93 %, so times are upper bounds. The two Modrinth packs were imported with `horizon-launcher mods install ` (the browser's Import), ATM10 from its CurseForge zip with `modpack import` -(CurseForge isn't searchable without a key), then each ported with `--resources` for 26.3 and opened as a survival +(CurseForge support is coming soon), then each ported with `--resources` for 26.3 and opened as a survival world with every ported mod on (horizon-ctl `launch --dev-mod ...`, from a scratch script). | Pack | Files | Import | Port | Ported mods | Coverage | Declared | World load (resources) | Crashes | @@ -1067,7 +1067,7 @@ world with every ported mod on (horizon-ctl `launch --dev-mod ...`, from a scrat The same world with no mods loads in 5.4 s (resources 1.1 s). Import is the pack download and Modrinth's answers by file hash; Vanilla Perfected's 30 s is mostly its 108 lookups and its download. Port is the jars (downloaded for the -two Modrinth packs; ATM10's 42 copied from a folder, 12 more are on CurseForge only and need its key) and the carry, +two Modrinth packs; ATM10's 42 copied from a folder, 12 more are on CurseForge only: CurseForge downloads coming soon) and the carry, which writes tens of thousands of small files. World load grows with the blocks the pack declares: ATM10 adds about 155,000 block states, and loading their models and textures is most of its 28.7 s. @@ -1081,5 +1081,5 @@ the mods that need porting (not counting performance mods and libraries), 2 of 8 - Contacting authors of permissively licensed mods to publish ports (none contacted). - Whether players should run code-port agents themselves (their own Claude Code or Codex login, as Zenith does) or only download published ports. -- A CurseForge API key for the launcher (CurseForge grants them to launchers on request). Until - then, CurseForge packs import from an installed instance. +- CurseForge: dropped for now (its API needs a paid key; Ludovic, 2026-10-22), shown as coming + soon. CurseForge packs import from their zip or an installed instance. diff --git a/launcher/src/modpacks.rs b/launcher/src/modpacks.rs index 67325e624..909c6cfae 100644 --- a/launcher/src/modpacks.rs +++ b/launcher/src/modpacks.rs @@ -45,7 +45,8 @@ pub struct Imported { pub fetched: Fetched, /// The carried-over mods the profile loads. pub mods: Vec, - /// Carried-over mods left off because an earlier one owns a namespace of theirs, with why. + /// Mods left off, with why: a ported one an earlier one owns a namespace of, or one whose + /// jar only CurseForge serves (CurseForge downloads coming soon). pub left_off: Vec, /// The mods the port step gets and carries over (content, data tier). pub portable: usize, @@ -107,7 +108,15 @@ pub fn load(work: &Path) -> Result { let rows: Vec = pipeline::read_json(&work.join("coverage.json")).unwrap_or_default(); let records: Vec = pipeline::read_json(&work.join("inventory.json")).unwrap_or_default(); - let (mods, left_off) = pipeline::loadable(&carried(work)); + let (mods, mut left_off) = pipeline::loadable(&carried(work)); + let fetched = Fetched::load(work); + left_off.extend( + fetched + .files + .iter() + .filter(|o| o.how == How::NeedsKey) + .map(|o| format!("{}: CurseForge downloads coming soon", o.key)), + ); Ok(Imported { slug: work .file_name() @@ -116,7 +125,7 @@ pub fn load(work: &Path) -> Result { work: work.to_path_buf(), pack, rows, - fetched: Fetched::load(work), + fetched, mods, left_off, portable: records.iter().filter(|r| pipeline::portable(r)).count(), @@ -216,7 +225,7 @@ pub fn outcome(pack: &Imported) -> String { pack.count(Status::NotNeeded), match pack.left_off.len() { 0 => String::new(), - n => format!("; {n} ported mods are left off, sharing a namespace with another"), + n => format!("; {n} are left off (listed under the pack)"), }, ) } @@ -267,6 +276,34 @@ mod tests { assert_eq!(slug(" "), "pack"); } + #[test] + fn jars_only_curseforge_serves_are_left_off_as_coming_soon() { + use horizon_port_pack::fetch::Outcome; + let work = std::env::temp_dir().join(format!("horizon-launcher-cf-{}", std::process::id())); + let _ = fs::remove_dir_all(&work); + fs::create_dir_all(&work).unwrap(); + pipeline::write_json(&work.join("pack.json"), &Pack::default()).unwrap(); + let fetched = Fetched { + files: vec![Outcome { + key: "allthemodium".into(), + file: "mods/allthemodium.jar".into(), + how: How::NeedsKey, + detail: String::new(), + }], + }; + pipeline::write_json(&work.join("fetch.json"), &fetched).unwrap(); + let pack = load(&work).unwrap(); + assert_eq!( + pack.left_off, + ["allthemodium: CurseForge downloads coming soon"] + ); + assert!(pack + .jars() + .unwrap() + .contains("CurseForge downloads coming soon")); + fs::remove_dir_all(&work).unwrap(); + } + #[test] fn a_profile_has_its_own_home_and_mods() { let root =