Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when trying to save file - but it saves the file still #20

Open
IvoryJam opened this issue Jul 9, 2021 · 0 comments
Open

Error when trying to save file - but it saves the file still #20

IvoryJam opened this issue Jul 9, 2021 · 0 comments

Comments

@IvoryJam
Copy link

IvoryJam commented Jul 9, 2021

I get the following error when trying to save any go file

error: Traceback (most recent call last):
  File "/home/my_user/.config/sublime-text/Installed Packages/Gofmt.sublime-package/gofmt.py", line 257, in run_formatter
    formatter = Formatter(view)
  File "/home/my_user/.config/sublime-text/Installed Packages/Gofmt.sublime-package/gofmt.py", line 166, in __init__
    self.cmds = [Command(cmd, self.view, self.window) for cmd in cmds]
  File "/home/my_user/.config/sublime-text/Installed Packages/Gofmt.sublime-package/gofmt.py", line 166, in <listcomp>
    self.cmds = [Command(cmd, self.view, self.window) for cmd in cmds]
  File "/home/my_user/.config/sublime-text/Installed Packages/Gofmt.sublime-package/gofmt.py", line 77, in __init__
    self.window)
  File "/home/my_user/.config/sublime-text/Packages/golangconfig/all/golangconfig.py", line 197, in subprocess_info
    value, _ = setting_value(var_name, view=view, window=window)
  File "/home/my_user/.config/sublime-text/Packages/golangconfig/all/golangconfig.py", line 371, in setting_value
    raise e
golangconfig.GoPathNotFoundError: The GOPATH environment variable value "/home/my_user/.local/go
BASH_FUNC_which%%=() {  ( alias;
 eval ${which_declare} ) | /usr/bin/which --tty-only --read-alias --read-functions --show-tilde --show-dot "$@"
}" does not exist on the filesystem

Here's the weird thing though, I don't get the error if I leave my terminal's PS1 alone. I'm currently on Fedora 34 XFCE x11 and Sublime Text Build 4107

Here is my Gofmt.sublime-settings

{
  "cmds": [
    ["goimports", "-e"]
  ],
  "format_on_save": true
}

as for the BASH_FUNC_which function in the error, I have no idea where it's getting that from, that's not in my .bashrc

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

No branches or pull requests

1 participant