PageSourceSearch

https://imperfect.co/_next/static/chunks/6621.d4ea87654051f7d3.js

js imperfect.co collected 2026-10-08 05:41:28 UTC 2,541 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6621],{86621:(t,e,a)=>{a.d(e,{fetchGoalTape:()=>i});var n=a(94222),o=a(75571);let s=/^[a-z0-9][a-z0-9_-]{0,63}$/;function r(t,e){throw new n.X6("unknown","tape ".concat(t,": ").concat(e))}function c(t){return"object"==typeof t&&null!==t&&!Array.isArray(t)}async function i(t){let e;"string"==typeof t&&s.test(t)||r(JSON.stringify(t),"is not a tape name");let a="".concat("/goals-tapes","/").concat(t,".json");try{let n=await fetch(a,{cache:"no-store"});n.ok||r(a,"answered ".concat(n.status,". Record one with `lg goals-record --from-session <id> ")+"--name ".concat(t,"`, or name a committed capture through `lg goals-screens --tape`.")),e=await n.json()}catch(t){if(t instanceof n.X6)throw t;r(a,"could not be loaded (".concat(t instanceof Error?t.message:String(t),")"))}var i=e;c(i)||r(a,"is not an object");let{meta:u,turns:l}=i;c(u)&&"string"==typeof u.name||r(a,"has no meta.name"),"from-session"!==u.source&&"conjured"!==u.source&&"fixture"!==u.source&&r(a,"meta.source is ".concat(JSON.stringify(u.source),", not from-session, conjured or fixture"));let{locale:d,recorded_at:m}=u;null!==d&&"string"!=typeof d&&r(a,"meta.locale is not a string"),null!==m&&"string"!=typeof m&&r(a,"meta.recorded_at is not a string"),null!==m&&Number.isNaN(new Date(m).getTime())&&r(a,"meta.recorded_at is not a date (".concat(JSON.stringify(m),")")),Array.isArray(l)&&0!==l.length||r(a,"carries no turns");let f=l.map((t,e)=>{var n;let s="turn ".concat(e+1);c(t)||r(a,"".concat(s," is not an object"));let{message:i,reply:u,document:l,status:d,deltas:m}=t;("string"!=typeof i||""===i.trim())&&r(a,"".concat(s," has no athlete message")),("string"!=typeof u||""===u.trim())&&r(a,"".concat(s," has no reply")),"string"!=typeof l&&r(a,"".concat(s," has no document")),o.Nk.includes(d)||r(a,"".concat(s," has status ").concat(JSON.stringify(d)));let f=null==(n=(0,o.AI)(l))?void 0:n.rim;return void 0===f&&r(a,"".concat(s," carries a document the rim parser cannot read")),f.status!==d&&r(a,"".concat(s," says ").concat(d," but its document's rim says ").concat(f.status)),void 0!==m&&(Array.isArray(m)&&m.every(t=>"string"==typeof t)||r(a,"".concat(s," has deltas that are not strings")),m.join("").trim()!==u&&r(a,"".concat(s," has deltas that do not rebuild its reply"))),void 0===m?{message:i,reply:u,document:l,status:d}:{message:i,reply:u,document:l,status:d,deltas:m}});return{meta:{name:u.name,source:u.source,locale:d,recorded_at:m,statuses:f.map(t=>t.status)},turns:f}}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.