withfig / fig

Public issue tracker for Fig.
https://fig.io
MIT License
2.05k stars 63 forks source link

(eval):source:79: no such file or directory: /Contents/plugins/terminal/.zshenv #1357

Open derkan opened 2 years ago

derkan commented 2 years ago

Description:

Please include a detailed description of the issue (and an image or screen recording, if applicable)

Every time I open terminal in Goland I get this error:

(eval):source:79: no such file or directory: /Contents/plugins/terminal/.zshenv

There is no path starting with /Content/... on my system.

Details:

OS Fig Shell
macOS 12.3.1 (21E258) 1.0.57 /bin/zsh
fig diagnostic

# Fig Diagnostics ## Fig details: - Fig version: Version 1.0.57 (B437) [Turkish Q] - Bundle path: /Applications/Fig.app - Autocomplete: true - Settings.json: true - Accessibility: true - Number of specs: 0 - Symlinked dotfiles: false - Only insert on tab: false - Keybindings path: - Installation Script: true - PseudoTerminal Path: - SecureKeyboardInput: false - SecureKeyboardProcess: ## Hardware Info: - Model Name: MacBook Pro - Model Identifier: MacBookPro16,1 - Chip: - Cores: 8 - Memory: 16 GB ## OS Info: - macOS 12.3.1 (21E258) ## Environment: - User Shell: /bin/zsh - CLI Installed: true - Executable Location: /usr/local/bin/fig - Current Window ID: 145/% (com.jetbrains.goland) - Active Process: zsh (39555) - /dev/ttys008 - Installed via Brew: true - Environment Variables: - TERM=xterm-256color - TERM_SESSION_ID=a384844d-e394-4bfe-92fa-3c2022a0dd59 - FIG_INTEGRATION_VERSION=8 - FIG_TERM=1 - FIG_TERM_VERSION=4.3.0 - FIG_PID=39555 ## Integrations: - SSH: false - TMUX: false - iTerm: installed! - Hyper: application is not present. - Visual Studio Code: installed! - Docker: false

mschrage commented 2 years ago

Hey @derkan! Can you run echo $__CFBundleIdentifier in your GoLand terminal? Also what version of GoLand are you using?

Coffee0127 commented 2 years ago

@derkan have you installed plugin yet?

image

(👆 take PhpStorm for example, in your case, you could just install the plugin for GoLand)

After installing plugin and restart the IDE, problem solved.

mschrage commented 2 years ago

Hey @derkan! Did you also run into this issue (or are you just speculating on a potential solution)?

derkan commented 2 years ago

Yes, I've already installed Goland plugin. When running inside Goland Teminal fig is trying to access non-existent path "/Content/..." at root

xpader commented 2 years ago

Same issue for me even enable integration.

mschrage commented 2 years ago

Hey @derkan and @xpader can you run mdfind kMDItemCFBundleIdentifier = $__CFBundleIdentifier inside of the terminal where this issue is happening?

Can you also share the output of echo $__CFBundleIdentifier?

xpader commented 2 years ago

@mschrage mdfind kMDItemCFBundleIdentifier = $__CFBundleIdentifier output nothing, echo $__CFBundleIdentifier output com.jetbrains.PhpStorm.

mschrage commented 2 years ago

@xpader so that is the issue. We use the output of the mdfind command to locate the JetBrains application bundle. When I run this command on my machine, I get a path.

How did you install PhpStorm?

xpader commented 2 years ago

@mschrage Download the dmg file from official website. Although these things are output, the functions still work properly.

mschrage commented 2 years ago

Can you run ls /Applications and share the output here?

xpader commented 2 years ago

@mschrage

~ ls /Applications
ApiPost6.app                    Microsoft Edge.app              TencentMeeting.app
BaiduNetdisk_mac.app            Microsoft To Do.app             ToDesk.app
Charles.app                     Nextcloud.app                   Turbo Boost Switcher Pro.app
CleanMyMac X.app                PhpStorm.app                    Utilities
Clipy.app                       Postman.app                     V2rayU.app
CrossOver.app                   Proxifier.app                   VLC.app
Fig.app                         QQ.app                          VMware Fusion.app
FileZilla.app                   QQMusic.app                     VNC Viewer.app
Firefox.app                     RDM.app                         Visual Studio Code.app
Google Chrome.app               Safari.app                      WeChat.app
HBuilderX.app                   Scroll Reverser.app             aDrive.app
Hackintool.app                  Sensei.app                      iStat Menus.app
Intel Power Gadget              ServerCat.app                   tbswitcher_resources
Karabiner-Elements.app          SiteSucker Pro.app              wechatwebdevtools.app
Karabiner-EventViewer.app       TablePlus.app                   wpsoffice.app
MailMaster.app                  Telegram.app
yasinzaehringer-paradime commented 2 years ago

