"pio returned non-zero exit status 1"
NotAFile opened this issue · comments
Usually that means that you just haven't ran
call SetupPlatformioEnvironment('/path/to/your/platformio/project/')
Is it possible that you might have missed that instruction in the readme?
That command is what caused the above error.
In that case, I'm afraid I have no direct insight to give you except that -- given that the command executes properly in your shell, but not from within vim -- that the environment in which vim is executing the command differs in some fundamental way.
You might be able to glean a little more information by altering this line: https://github.com/coddingtonbear/neomake-platformio/blob/master/rplugin/python/neomake-platformio.py#L23 to something like (untested):
proc = subprocess.Popen(
[
'pio',
'-f',
'-c',
'vim',
'run',
'-t',
'idedata',
'-d',
path,
],
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
)
_, stderr = proc.communicate()
raise Exception(stderr)
Making those changes will cause the actual error message to be reported to you as the reason the command failed.
Interesting, it seems I didn't have a trailing /
in my folder name. Perhaps "this is not a platformIO project" could be displayed a little more prettily.
The command runs without an error, but Neomake still does not recognize the platform libraries ("undeclared identifier" galore) so it might not actually be working though.
If you post a pull request for updating the output to be friendlier, I'd totally merge it. Actually -- if you want to own this project, I'd gladly transfer it to you: against ten or so years of inertia, I switched from vim to vscode a couple months back.
A transfer would mean breaking all existing Links, right?
I don't think I'll be doing much work on this either, only thing I could do is answer issues. Platformio has a fork of this project, perhaps they would be interested in ownership?
Interestingly enough -- links aren't broken when transferring github repositories (with some caveats), but I understand not wanting to take on that responsibility, anyway!