Bumps the desktop runtime to electron 42 (dependabot PR #9945) and closes a supply-chain gap in the Linux/Mac packaging scripts that predated this bump. Why the bump is safe: - macOS UNNotification API change — pgAdmin's runtime does not use Electron's Notification API (only a UI toast comment in src/js/pgadmin.js:211; no `new Notification(...)` anywhere). - postinstall no longer downloads electron — production packaging fetches the binary directly via wget from GitHub releases, never via electron's postinstall script. - Offscreen rendering scale-factor change — no OSR usage anywhere in runtime/src/js/. While verifying, found that pkg/linux/build-functions.sh and pkg/mac/build-functions.sh resolve the packaged electron version via: ELECTRON_VERSION="$(npm info electron version)" This pulls whatever currently carries the `latest` dist-tag on the npm registry. Any newly published electron release — including a hypothetical malicious one — would land in shipped binaries without review, regardless of what runtime/package.json pins. Replace with sed-based extraction from runtime/package.json and fail loudly if extraction returns empty. The Windows installer (pkg/win32/installer.iss.in) does not have this issue (it bundles a pre-built tree, no electron download step). Net change in runtime/yarn.lock is mostly deletions — electron 42 ships with @electron/get 5.x, which dropped a large transitive dependency tree associated with the old postinstall download path. Verified: - eslint (runtime): clean (silent) - yarn install (runtime): resolved to electron 42.2.0 within ^42.1.0 range - sed extraction smoke-tested: returns 42.1.0 from current runtime/package.json
pgAdmin macOS Builds
Required Packages
Either build the sources or get them from macports or similar:
-
Yarn & NodeJS
-
PostgreSQL 12 or above from http://www.postgresql.org/
-
Python 3.6+ (required for building). The build environment should run this version of python in response to the python command.
Building
-
To bundle a different version of Python from the default of 3.13.1, set the PGADMIN_PYTHON_VERSION environment variable, e.g:
export PGADMIN_PYTHON_VERSION=3.13.11 -
If a path different from the default of /usr/local/pgsql for the PostgreSQL installation has been used, set the PGADMIN_POSTGRES_DIR environment variable appropriately, e.g:
export PGADMIN_POSTGRES_DIR=/opt/local/pgsql -
If you want to codesign the appbundle, copy codesign.conf.in to codesign.conf and set the values accordingly.
-
If you want to notarize the appbundle, copy notarization.conf.in to notarization.conf and set the values accordingly. Note that notarization will fail if the code isn't signed.
-
To build only DMG file, go to pgAdmin4 source root directory and execute:
make appbundleTo build both DMG and ZIP files, go to pgAdmin4 source root directory and execute:
make appbundle BUILD_OPTS="--zip"This will create the python virtual environment and install all the required python modules mentioned in the requirements file using pip, build the runtime code and finally create the app bundle and the DMG and/or ZIP in ./dist directory.