Got a similar issue right now - my ~/.zshrc includes~/.fig/shell/zshrc.pre.zsh which evals this command:

% ~/.local/bin/fig init zsh pre --rcfile zshrc
[snip]
if [ -z "${FIG_JETBRAINS_SHELL_INTEGRATION}" ]; then
  FIG_JETBRAINS_SHELL_INTEGRATION=1
  source '/Contents/plugins/terminal/.zshenv'
fi

but this file isn't there:

% cat /Contents/plugins/terminal/.zshenv
cat: /Contents/plugins/terminal/.zshenv: No such file or directory

I cannot create a file in Contents since it's a read-only filesystem.

mschrage commented 2 years ago

Which Jetbrains IDE does this error message appear in?

neoighodaro commented 2 years ago

Screenshot 2022-08-11 at 23 02 27

Sorry to piggyback, I also get the same issue on VSCode

etcook commented 2 years ago

I'm getting this issue out of nowhere with IntelliJ, now. Has been working fine for months.

mschrage commented 2 years ago

Hmm thanks for reporting @etcook @neoighodaro

Can you both run env in the effected terminal session and share the output?

etcook commented 2 years ago

COMMAND_MODE=unix2003 FIG_INTEGRATION_VERSION=8 FIG_TERM=1 FIG_TERM_VERSION=5.1.0 HOME=*** JEDITERM_SOURCE=*** LC_CTYPE=en_US.UTF-8 LOGIN_SHELL=1 LOGNAME=*** OLDPWD=*** PATH=*** PWD=*** RUBY_VERSION_MANAGER_DISTRIBUTION_ID=2.7.5 RUBY_VERSION_MANAGER_PATH=*** SHELL=/bin/zsh SHLVL=1 SSH_AUTH_SOCK=/private/tmp/com.apple.launchd.O34cGraFxa/Listeners TERM=xterm-256color TERMINAL_EMULATOR=JetBrains-JediTerm TERM_SESSION_ID=03376003-0fd0-4296-a9ad-cd46309e6a37 TMPDIR=/var/folders/t7/g5wcw7750f70_q9dxzn312240000gn/T/ USER=*** XPC_FLAGS=0x0 XPC_SERVICE_NAME=0 __CFBundleIdentifier=com.jetbrains.intellij __CF_USER_TEXT_ENCODING=0x1F5:0x0:0x0 __INTELLIJ_COMMAND_HISTFILE__=*** HOMEBREW_PREFIX=/opt/homebrew HOMEBREW_CELLAR=/opt/homebrew/Cellar HOMEBREW_REPOSITORY=/opt/homebrew MANPATH=/opt/homebrew/share/man:: INFOPATH=/opt/homebrew/share/info: TTY=/dev/ttys005 FIG_PID=10537 ARCHFLAGS=-arch arm64 DEFAULT_USER=*** HIX_ON_RAILS_ACCESS_KEY=*** LDFLAGS=-L/opt/homebrew/opt/libpq/lib CPPFLAGS=-I/opt/homebrew/opt/libpq/include PKG_CONFIG_PATH=/opt/homebrew/opt/libpq/lib/pkgconfig ASDF_DIR=*** _=/usr/bin/env

I censored out some private information with ***

mschrage commented 2 years ago

How did you install the JetBrains IDE? Did you use Toolbox by chance?

etcook commented 2 years ago

@mschrage yes, I've always installed it via toolbox.

kuhnroyal commented 2 years ago

Same issue since I started using fig a couple month back. IntelliJ is also installed via Toolbox.

timengel commented 2 years ago

I get the same message in WebStorm 2022.1.4, not installed via toolbox. The WebStorm plugin is installed and fig works as intended (afaik) but the message is annoying. It started showing up after reinstalling WebStorm. (eval):source:94: no such file or directory: /Contents/plugins/terminal/.zshenv

mschrage commented 2 years ago

What's happening here is that Fig attempts to located the location of the application bundle associated with a bundle identifier (eg. com.jetbrains.intellij.ce -> /Applications/Intellij.app).

Internally, we use the following shell command mdfind kMDItemCFBundleIdentifier = com.jetbrains.intellij.ce to determine the location.

This error message is printed in cases where the output of this command is empty. I can suppress the error by confirming that the file path is valid, but that will mask the underlying issue. #1069 #1038

