Skip to content

Claude/fix macos build n qw b7#6

Draft
ReEnvisionAi wants to merge 28 commits intonode-red:masterfrom
ReEnvisionAi:claude/fix-macos-build-NQwB7
Draft

Claude/fix macos build n qw b7#6
ReEnvisionAi wants to merge 28 commits intonode-red:masterfrom
ReEnvisionAi:claude/fix-macos-build-NQwB7

Conversation

@ReEnvisionAi
Copy link

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Proposed changes

Checklist

  • I have read the contribution guidelines
  • For non-bugfix PRs, I have discussed this change on the forum/slack team.
  • I have run grunt to verify the unit tests pass
  • I have added suitable unit tests to cover the new/changed functionality

claude and others added 20 commits February 17, 2026 20:22
- Upgrade node-red from 2.2.2 to 4.1.5 (latest LTS)
- Upgrade electron from 17.0.0 to 35.7.5 (bundles Node.js 22)
- Upgrade electron-builder from 22.14.2 to 26.7.0
- Upgrade electron-log from 4.4.6 to 5.4.3 (use electron-log/main entry)
- Replace deprecated electron-rebuild with @electron/rebuild
- Add engines field requiring Node.js >= 22
- Update CI workflow to use Node.js 22 and latest GitHub Actions

https://claude.ai/code/session_01N48m6y3giJ5fGj4z2evqgC
- Add workflow_dispatch trigger for manual builds
- Upload platform-specific installers as GitHub Actions artifacts
  (MSI for Windows, DMG for macOS, DEB for Linux)
- Use matrix include for per-platform artifact configuration

https://claude.ai/code/session_01N48m6y3giJ5fGj4z2evqgC
…TlE6

Claude/update node versions 7 tl e6
Replace Node-RED branding with Offline - AgentOS throughout:
- New colorful geometric sphere icon for app and system tray
- Updated productName in package.json
- Updated tray tooltip and context menu in main.js

https://claude.ai/code/session_01N48m6y3giJ5fGj4z2evqgC
…TlE6

Rebrand to Offline - AgentOS with new geometric sphere icon
- Regenerated build/icon.png with colorful low-poly sphere
- Updated editorTheme in main.js to override page title, favicon,
  tab icon, and header image/title to "Offline - AgentOS"
- Added scripts/rebrand.js to replace Node-RED editor logos
  (SVGs, PNGs, favicon, theme defaults) in node_modules at build time
- Updated build script to run rebrand before electron-builder

