diff --git a/app/src/domain/pages.rs b/app/src/domain/pages.rs index 6994f38d..600527c2 100644 --- a/app/src/domain/pages.rs +++ b/app/src/domain/pages.rs @@ -29,6 +29,23 @@ pub struct Page { pub diff_id: Option, } +/// How many pages each side has, `(base, head)`, from the pages' indexes. A comparison's rows are aligned positions: a +/// reflowed document with pages inserted and removed has more rows than either side has pages (34 base pages and 32 +/// head pages aligned over 35 rows), so a page count is never the row count (sc-9184). +pub fn side_counts(indexes: impl IntoIterator, Option)>) -> (usize, usize) { + let (mut base, mut head) = (std::collections::BTreeSet::new(), std::collections::BTreeSet::new()); + for (b, h) in indexes { + base.extend(b); + head.extend(h); + } + (base.len(), head.len()) +} + +/// The page count to show for a snapshot: its head's, or its base's when it has no head (a removed snapshot). +pub const fn shown_count((base, head): (usize, usize)) -> usize { + if head == 0 { base } else { head } +} + struct Row { snapshot_id: i64, position: i32, diff --git a/app/src/domain/summary.rs b/app/src/domain/summary.rs index 18e1c2a0..64c09393 100644 --- a/app/src/domain/summary.rs +++ b/app/src/domain/summary.rs @@ -103,6 +103,19 @@ async fn describe(s: &Snapshot) -> laravel::Result { } } let mut out = Vec::new(); + // A document whose page count changed leads with both counts: its rows are aligned positions, so "1 page added, + // 3 pages removed" for 34 pages becoming 32 reads as a strange change (sc-9184). Pages added and removed are then + // that alignment's detail, left to the snapshot's page. + let (base_count, head_count) = super::pages::side_counts(pages.iter().map(|p| (p.base_index, p.head_index))); + let recounted = s.kind != "image" && base_count > 0 && head_count > 0 && base_count != head_count; + if recounted { + let (more, word) = if head_count > base_count { + (head_count - base_count, "more") + } else { + (base_count - head_count, "fewer") + }; + out.push(format!("{base_count} → {head_count} pages ({more} {word})")); + } if !changed_pages.is_empty() { let which = if s.kind == "image" { "changed".to_string() @@ -116,10 +129,10 @@ async fn describe(s: &Snapshot) -> laravel::Result { which }); } - if inserted > 0 { + if inserted > 0 && !recounted { out.push(format!("{inserted} {} added", plural(inserted, "page", "pages"))); } - if deleted > 0 { + if deleted > 0 && !recounted { out.push(format!("{deleted} {} removed", plural(deleted, "page", "pages"))); } Ok(if out.is_empty() { "changed".to_string() } else { out.join(", ") }) diff --git a/app/src/http/ui/builds.rs b/app/src/http/ui/builds.rs index 7439f7f9..ec262b7c 100644 --- a/app/src/http/ui/builds.rs +++ b/app/src/http/ui/builds.rs @@ -155,6 +155,7 @@ pub async fn show_build(auth: Auth, Params((org, project, number)): Params for s in &list { let pages = pages_of.get(&s.id).map(Vec::as_slice).unwrap_or_default(); let changed = pages.iter().filter(|p| p.state == "changed").count(); + let counts = crate::domain::pages::side_counts(pages.iter().map(|p| (p.base_index, p.head_index))); let thumb = thumb_of(s).filter(|sha| stored.contains(sha)).and_then(|sha| store.download_url(&sha).ok()); // Text snapshots: lines added and removed by the change, for the build's list. @@ -174,7 +175,10 @@ pub async fn show_build(auth: Auth, Params((org, project, number)): Params "state": s.state, "review": s.review, "error": s.error, - "pages": pages.len(), + // The head's page count (the base's for a removed snapshot), and the base's: a comparison's rows + // are aligned positions, more than either side's pages when pages were added and removed. + "pages": crate::domain::pages::shown_count(counts), + "base_pages": counts.0, "changed_pages": changed, "change": sizes.get(&s.id), "approved_elsewhere": elsewhere.remove(&s.id), diff --git a/app/src/mcp/mod.rs b/app/src/mcp/mod.rs index adf0cd6c..ae8ddfaa 100644 --- a/app/src/mcp/mod.rs +++ b/app/src/mcp/mod.rs @@ -1218,7 +1218,10 @@ impl VisualCi { v["url"] = json!(snapshot_url(e)); v }), - "pages": pages.map(Vec::len), + // The head's page count (the base's for a removed snapshot), and the base's: the comparison's + // positions outnumber both when a reflow added and removed pages (sc-9184). + "pages": pages.map(|p| crate::domain::pages::shown_count(page_counts(p))), + "base_pages": pages.map(|p| page_counts(p).0), "changed_pages": pages.map(|p| p.iter().filter(|p| p.state == "changed").count()), "moved_lines": review_detail.as_ref().map_or(0, |d| d.moved.len()), }); @@ -1457,6 +1460,7 @@ impl VisualCi { return Ok(CallToolResult::success(content)); } let (pages, moved) = (review_detail.pages, review_detail.moved); + let (base_pages, head_pages) = page_counts(&pages); // Changed pages first; with none (an unchanged snapshot), the first pages, so any snapshot can be looked at. let wanted: Vec = match &args.pages { @@ -1511,6 +1515,10 @@ impl VisualCi { "url": url, "compared_with": compared_with, "open_comment_threads": open_threads, + // Each side's page count: `pages` lists aligned positions, more than either side has when a reflow added + // and removed pages (sc-9184). + "base_pages": base_pages, + "head_pages": head_pages, "pages": summary, "moved_lines": moved.iter().map(|m| json!({ "text": m.text, "from_page": m.from_page + 1, "to_page": m.to_page + 1 })).collect::>(), }); @@ -2362,6 +2370,11 @@ pub async fn handle(principal: Result, request: axum: } /// The bearer token of a request, if it sent one. +/// Each side's page count, `(base, head)` ([`crate::domain::pages::side_counts`]). +fn page_counts(pages: &[crate::domain::detail::PageDetail]) -> (usize, usize) { + crate::domain::pages::side_counts(pages.iter().map(|p| (p.base_index, p.head_index))) +} + fn bearer(request: &axum::extract::Request) -> Option<&str> { oauth_provider::bearer(request.headers().get(axum::http::header::AUTHORIZATION).and_then(|v| v.to_str().ok())) } diff --git a/app/tests/all.rs b/app/tests/all.rs index 254fc442..cf6cf88e 100644 --- a/app/tests/all.rs +++ b/app/tests/all.rs @@ -68,6 +68,7 @@ mod staff; mod staff_commands; mod storage; mod storage_blobs; +mod summaries; mod sweep; mod tokens; mod ui; diff --git a/app/tests/golden/mcp/agents_comment_on_snapshots_and_resolve_threads/get_build.json b/app/tests/golden/mcp/agents_comment_on_snapshots_and_resolve_threads/get_build.json index 08df92b3..341de4a0 100644 --- a/app/tests/golden/mcp/agents_comment_on_snapshots_and_resolve_threads/get_build.json +++ b/app/tests/golden/mcp/agents_comment_on_snapshots_and_resolve_threads/get_build.json @@ -6,7 +6,7 @@ "result": { "content": [ { - "text": "{\"blocked\":null,\"branch\":\"feat\",\"ci_mode\":\"review\",\"commit\":\"abc\",\"conclusion\":null,\"config\":null,\"created_at\":\"\",\"environment\":\"ci\",\"environment_info\":{},\"error\":null,\"id\":\"\",\"mode\":\"ci\",\"name\":\"default\",\"number\":1,\"open_comment_threads\":[{\"anchor\":{\"kind\":\"point\",\"x\":20.0,\"y\":30.0},\"comments\":[{\"author\":{\"agent\":\"rmcp 3.12.0\",\"kind\":\"agent\",\"name\":null},\"body\":\"Is this change meant?\",\"created_at\":\"\",\"id\":\"\",\"updated_at\":\"\"},{\"author\":{\"agent\":\"rmcp 3.12.0\",\"kind\":\"agent\",\"name\":null},\"body\":\"Yes.\",\"created_at\":\"\",\"id\":\"\",\"updated_at\":\"\"}],\"id\":\"\",\"page\":0,\"platform\":\"\",\"resolved\":false,\"resolved_at\":null,\"side\":\"head\",\"snapshot\":\"greeting\",\"started_in_build\":1,\"started_in_snapshot\":\"\"}],\"passed\":null,\"pr_number\":null,\"project\":\"/pdfs\",\"review_state\":\"none\",\"reviewable\":false,\"reviews\":[],\"snapshots\":[{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"greeting\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"}],\"state\":\"receiving\",\"stats\":{\"added\":0,\"changed\":0,\"config\":0,\"failed\":0,\"ignored\":0,\"pending\":0,\"removed\":0,\"total\":0,\"unchanged\":0},\"summary\":null,\"url\":\"https://app.visualci.test//pdfs/builds/1\",\"warnings\":[]}", + "text": "{\"blocked\":null,\"branch\":\"feat\",\"ci_mode\":\"review\",\"commit\":\"abc\",\"conclusion\":null,\"config\":null,\"created_at\":\"\",\"environment\":\"ci\",\"environment_info\":{},\"error\":null,\"id\":\"\",\"mode\":\"ci\",\"name\":\"default\",\"number\":1,\"open_comment_threads\":[{\"anchor\":{\"kind\":\"point\",\"x\":20.0,\"y\":30.0},\"comments\":[{\"author\":{\"agent\":\"rmcp 3.12.0\",\"kind\":\"agent\",\"name\":null},\"body\":\"Is this change meant?\",\"created_at\":\"\",\"id\":\"\",\"updated_at\":\"\"},{\"author\":{\"agent\":\"rmcp 3.12.0\",\"kind\":\"agent\",\"name\":null},\"body\":\"Yes.\",\"created_at\":\"\",\"id\":\"\",\"updated_at\":\"\"}],\"id\":\"\",\"page\":0,\"platform\":\"\",\"resolved\":false,\"resolved_at\":null,\"side\":\"head\",\"snapshot\":\"greeting\",\"started_in_build\":1,\"started_in_snapshot\":\"\"}],\"passed\":null,\"pr_number\":null,\"project\":\"/pdfs\",\"review_state\":\"none\",\"reviewable\":false,\"reviews\":[],\"snapshots\":[{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"greeting\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"}],\"state\":\"receiving\",\"stats\":{\"added\":0,\"changed\":0,\"config\":0,\"failed\":0,\"ignored\":0,\"pending\":0,\"removed\":0,\"total\":0,\"unchanged\":0},\"summary\":null,\"url\":\"https://app.visualci.test//pdfs/builds/1\",\"warnings\":[]}", "type": "text" } ], @@ -77,6 +77,7 @@ "snapshots": [ { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", diff --git a/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build-2.json b/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build-2.json index c0ff4250..645bd96c 100644 --- a/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build-2.json +++ b/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build-2.json @@ -7,7 +7,7 @@ "result": { "content": [ { - "text": "{\"blocked\":null,\"branch\":\"main\",\"ci_mode\":\"review\",\"commit\":\"abc\",\"conclusion\":null,\"config\":null,\"created_at\":\"\",\"environment\":\"ci\",\"environment_info\":{},\"error\":null,\"groups\":[{\"count\":2,\"prefix\":\"\",\"state\":\"pending\"},{\"count\":5,\"prefix\":\"api/\",\"state\":\"pending\"},{\"count\":35,\"prefix\":\"screenshots/home/\",\"state\":\"pending\"}],\"id\":\"\",\"listed\":\"31 to 42 of 42\",\"mode\":\"ci\",\"name\":\"default\",\"next_offset\":null,\"number\":1,\"passed\":null,\"pr_number\":null,\"project\":\"/pdfs\",\"review_state\":\"none\",\"reviewable\":false,\"reviews\":[],\"snapshots\":[{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/25\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/26\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/27\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/28\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/29\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/30\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/31\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/32\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/33\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/34\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"twice\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"twice\",\"pages\":null,\"platform\":\"firefox\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"}],\"state\":\"receiving\",\"stats\":{\"added\":0,\"changed\":0,\"config\":0,\"failed\":0,\"ignored\":0,\"pending\":0,\"removed\":0,\"total\":0,\"unchanged\":0},\"summary\":null,\"url\":\"https://app.visualci.test//pdfs/builds/1\",\"warnings\":[]}", + "text": "{\"blocked\":null,\"branch\":\"main\",\"ci_mode\":\"review\",\"commit\":\"abc\",\"conclusion\":null,\"config\":null,\"created_at\":\"\",\"environment\":\"ci\",\"environment_info\":{},\"error\":null,\"groups\":[{\"count\":2,\"prefix\":\"\",\"state\":\"pending\"},{\"count\":5,\"prefix\":\"api/\",\"state\":\"pending\"},{\"count\":35,\"prefix\":\"screenshots/home/\",\"state\":\"pending\"}],\"id\":\"\",\"listed\":\"31 to 42 of 42\",\"mode\":\"ci\",\"name\":\"default\",\"next_offset\":null,\"number\":1,\"passed\":null,\"pr_number\":null,\"project\":\"/pdfs\",\"review_state\":\"none\",\"reviewable\":false,\"reviews\":[],\"snapshots\":[{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/25\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/26\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/27\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/28\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/29\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/30\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/31\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/32\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/33\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/34\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"twice\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"twice\",\"pages\":null,\"platform\":\"firefox\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"}],\"state\":\"receiving\",\"stats\":{\"added\":0,\"changed\":0,\"config\":0,\"failed\":0,\"ignored\":0,\"pending\":0,\"removed\":0,\"total\":0,\"unchanged\":0},\"summary\":null,\"url\":\"https://app.visualci.test//pdfs/builds/1\",\"warnings\":[]}", "type": "text" } ], @@ -55,6 +55,7 @@ "snapshots": [ { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -73,6 +74,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -91,6 +93,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -109,6 +112,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -127,6 +131,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -145,6 +150,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -163,6 +169,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -181,6 +188,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -199,6 +207,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -217,6 +226,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -235,6 +245,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -253,6 +264,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", diff --git a/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build-3.json b/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build-3.json index dbcb084e..c965b1bb 100644 --- a/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build-3.json +++ b/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build-3.json @@ -6,7 +6,7 @@ "result": { "content": [ { - "text": "{\"blocked\":null,\"branch\":\"main\",\"ci_mode\":\"review\",\"commit\":\"abc\",\"conclusion\":null,\"config\":null,\"created_at\":\"\",\"environment\":\"ci\",\"environment_info\":{},\"error\":null,\"groups\":[{\"count\":2,\"prefix\":\"\",\"state\":\"pending\"},{\"count\":5,\"prefix\":\"api/\",\"state\":\"pending\"},{\"count\":35,\"prefix\":\"screenshots/home/\",\"state\":\"pending\"}],\"id\":\"\",\"listed\":\"1 to 30 of 42\",\"mode\":\"ci\",\"name\":\"default\",\"next_offset\":30,\"number\":1,\"passed\":null,\"pr_number\":null,\"project\":\"/pdfs\",\"review_state\":\"none\",\"reviewable\":false,\"reviews\":[],\"snapshots\":[{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/0\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/1\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/2\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/3\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/4\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/00\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/01\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/02\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/03\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/04\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/05\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/06\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/07\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/08\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/09\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/10\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/11\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/12\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/13\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/14\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/15\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/16\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/17\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/18\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/19\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/20\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/21\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/22\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/23\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/24\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"}],\"state\":\"receiving\",\"stats\":{\"added\":0,\"changed\":0,\"config\":0,\"failed\":0,\"ignored\":0,\"pending\":0,\"removed\":0,\"total\":0,\"unchanged\":0},\"summary\":null,\"url\":\"https://app.visualci.test//pdfs/builds/1\",\"warnings\":[]}", + "text": "{\"blocked\":null,\"branch\":\"main\",\"ci_mode\":\"review\",\"commit\":\"abc\",\"conclusion\":null,\"config\":null,\"created_at\":\"\",\"environment\":\"ci\",\"environment_info\":{},\"error\":null,\"groups\":[{\"count\":2,\"prefix\":\"\",\"state\":\"pending\"},{\"count\":5,\"prefix\":\"api/\",\"state\":\"pending\"},{\"count\":35,\"prefix\":\"screenshots/home/\",\"state\":\"pending\"}],\"id\":\"\",\"listed\":\"1 to 30 of 42\",\"mode\":\"ci\",\"name\":\"default\",\"next_offset\":30,\"number\":1,\"passed\":null,\"pr_number\":null,\"project\":\"/pdfs\",\"review_state\":\"none\",\"reviewable\":false,\"reviews\":[],\"snapshots\":[{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/0\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/1\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/2\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/3\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/4\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/00\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/01\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/02\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/03\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/04\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/05\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/06\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/07\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/08\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/09\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/10\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/11\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/12\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/13\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/14\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/15\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/16\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/17\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/18\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/19\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/20\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/21\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/22\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/23\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/24\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"}],\"state\":\"receiving\",\"stats\":{\"added\":0,\"changed\":0,\"config\":0,\"failed\":0,\"ignored\":0,\"pending\":0,\"removed\":0,\"total\":0,\"unchanged\":0},\"summary\":null,\"url\":\"https://app.visualci.test//pdfs/builds/1\",\"warnings\":[]}", "type": "text" } ], @@ -54,6 +54,7 @@ "snapshots": [ { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -72,6 +73,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -90,6 +92,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -108,6 +111,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -126,6 +130,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -144,6 +149,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -162,6 +168,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -180,6 +187,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -198,6 +206,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -216,6 +225,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -234,6 +244,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -252,6 +263,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -270,6 +282,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -288,6 +301,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -306,6 +320,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -324,6 +339,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -342,6 +358,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -360,6 +377,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -378,6 +396,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -396,6 +415,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -414,6 +434,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -432,6 +453,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -450,6 +472,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -468,6 +491,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -486,6 +510,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -504,6 +529,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -522,6 +548,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -540,6 +567,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -558,6 +586,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -576,6 +605,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", diff --git a/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build.json b/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build.json index 35693ffe..24cf4358 100644 --- a/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build.json +++ b/app/tests/golden/mcp/get_build_pages_long_lists_and_get_snapshot_finds_a_unique_name_without_its_platform/get_build.json @@ -6,7 +6,7 @@ "result": { "content": [ { - "text": "{\"blocked\":null,\"branch\":\"main\",\"ci_mode\":\"review\",\"commit\":\"abc\",\"conclusion\":null,\"config\":null,\"created_at\":\"\",\"environment\":\"ci\",\"environment_info\":{},\"error\":null,\"groups\":[{\"count\":2,\"prefix\":\"\",\"state\":\"pending\"},{\"count\":5,\"prefix\":\"api/\",\"state\":\"pending\"},{\"count\":35,\"prefix\":\"screenshots/home/\",\"state\":\"pending\"}],\"id\":\"\",\"listed\":\"1 to 30 of 42\",\"mode\":\"ci\",\"name\":\"default\",\"next_offset\":30,\"number\":1,\"passed\":null,\"pr_number\":null,\"project\":\"/pdfs\",\"review_state\":\"none\",\"reviewable\":false,\"reviews\":[],\"snapshots\":[{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/0\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/1\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/2\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/3\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/4\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/00\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/01\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/02\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/03\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/04\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/05\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/06\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/07\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/08\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/09\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/10\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/11\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/12\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/13\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/14\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/15\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/16\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/17\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/18\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/19\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/20\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/21\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/22\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/23\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/24\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"}],\"state\":\"receiving\",\"stats\":{\"added\":0,\"changed\":0,\"config\":0,\"failed\":0,\"ignored\":0,\"pending\":0,\"removed\":0,\"total\":0,\"unchanged\":0},\"summary\":null,\"url\":\"https://app.visualci.test//pdfs/builds/1\",\"warnings\":[]}", + "text": "{\"blocked\":null,\"branch\":\"main\",\"ci_mode\":\"review\",\"commit\":\"abc\",\"conclusion\":null,\"config\":null,\"created_at\":\"\",\"environment\":\"ci\",\"environment_info\":{},\"error\":null,\"groups\":[{\"count\":2,\"prefix\":\"\",\"state\":\"pending\"},{\"count\":5,\"prefix\":\"api/\",\"state\":\"pending\"},{\"count\":35,\"prefix\":\"screenshots/home/\",\"state\":\"pending\"}],\"id\":\"\",\"listed\":\"1 to 30 of 42\",\"mode\":\"ci\",\"name\":\"default\",\"next_offset\":30,\"number\":1,\"passed\":null,\"pr_number\":null,\"project\":\"/pdfs\",\"review_state\":\"none\",\"reviewable\":false,\"reviews\":[],\"snapshots\":[{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/0\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/1\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/2\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/3\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"api/4\",\"pages\":null,\"platform\":\"\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/00\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/01\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/02\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/03\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/04\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/05\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/06\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/07\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/08\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/09\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/10\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/11\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/12\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/13\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/14\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/15\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/16\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/17\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/18\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/19\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/20\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/21\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/22\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/23\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"},{\"approved_elsewhere\":null,\"base_pages\":null,\"change\":null,\"changed_pages\":null,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"matched_environment\":null,\"moved_lines\":0,\"name\":\"screenshots/home/24\",\"pages\":null,\"platform\":\"chrome\",\"review\":null,\"state\":\"pending\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"}],\"state\":\"receiving\",\"stats\":{\"added\":0,\"changed\":0,\"config\":0,\"failed\":0,\"ignored\":0,\"pending\":0,\"removed\":0,\"total\":0,\"unchanged\":0},\"summary\":null,\"url\":\"https://app.visualci.test//pdfs/builds/1\",\"warnings\":[]}", "type": "text" } ], @@ -54,6 +54,7 @@ "snapshots": [ { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -72,6 +73,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -90,6 +92,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -108,6 +111,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -126,6 +130,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -144,6 +149,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -162,6 +168,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -180,6 +187,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -198,6 +206,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -216,6 +225,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -234,6 +244,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -252,6 +263,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -270,6 +282,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -288,6 +301,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -306,6 +320,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -324,6 +339,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -342,6 +358,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -360,6 +377,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -378,6 +396,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -396,6 +415,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -414,6 +434,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -432,6 +453,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -450,6 +472,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -468,6 +491,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -486,6 +510,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -504,6 +529,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -522,6 +548,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -540,6 +567,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -558,6 +586,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", @@ -576,6 +605,7 @@ }, { "approved_elsewhere": null, + "base_pages": null, "change": null, "changed_pages": null, "environment": "", diff --git a/app/tests/golden/mcp/runs_a_build_from_uploaded_files/get_build.json b/app/tests/golden/mcp/runs_a_build_from_uploaded_files/get_build.json index f8847cf1..5855d693 100644 --- a/app/tests/golden/mcp/runs_a_build_from_uploaded_files/get_build.json +++ b/app/tests/golden/mcp/runs_a_build_from_uploaded_files/get_build.json @@ -5,7 +5,7 @@ "result": { "content": [ { - "text": "{\"blocked\":null,\"branch\":\"main\",\"ci_mode\":\"review\",\"commit\":\"abc\",\"conclusion\":\"changes\",\"config\":null,\"created_at\":\"\",\"environment\":\"ci\",\"environment_info\":{},\"error\":null,\"id\":\"\",\"mode\":\"ci\",\"name\":\"default\",\"number\":1,\"passed\":true,\"pr_number\":null,\"project\":\"/pdfs\",\"review_state\":\"auto_approved\",\"reviewable\":true,\"reviews\":[],\"snapshots\":[{\"approved_elsewhere\":null,\"change\":{\"amount\":2,\"fraction\":1.0},\"changed_pages\":1,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"lines_added\":2,\"lines_removed\":0,\"matched_environment\":null,\"moved_lines\":0,\"name\":\"greeting\",\"pages\":1,\"platform\":\"\",\"review\":null,\"state\":\"added\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"}],\"state\":\"completed\",\"stats\":{\"added\":1,\"changed\":0,\"config\":0,\"failed\":0,\"ignored\":0,\"pending\":0,\"removed\":0,\"total\":1,\"unchanged\":0},\"summary\":\"1 added\",\"url\":\"https://app.visualci.test//pdfs/builds/1\",\"warnings\":[]}", + "text": "{\"blocked\":null,\"branch\":\"main\",\"ci_mode\":\"review\",\"commit\":\"abc\",\"conclusion\":\"changes\",\"config\":null,\"created_at\":\"\",\"environment\":\"ci\",\"environment_info\":{},\"error\":null,\"id\":\"\",\"mode\":\"ci\",\"name\":\"default\",\"number\":1,\"passed\":true,\"pr_number\":null,\"project\":\"/pdfs\",\"review_state\":\"auto_approved\",\"reviewable\":true,\"reviews\":[],\"snapshots\":[{\"approved_elsewhere\":null,\"base_pages\":0,\"change\":{\"amount\":2,\"fraction\":1.0},\"changed_pages\":1,\"environment\":\"\",\"error\":null,\"format\":\"text\",\"id\":\"\",\"kind\":\"text\",\"lines_added\":2,\"lines_removed\":0,\"matched_environment\":null,\"moved_lines\":0,\"name\":\"greeting\",\"pages\":1,\"platform\":\"\",\"review\":null,\"state\":\"added\",\"url\":\"https://app.visualci.test//pdfs/builds/1/snapshots/\"}],\"state\":\"completed\",\"stats\":{\"added\":1,\"changed\":0,\"config\":0,\"failed\":0,\"ignored\":0,\"pending\":0,\"removed\":0,\"total\":1,\"unchanged\":0},\"summary\":\"1 added\",\"url\":\"https://app.visualci.test//pdfs/builds/1\",\"warnings\":[]}", "type": "text" } ], @@ -34,6 +34,7 @@ "snapshots": [ { "approved_elsewhere": null, + "base_pages": 0, "change": { "amount": 2, "fraction": 1.0 diff --git a/app/tests/summaries.rs b/app/tests/summaries.rs new file mode 100644 index 00000000..f0e0fd7c --- /dev/null +++ b/app/tests/summaries.rs @@ -0,0 +1,76 @@ +//! The build summary's line for each changed snapshot (`domain::summary`), as the check and the build page show it. + +use app::domain::{pages, summary}; +use app::models::Build; +use app::testing::fixtures; +use laravel::db; +use laravel::testing::prelude::*; + +/// A completed build with one changed document whose comparison has these rows, `(op, base_index, head_index)`. +async fn build_with_pages(rows: &[(&str, Option, Option)]) -> laravel::Result { + let org = fixtures::organization(&format!("org-{}", &laravel::str::uuid7().simple().to_string()[24..])).await?; + let project = fixtures::project(&org, "web").await?; + let id = project.id; + let build_id: Option = db::query!( + "INSERT INTO builds (pid, project_id, number, commit_sha, branch, state) \ + VALUES (gen_random_uuid(), {id}, 1, repeat('a', 40), 'main', 'completed') RETURNING id" + ) + .scalar() + .await?; + let build_id = build_id.expect("a build"); + let snapshot: Option = db::query!( + "INSERT INTO snapshots (pid, build_id, name, kind, state, source_fingerprint) \ + VALUES (gen_random_uuid(), {build_id}, 'samples/book', 'document', 'changed', 'f') RETURNING id" + ) + .scalar() + .await?; + let snapshot = snapshot.expect("a snapshot"); + for (position, &(op, base, head)) in (0i32..).zip(rows) { + let state = if op == "unchanged" { "unchanged" } else { "changed" }; + db::query!( + "INSERT INTO snapshot_pages (snapshot_id, position, op, state, base_index, head_index) \ + VALUES ({snapshot}, {position}, {op}, {state}, {base}, {head})" + ) + .insert() + .await?; + } + Ok(Build::find(build_id).await?.expect("the build")) +} + +/// A reflowed book (5 pages becoming 4) aligns over 6 positions, one "inserted" and two "removed": the summary leads +/// with the real page counts, not "1 page added, 2 pages removed" (sc-9184). +#[laravel::test] +async fn a_reflowed_document_leads_with_both_page_counts(_app: Application) -> laravel::Result<()> { + let build = build_with_pages(&[ + ("unchanged", Some(0), Some(0)), + ("removed", Some(1), None), + ("removed", Some(2), None), + ("inserted", None, Some(1)), + ("changed", Some(3), Some(2)), + ("unchanged", Some(4), Some(3)), + ]) + .await?; + let line = summary::summary_line(&build).await?.expect("a summary"); + assert!(line.contains("samples/book: 5 → 4 pages (1 fewer), page 3 changed"), "{line}"); + assert!(!line.contains("added") && !line.contains("removed"), "{line}"); + Ok(()) +} + +/// With as many pages on each side, a page taken out and another put in are still told as such. +#[laravel::test] +async fn the_same_page_count_still_says_what_was_added_and_removed(_app: Application) -> laravel::Result<()> { + let build = + build_with_pages(&[("unchanged", Some(0), Some(0)), ("removed", Some(1), None), ("inserted", None, Some(1))]) + .await?; + let line = summary::summary_line(&build).await?.expect("a summary"); + assert!(line.contains("samples/book: 1 page added, 1 page removed"), "{line}"); + Ok(()) +} + +#[test] +fn page_counts_come_from_each_sides_indexes() { + let rows = [(Some(0), Some(0)), (Some(1), None), (Some(2), None), (None, Some(1)), (Some(3), Some(2))]; + assert_eq!(pages::side_counts(rows), (4, 3)); + assert_eq!(pages::shown_count((4, 3)), 3); + assert_eq!(pages::shown_count((4, 0)), 4, "a removed snapshot shows its base's pages"); +} diff --git a/frontend/src/api/types.ts b/frontend/src/api/types.ts index 0a9b21b3..4df50c4d 100644 --- a/frontend/src/api/types.ts +++ b/frontend/src/api/types.ts @@ -424,7 +424,10 @@ export type SnapshotRow = { state: SnapshotState review: SnapshotReview error: string | null + /** The head's page count (the base's for a removed snapshot). */ pages: number + /** The base's page count: differs from `pages` when the document gained or lost pages. */ + base_pages: number changed_pages: number /** How big the change is: the largest share of a page (or of the lines) that changed, and how many pixels (or * lines). The build lists the biggest first. */ diff --git a/frontend/src/pages/BuildPage.tsx b/frontend/src/pages/BuildPage.tsx index 4a636606..721542a4 100644 --- a/frontend/src/pages/BuildPage.tsx +++ b/frontend/src/pages/BuildPage.tsx @@ -495,7 +495,11 @@ function SnapshotItem({ {s.kind === 'document' && ( {' '} - {s.state === 'changed' ? `${s.changed_pages} of ${plural(s.pages, 'page')} changed` : plural(s.pages, 'page')} + {s.state === 'changed' && s.base_pages && s.base_pages !== s.pages + ? `${s.base_pages} → ${plural(s.pages, 'page')}, ${s.changed_pages} changed` + : s.state === 'changed' + ? `${s.changed_pages} of ${plural(s.pages, 'page')} changed` + : plural(s.pages, 'page')} )}