ohaddahan commented 1 year ago

The end of ~/.local/bin/fig init zsh pre --rcfile zshrc has:

if [ -z "${FIG_JETBRAINS_SHELL_INTEGRATION}" ]; then
  FIG_JETBRAINS_SHELL_INTEGRATION=1
  source '/Contents/plugins/terminal/.zshenv'
fi

Anyway I can fix locally? Didn't find any script it's coming from.

yuzhanglong commented 1 year ago

same problem! Has anyone solved it?

mschrage commented 1 year ago

@yuzhanglong did you also install via Toolbox? Can you run mdfind kMDItemCFBundleIdentifier = com.jetbrains.intellij.ce or whatever the bundle dd is for your JetBrains IDE?

yuzhanglong commented 1 year ago

@yuzhanglong did you also install via Toolbox? Can you run mdfind kMDItemCFBundleIdentifier = com.jetbrains.intellij.ce or whatever the bundle dd is for your JetBrains IDE?

The problem suddenly disappeared that day, and now everything is good 😄

kuhnroyal commented 1 year ago

Installed with Toolbox:

❯ echo $__CFBundleIdentifier
com.jetbrains.intellij
❯ mdfind kMDItemCFBundleIdentifier = com.jetbrains.intellij

The mdfind kMDItemCFBundleIdentifier = com.jetbrains.intellij doesn't return anything.

Evisolpxe commented 1 year ago

same issues

MichaelHao25 commented 1 year ago
image
wimdeblauwe commented 1 year ago

I have the same issue with IntelliJ, not installed via Toolbox. Any workaround?

kuhnroyal commented 1 year ago

I think this happens after IntelliJ up/downgrades. Everything was fine for me on a fresh system using IntelliJ EAP, now after the update to Beta, I have this error again. The IntelliJ application path was changed.

KostasDimakis commented 1 year ago

I upgraded both Fig and my Jetbrains IDEs last night. I started seeing this issue.

JasonkayZK commented 1 year ago

Same here! I got this issue, after i upgraded the Jetbrains IDEs!

kuhnroyal commented 1 year ago

I wonder if Jetbrains products don't copy/move hidden files in plugin folders when upgrading between versions.

etcook commented 1 year ago

@mschrage The issue is that the file is now down one directory in /zsh, so in the example above, although it can't be found in /Contents/plugins/terminal/.zshenv it's actually in /Contents/plugins/terminal/zsh/.zshenv

tkm5 commented 1 year ago

I also got the same error after updating to pycharm 2023.1 (eval):source:87: no such file or directory: /Applications/PyCharm.app/Contents/plugins/terminal/.zshenv

image

Darkvar commented 1 year ago

Fixed for me by copying .zshenv file 1 folder lvl up. cp .zshenv ../

CharleeWa commented 1 year ago

I also encountered this problem, and I can't automatically enter the independent python runtime environment after opening the editor, I wonder if this is also a fig problem.

pfcodes commented 1 year ago

This just started happening to me today too

HytonightYX commented 1 year ago

too

RomainCrz commented 1 year ago

Same error here

anubhavsharma515 commented 1 year ago

Same error here :(

TomDeSmet commented 1 year ago

Same error since upgrading to PHPStorm 2023.1, also using Toolbox.

etcook commented 1 year ago

I'm sure this will be fixed eventually, but until then, it's easy to create a symbolic link to the original file that will bridge it.

Go into the directory of the error and use the following

ln -s zsh/.zshenv .

adjaythakoerdien commented 1 year ago

Same here since last week.. :-( I'v also installed PyCharm with the Toolbox and also use Fig..

adjaythakoerdien commented 1 year ago

I've rolled back PyCharm to version 2022.3.3 and everything went back to normal :-)

Bayramito commented 1 year ago

ln -s zsh/.zshenv .

This one fixed my issue with WebStorm latest thank you

davidteren commented 1 year ago

I'm sure this will be fixed eventually, but until then, it's easy to create a symbolic link to the original file that will bridge it.

Go into the directory of the error and use the following

ln -s zsh/.zshenv .

Thanks. Can confirm this works.

Setup a new MacBook with both latest RubyMine and Fig and into this issue. @etcook's solution solved it.

sdet-node-js-dev commented 1 year ago

I was also facing the same issue, turns out it's because of Fig. The Fig stopped working on my machine and that led to this CLI error for WebStorm. When I uninstalled Fig, suddenly the error was also gone.

naimbh commented 1 year ago

Simple solution:

cd /Applications/PhpStorm.app/Contents/plugins/terminal touch .zshenv