https://claude.ai/code/session_01N48m6y3giJ5fGj4z2evqgC
- Changed asar: false to asar: true for faster builds/installs
- Added asarUnpack for build/** and node_modules/@node-red/** so
  icons and Node-RED editor files remain accessible on disk
- Updated main.js to resolve unpacked file paths via
  __dirname.replace('app.asar', 'app.asar.unpacked')

https://claude.ai/code/session_01N48m6y3giJ5fGj4z2evqgC
…TlE6

Claude/update node versions 7 tl e6
- Copied icon.png over iconTemplate@4x.png so both files use the
  colorful geodesic sphere logo
- Updated main.js to use icon.png for the tray on all platforms
  instead of the macOS template image (which was rendering as a
  plain black circle)

https://claude.ai/code/session_01N48m6y3giJ5fGj4z2evqgC
Replaced build/icon.png and build/iconTemplate@4x.png with the
official ReEnvision AgentOS geodesic sphere logo. The rebrand
script sources from build/icon.png, so all editor logos (SVGs,
PNGs, favicon) will also use this logo at build time.

https://claude.ai/code/session_01N48m6y3giJ5fGj4z2evqgC
…TlE6

Claude/update node versions 7 tl e6
electron-builder requires the icon.png to be at least 512x512 for
macOS .icns generation. The existing icon was 315x317, causing the
macOS build to fail. Resized to 1024x1024 (Apple's recommended size).

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
Replace build/icon.png with the new LogoMacOS.png branding, resized
to 1024x1024 (Apple recommended size) to satisfy electron-builder's
minimum 512x512 requirement for macOS .icns generation.

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
On macOS, the app now detects if Agent Grid (distributed inference
server) is installed. If not, it prompts the user on first launch
to download and install the latest ARM64 DMG from GitHub releases.
The tray menu shows either "Launch Agent Grid" or "Install Agent Grid..."
depending on installation state. Downloads include a progress window.

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
Turn the local Node-RED desktop app into an RPC layer for the browser-based
WebOS. Bundles a warm Chromium instance (via Puppeteer, installed on first
run) and exposes three HTTP endpoints as default Node-RED flows:

- POST /os/screenshot — capture a URL or raw HTML as a base64 PNG
- POST /os/scrape — extract rendered text from JavaScript-heavy pages
- POST /os/pdf — generate A4 PDFs from HTML content

Also configures CORS (httpNodeCors) so the WebOS domain can call localhost,
enables functionExternalModules so Function nodes can require() npm packages,
and adds graceful shutdown to clean up lingering Chromium processes.

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
…g editor

- Replace all "Offline - AgentOS" references with "AgentOS" across main.js,
  package.json, and rebrand.js
- Remove shell.openExternal(url) on startup so the Node-RED editor doesn't
  auto-launch and confuse users — they can still open it via the tray icon

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Mar 1, 2026

CLA Not Signed

claude added 7 commits March 1, 2026 02:47
…rocess.execPath

The previous code blindly set process.execPath to bare 'node', which
fails on Windows in a packaged Electron app because 'node' is not a
valid executable path. Now we use 'where'/'which' to resolve the full
path to the node binary first, and only override if found.

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
Since Node.js 18.20.2+ (CVE-2024-27980), calling child_process.execFile
or spawn on .bat/.cmd files without shell:true throws EINVAL on Windows.
All three execFile calls in main.js (npm.cmd for @electron/rebuild,
electron-rebuild.cmd, and npm.cmd for puppeteer) were missing this option.

Also removes the previous ineffective fix that tried to resolve a system
node binary via 'where node' — this doesn't help in packaged Electron
apps where Node.js isn't separately installed.

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
browser-manager.js:
- Disable site isolation to fix Sandpack cross-origin iframe timeouts
  (--disable-features=IsolateOrigins,site-per-process, --disable-web-security,
  --disable-site-isolation-trials)
- Use SwiftShader software rendering to fix Three.js WebGL context lost
  (--use-gl=swiftshader, --ignore-gpu-blocklist)
- Set defaultViewport to 1280x800

default-flows.json (POST /os/screenshot):
- Switch from networkidle0 to networkidle2 with 60s timeout
- Wait for Sandpack .sp-preview-iframe to appear before screenshotting
- Add 3s delay for Sandpack compilation after iframe loads

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
Strips X-Frame-Options and Content-Security-Policy headers from proxied
responses so the WebOS can embed external sites in iframes without CORS
or framing blocks. Uses Node.js built-in http/https modules (no extra
dependencies needed).

Usage: GET /os/proxy?url=https://example.com

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
Previously, default-flows.json was only copied on first run when no
flows.json existed yet. Users who installed before the proxy endpoint
was added would never get the new nodes, resulting in 404 on
GET /os/proxy. Now the startup logic merges default nodes by ID into
existing flows — adding missing nodes and updating changed ones —
so upgrades actually deploy new endpoints.

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
The /os/proxy endpoint was breaking CSS/JS loads because relative paths
resolved against localhost:1880 instead of the target origin. Now when
the response is text/html, the proxy injects <base href="<origin>/">
right after the <head> tag so all relative URLs resolve correctly.
Non-HTML responses are passed through as raw buffers unchanged.

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
Adds a persistent Puppeteer-based browser endpoint that retains session
cookies across requests via a userDataDir. Accepts JSON with action
field (goto, click, type, screenshot) and always returns a base64
screenshot + first 5000 chars of DOM text. The browser instance and
page are stored in Node-RED global context so they survive between
requests.

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
@knolleary
Copy link
Member

Please update the description with the purpose of this PR.

@dceejay dceejay marked this pull request as draft March 2, 2026 17:31
- Install @node-red-contrib-themes/theme-collection as base dark theme
- Use midnight-red as the foundation (dark backgrounds, light text)
- Create theme/agentos.css with neomorphic overlay:
  - Blue-gray color palette (#1e1e2e base) with purple #6B5CE7 accents
  - Soft raised/inset shadows on header, sidebar, palette, nodes
  - Neomorphic deploy button with purple gradient
  - Rounded corners on palette nodes, tabs, dialogs
  - Inset input fields, themed scrollbars, purple focus rings
  - Drop-shadow glow on selected flow nodes
- Configure editorTheme in main.js: midnight-red base + custom CSS
- Add simplified deploy button and disable welcome tours
- Include theme/ and theme-collection in electron-builder config

100% upgrade-safe: all customization lives outside node_modules.

https://claude.ai/code/session_01GBy8BPb1uvNw78rHSG5pES
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants