-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Description
Electron-Builder Version
26.4.0
Target
macOS (arm64)
Description
DMG builds fail on macOS 26.4 Tahoe (beta) with the error "Unable to attach disk image" followed by "hdiutil: attach failed - no mountable file systems".
This is caused by a known issue in the macOS Tahoe beta affecting HFS+ mounting. Apple has acknowledged this in their official release
notes:
From macOS Tahoe 26.4 Beta Release
Notes:"External Media - Known Issues: HFS external media might fail to mount automatically. (168672160)"
Thedmgbuildlibrary bundled indmg-builderdefaults to creating HFS+ sparse images, which triggers this bug.
Error Output
⨯ /usr/bin/python3 process failed 1
Exit code: 1
dmgbuild.core.DMGError: Unable to attach disk image:
hdiutil: attach failed - no mountable file systems
Root Cause Analysis
The DMG build process in dmgbuild/core.py:
- Creates a writable HFS+ sparse image
- Attaches the sparse image via
hdiutil attach← fails on macOS Tahoe beta - Populates the mounted volume
- Detaches and converts to read-only DMG
Verification:
HFS+ sparse image - FAILS on macOS 26 Tahoe
hdiutil create -size 200m -fs HFS+ -volname "Test" -type SPARSE /tmp/test_hfs.sparseimage
hdiutil attach -nobrowse -owners off /tmp/test_hfs.sparseimage
Error: hdiutil: attach failed - no mountable file systems
APFS sparse image - WORKS
hdiutil create -size 200m -fs APFS -volname "Test" -type SPARSE /tmp/test_apfs.sparseimage
hdiutil attach -nobrowse -owners off /tmp/test_apfs.sparseimage
Proposed Fix
Change the default filesystem from HFS+ to APFS in dmg-builder/vendor/dmgbuild/core.py.
Why APFS is the better default
| Aspect | HFS+ | APFS |
|---|---|---|
| Introduced | 1998 | 2017 (macOS High Sierra) |
| Default on new Macs | No (since 2017) | Yes |
| macOS minimum | All versions | 10.13+ (High Sierra) |
| Optimized for | HDDs | SSDs & Flash storage |
| Status | Legacy | Actively developed |
| Additional benefits of APFS: |
- Future-proof: Apple has been moving away from HFS+ since 2017. All new Macs ship with APFS.
- Better performance: APFS is optimized for modern storage (SSDs, NVMe) which all Apple Silicon Macs use.
- Wide compatibility: macOS 10.13+ covers 8+ years of macOS releases (2017-2025), which is sufficient for most Electron app
deployment targets. - Avoids beta bugs: Works around the current macOS Tahoe beta issue and any future HFS+ deprecation Apple may implement.
- No user impact: The filesystem is only used during the build process for the temporary sparse image - the final DMG output format
remains unchanged. Electron itself has minimum macOS requirements - Electron 22+ requires macOS 10.13+, so your users already need High Sierra or later
Environment
- macOS: 26.4 Tahoe (beta)
- Architecture: Apple Silicon (arm64)
- electron-builder: 26.4.0
- dmg-builder: 26.4.0
Related Issues
- Issue with hdiutil when building on MacOS #8415 - hdiutil issues (different error -
hdiutil convert) - Universal build fails on non-ARM64 hardware, and M1 target DMG is 'damaged' #5850 - M1 deprecating HFS+
- Operation not permitted during dmg building on macOS 11 Big Sur #5465 - HFS+ issues on Big Sur