Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
93 changes: 46 additions & 47 deletions latest_release.json
Original file line number Diff line number Diff line change
@@ -1,45 +1,45 @@
{
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/272959448",
"assets_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/272959448/assets",
"upload_url": "https://uploads.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/272959448/assets{?name,label}",
"html_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/tag/v2.0.2",
"id": 272959448,
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/273025127",
"assets_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/273025127/assets",
"upload_url": "https://uploads.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/273025127/assets{?name,label}",
"html_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/tag/v2.0.3",
"id": 273025127,
"author": {
"login": "github-actions[bot]",
"id": 41898282,
"node_id": "MDM6Qm90NDE4OTgyODI=",
"avatar_url": "https://avatars.githubusercontent.com/in/15368?v=4",
"login": "rcholic",
"id": 135060,
"node_id": "MDQ6VXNlcjEzNTA2MA==",
"avatar_url": "https://avatars.githubusercontent.com/u/135060?v=4",
"gravatar_id": "",
"url": "https://api.github.com/users/github-actions%5Bbot%5D",
"html_url": "https://github.com/apps/github-actions",
"followers_url": "https://api.github.com/users/github-actions%5Bbot%5D/followers",
"following_url": "https://api.github.com/users/github-actions%5Bbot%5D/following{/other_user}",
"gists_url": "https://api.github.com/users/github-actions%5Bbot%5D/gists{/gist_id}",
"starred_url": "https://api.github.com/users/github-actions%5Bbot%5D/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/github-actions%5Bbot%5D/subscriptions",
"organizations_url": "https://api.github.com/users/github-actions%5Bbot%5D/orgs",
"repos_url": "https://api.github.com/users/github-actions%5Bbot%5D/repos",
"events_url": "https://api.github.com/users/github-actions%5Bbot%5D/events{/privacy}",
"received_events_url": "https://api.github.com/users/github-actions%5Bbot%5D/received_events",
"type": "Bot",
"url": "https://api.github.com/users/rcholic",
"html_url": "https://github.com/rcholic",
"followers_url": "https://api.github.com/users/rcholic/followers",
"following_url": "https://api.github.com/users/rcholic/following{/other_user}",
"gists_url": "https://api.github.com/users/rcholic/gists{/gist_id}",
"starred_url": "https://api.github.com/users/rcholic/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/rcholic/subscriptions",
"organizations_url": "https://api.github.com/users/rcholic/orgs",
"repos_url": "https://api.github.com/users/rcholic/repos",
"events_url": "https://api.github.com/users/rcholic/events{/privacy}",
"received_events_url": "https://api.github.com/users/rcholic/received_events",
"type": "User",
"user_view_type": "public",
"site_admin": false
},
"node_id": "RE_kwDOQshiJ84QRQfY",
"tag_name": "v2.0.2",
"node_id": "RE_kwDOQshiJ84QRghn",
"tag_name": "v2.0.3",
"target_commitish": "main",
"name": "Release v2.0.2",
"name": "Release v2.0.3",
"draft": false,
"immutable": false,
"prerelease": false,
"created_at": "2025-12-27T01:12:14Z",
"updated_at": "2025-12-27T01:13:47Z",
"published_at": "2025-12-27T01:13:15Z",
"updated_at": "2025-12-27T22:46:31Z",
"published_at": "2025-12-27T22:46:13Z",
"assets": [
{
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/assets/333313919",
"id": 333313919,
"node_id": "RA_kwDOQshiJ84T3fd_",
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/assets/333567799",
"id": 333567799,
"node_id": "RA_kwDOQshiJ84T4dc3",
"name": "extension-files.tar.gz",
"label": "",
"uploader": {
Expand All @@ -65,17 +65,17 @@
},
"content_type": "application/gzip",
"state": "uploaded",
"size": 73449,
"digest": "sha256:679e004e2be6d7ccab6030b2437353aeab74f0e5882608c3b38048ecffecff82",
"download_count": 2,
"created_at": "2025-12-27T01:13:16Z",
"updated_at": "2025-12-27T01:13:16Z",
"browser_download_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/download/v2.0.2/extension-files.tar.gz"
"size": 73434,
"digest": "sha256:ca93cdaf875792eb22333f7ba5b13dd129552f388900e624422e73959338d8fb",
"download_count": 0,
"created_at": "2025-12-27T22:46:31Z",
"updated_at": "2025-12-27T22:46:31Z",
"browser_download_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/download/v2.0.3/extension-files.tar.gz"
},
{
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/assets/333313918",
"id": 333313918,
"node_id": "RA_kwDOQshiJ84T3fd-",
"url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/assets/333567800",
"id": 333567800,
"node_id": "RA_kwDOQshiJ84T4dc4",
"name": "extension-package.zip",
"label": "",
"uploader": {
Expand All @@ -101,16 +101,15 @@
},
"content_type": "application/zip",
"state": "uploaded",
"size": 75594,
"digest": "sha256:e44d1c2d30ada8912df9b1fe3c96a69b9a74a9c6bf89f7c21397d07ec75dda9c",
"size": 75584,
"digest": "sha256:291750ec174d9aadade298d2a2aa1057d08a138e2650c97cd93d56b6bcbee713",
"download_count": 0,
"created_at": "2025-12-27T01:13:16Z",
"updated_at": "2025-12-27T01:13:16Z",
"browser_download_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/download/v2.0.2/extension-package.zip"
"created_at": "2025-12-27T22:46:31Z",
"updated_at": "2025-12-27T22:46:31Z",
"browser_download_url": "https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/releases/download/v2.0.3/extension-package.zip"
}
],
"tarball_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/tarball/v2.0.2",
"zipball_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/zipball/v2.0.2",
"body": "## What's Changed\r\n* Close gaps during migration from Servo + Chrome to extension migrations by @rcholic in https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/pull/17\r\n\r\n\r\n**Full Changelog**: https://github.com/SentienceAPI/Sentience-Geometry-Chrome-Extension/compare/v2.0.1...v2.0.2",
"mentions_count": 1
"tarball_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/tarball/v2.0.3",
"zipball_url": "https://api.github.com/repos/SentienceAPI/Sentience-Geometry-Chrome-Extension/zipball/v2.0.3",
"body": ""
}
6 changes: 3 additions & 3 deletions sentience/extension/background.js
Original file line number Diff line number Diff line change
Expand Up @@ -144,13 +144,13 @@ async function handleScreenshotCapture(_tabId, options = {}) {
async function handleSnapshotProcessing(rawData, options = {}) {
const MAX_ELEMENTS = 10000; // Safety limit to prevent hangs
const startTime = performance.now();

try {
// Safety check: limit element count to prevent hangs
if (!Array.isArray(rawData)) {
throw new Error('rawData must be an array');
}

if (rawData.length > MAX_ELEMENTS) {
console.warn(`[Sentience Background] ⚠️ Large dataset: ${rawData.length} elements. Limiting to ${MAX_ELEMENTS} to prevent hangs.`);
rawData = rawData.slice(0, MAX_ELEMENTS);
Expand Down Expand Up @@ -186,7 +186,7 @@ async function handleSnapshotProcessing(rawData, options = {}) {
// Add timeout protection (18 seconds - less than content.js timeout)
analyzedElements = await Promise.race([
wasmPromise,
new Promise((_, reject) =>
new Promise((_, reject) =>
setTimeout(() => reject(new Error('WASM processing timeout (>18s)')), 18000)
)
]);
Expand Down
2 changes: 1 addition & 1 deletion sentience/extension/content.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ function handleSnapshotRequest(data) {
if (responded) return; // Already responded via timeout
responded = true;
clearTimeout(timeoutId);

const duration = performance.now() - startTime;

// Handle Chrome extension errors (e.g., background script crashed)
Expand Down
Loading