zed-industries / zed

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
https://zed.dev
Other
48.32k stars 2.87k forks source link

Auto update always fails (possibly due to non-Administrator user?) #11602

Closed liamjones closed 2 weeks ago

liamjones commented 5 months ago

Check for existing issues

Describe the bug / provide steps to reproduce it

Whenever there's an update for Zed it downloads but fails to install. I have to manually download the new version from the website and install it in /Applications.

This may be down to an issue I've hit with some other pieces of software (JetBrains Toolbox, Docker Desktop) and non-administrator user accounts.

Due to security policies at our company, our regular day-to-day users are Mac "Standard" users, not "Administrator" users. We have a separate admin user account with a different password that we use when appropriate for elevated rights.

/Applications needs elevated rights to write to. With apps that do correctly support installing updates as a Standard user, I see an OS dialog like this:

image

and I can provide my Administrator account details to write to /Applications.

Environment

Zed: v0.133.7 (Zed) OS: macOS 14.4.1 Memory: 32 GiB Architecture: x86_64

If applicable, add mockups / screenshots to help explain present your vision of the feature

No response

If applicable, attach your ~/Library/Logs/Zed/Zed.log file to this issue.

2024-05-09T10:58:41+01:00 [INFO] ========== starting zed ========== 2024-05-09T10:58:41+01:00 [INFO] Opening main db 2024-05-09T10:58:41+01:00 [INFO] Using git binary path: Some("/Applications/Zed.app/Contents/MacOS/git") 2024-05-09T10:58:41+01:00 [INFO] extensions updated. loading 1, reloading 0, unloading 0 2024-05-09T10:58:41+01:00 [ERROR] crates/zed/src/zed.rs:660: EOF while parsing a value at line 1 column 0 2024-05-09T10:58:41+01:00 [INFO] Opening main db 2024-05-09T10:58:42+01:00 [INFO] set status on client 0: Authenticating 2024-05-09T10:58:42+01:00 [INFO] building git repository, .git path in the worktree: ".git" 2024-05-09T10:58:42+01:00 [INFO] set status on client 134549: Connecting 2024-05-09T10:58:42+01:00 [ERROR] crates/workspace/src/persistence/model.rs:314: Deserializer does not exist for item kind: diagnostics 2024-05-09T10:58:42+01:00 [INFO] connected to rpc endpoint https://collab.zed.dev/rpc 2024-05-09T10:58:43+01:00 [INFO] set environment variables from shell:/bin/zsh, path:/Users/liam.jones/.volta/bin:/Users/liam.jones/.mint/bin:/usr/local/opt/whois/bin:/Applications/ARX-3.9.0.app/Contents/bin:/Users/liam.jones/.sdkman/candidates/java/current/bin:/Users/liam.jones/.rbenv/shims:/usr/local/opt/ccache/libexec:/Users/liam.jones/.cargo/bin:/Users/liam.jones/Library/Android/sdk/platform-tools:/Users/liam.jones/Library/Android/sdk/emulator:/Users/liam.jones/.fastlane/bin:/usr/local/sbin:/Users/liam.jones/.local/bin:/usr/local/opt/python/libexec/bin:/Users/liam.jones/code/go/bin:export HOMEBREW_PREFIX="/usr/local"; 2024-05-09T10:58:43+01:00 [INFO] add connection to peer 2024-05-09T10:58:43+01:00 [INFO] add_connection; 2024-05-09T10:58:43+01:00 [INFO] waiting for server hello 2024-05-09T10:58:43+01:00 [INFO] got server hello 2024-05-09T10:58:43+01:00 [INFO] set status to connected (connection id: ConnectionId { owner_id: 0, id: 0 }, peer id: PeerId { owner_id: 402, id: 2707888 }) 2024-05-09T10:58:43+01:00 [INFO] set status on client 134549: Connected { peer_id: PeerId { owner_id: 402, id: 2707888 }, connection_id: ConnectionId { owner_id: 0, id: 0 } } 2024-05-09T10:58:44+01:00 [INFO] response dropped without fully consuming the response body, connection won't be reused Aborting a response without fully consuming the response body can result in sub-optimal performance. See https://github.com/sagebind/isahc/wiki/Connection-Reuse#closing-connections-early. 2024-05-09T10:58:54+01:00 [INFO] downloaded update. path: "/var/folders/wg/mjxl5l514m1fws3krvwwt0tw0000gn/T/zed-auto-updateXApc2I/Zed.dmg" 2024-05-09T10:58:54+01:00 [ERROR] auto-update failed: error:No such file or directory (os error 2) 2024-05-09T10:59:15+01:00 [INFO] downloaded update. path:"/var/folders/wg/mjxl5l514m1fws3krvwwt0tw0000gn/T/zed-auto-updateXcxGkN/Zed.dmg" 2024-05-09T10:59:15+01:00 [ERROR] auto-update failed: error:No such file or directory (os error 2)

liamjones commented 2 weeks ago

It seems like updates under non admin accounts work in recent versions so I'm going to close this issue.

It doesn't present an elevation prompt but still seems to be able to do the update under /Applications.