Arduino: permission denied on 2.5.0beta

Created on 12 Dec 2018  Â·  14Comments  Â·  Source: esp8266/Arduino

Basic Infos

  • [ x] This issue complies with the issue POLICY doc.
  • [x ] I have read the documentation at readthedocs and the issue is not addressed there.
  • [x ] I have tested that the issue is present in current master branch (aka latest git).
  • [x ] I have searched the issue tracker for a similar issue.
  • [x ] If there is a stack dump, I have decoded it.
  • [ x] I have filled out all fields below.

Platform

  • Hardware: [ESP-12|]
  • Core Version: [latest git hash or date]
  • Development Env: [Arduino IDE]
  • Operating System: [Ubuntu]

Settings in IDE

  • Module: [Generic ESP8266 Module|Wemos D1 mini r2|Nodemcu|other]
  • Flash Mode: [qio|dio|other]
  • Flash Size: [1MB]
  • lwip Variant: [v1.4]
  • Reset Method: [nodemcu]
  • Flash Frequency: [40Mhz]
  • CPU Frequency: [80Mhz]
  • Upload Using: [SERIAL]
  • Upload Speed: [115200|other] (serial upload only)

Problem Description

Detailed problem description goes here.

When compiling any code, I get a permission denied error like so
.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py: permission denied
Permisions for that folder looked fine, but I even did a chmod 777 on the entire directory to see if that would change anything, it did not.

This is with the latest beta version of the board info (2.5.0beta)
When I downgrade it to the previous version, it works fine.

Debug Messages

Debug messages go here

.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py: permission denied

packaging bug

Most helpful comment

Samer problem here on OSX (Mojave), will try suggestions and revert.

Install was done via board manager.

UPDATE: Solved by issuing command:

chmod u+rwx /Users/xxx/Library/Arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py

All 14 comments

Looks like a paranoid system configuration. Can you give the full OS config?

I'm assuming you're running from a Linux/UNIX-like system, yes? And there is a "~/" before the ".arduino15" that you've not copied? If not, then maybe your Arduino copy is having trouble with $(HOME)

From a bash prompt, please try
python ~/.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py

.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py

Both should give some form of "ERROR: Mode not specified..." message.

If they don't, then could you have the Arduino tree on a filesystem mounted as NOEXEC (so that nothing can run from it?). Another possibility is a SELINUX enforcing mode config that doesn't allow executing the file.

Samer problem here on OSX (Mojave), will try suggestions and revert.

Install was done via board manager.

UPDATE: Solved by issuing command:

chmod u+rwx /Users/xxx/Library/Arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py

Correct on linux, ubuntu 18.04And the path was fully qualified, I just removed the /home/user
I had tried running the command direct from the command line and it does give me the mode not specified message, so there is something about it being called from the ide that's messing with things 

Sent from my Verizon, Samsung Galaxy smartphone
-------- Original message --------From: "Earle F. Philhower, III" notifications@github.com Date: 12/11/18 21:29 (GMT-08:00) To: esp8266/Arduino Arduino@noreply.github.com Cc: Chad Gibeaut chad.gibeaut@gmail.com, Author author@noreply.github.com Subject: Re: [esp8266/Arduino] permission denied on 2.5.0beta (#5483)
Looks like a paranoid system configuration. Can you give the full OS config?
I'm assuming you're running from a Linux/UNIX-like system, yes? And there is a "~/" before the ".arduino15" that you've not copied? If not, then maybe your Arduino copy is having trouble with $(HOME)
From a bash prompt, please try

python ~/.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py
.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py
Both should give some form of "ERROR: Mode not specified..." message.
If they don't, then could you have the Arduino tree on a filesystem mounted as NOEXEC (so that nothing can run from it?). Another possibility is a SELINUX enforcing mode config that doesn't allow executing the file.

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/esp8266/Arduino","title":"esp8266/Arduino","subtitle":"GitHub repository","main_image_url":"https://assets-cdn.github.com/images/email/message_cards/header.png","avatar_image_url":"https://assets-cdn.github.com/images/email/message_cards/avatar.png","action":{"name":"Open in GitHub","url":"https://github.com/esp8266/Arduino"}},"updates":{"snippets":[{"icon":"PERSON","message":"@earlephilhower in #5483: Looks like a paranoid system configuration. Can you give the full OS config?\r\n\r\nI'm assuming you're running from a Linux/UNIX-like system, yes? And there is a \"~/\" before the \".arduino15\" that you've not copied? If not, then maybe your Arduino copy is having trouble with $(HOME)\r\n\r\nFrom a bash prompt, please try\r\npython ~/.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py\r\n\r\n.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py\r\n\r\nBoth should give some form of \"ERROR: Mode not specified...\" message.\r\n\r\nIf they don't, then could you have the Arduino tree on a filesystem mounted as NOEXEC (so that nothing can run from it?). Another possibility is a SELINUX enforcing mode config that doesn't allow executing the file."}],"action":{"name":"View Issue","url":"https://github.com/esp8266/Arduino/issues/5483#issuecomment-446466998"}}}
[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/esp8266/Arduino/issues/5483#issuecomment-446466998",
"url": "https://github.com/esp8266/Arduino/issues/5483#issuecomment-446466998",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]

Samer problem here on OSX (Mojave), will try suggestions and revert.

Install was done via board manager.

UPDATE: Solved by issuing command:

chmod u+rwx /Users/xxx/Library/Arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py

Worked like a charm :)

Same thing on Mac OS High Sierra and the suggested command in the terminal worked perfectly. Thanks @Swiftnesses

Welcome guys, glad I could help :)

Yup, looks like there is a packaging issue in the IDE installed package. Deleting my GIT copy and using the boards manager to install 2.5.0-b1 I too see:
````
fork/exec /home/earle/.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py: permission denied
Error compiling for board LOLIN(WEMOS) D1 R2 & mini.

ls -l /home/earle/.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py

-rw-rw-r-- 1 earle earle 2832 Dec 11 15:25 /home/earle/.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py
````

The GIT version itself has the +x bit set on the file, so I'll have to peek at our packing script...

image

Actually, it;s even worse. The packaged platform.txt is missing many lines vs. the GIT repo!
````
earle@server:~/.arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/git/Arduino$ git diff
diff --git a/platform.txt b/platform.txt
index 30eece5..6a42b8e 100644
--- a/platform.txt
+++ b/platform.txt
@@ -5,11 +5,11 @@
# For more info:
# https://github.com/arduino/Arduino/wiki/Arduino-IDE-1.5---3rd-party-Hardware-specification

-name=ESP8266 Boards (2.5.0-dev)
-version=2.5.0-dev
+name=ESP8266 Boards (2.5.0-beta1)
+version=2.5.0-beta1
+
+

-runtime.tools.xtensa-lx106-elf-gcc.path={runtime.platform.path}/tools/xtensa-lx106-elf
-runtime.tools.esptool.path={runtime.platform.path}/tools/esptool
runtime.tools.signing={runtime.platform.path}/tools/signing.py

compiler.warning_flags=-w
@@ -76,14 +76,14 @@ compiler.elf2hex.extra_flags=

## generate file with git version number
## needs bash, git, and echo
-recipe.hooks.core.prebuild.1.pattern=bash -c "mkdir -p {build.path}/core && echo #define ARDUINO_ESP8266_GIT_VER 0xgit --git-dir {runtime.platform.path}/.git rev-parse --short=8 HEAD 2>/dev/null || echo ffffffff >{build.path}/core/core_version.h"
-recipe.hooks.core.prebuild.2.pattern=bash -c "mkdir -p {build.path}/core && echo #define ARDUINO_ESP8266_GIT_DESC cd "{runtime.platform.path}"; git describe --tags 2>/dev/null || echo unix-{version} >>{build.path}/core/core_version.h"
-recipe.hooks.core.prebuild.3.pattern="{runtime.tools.signing}" --mode header --publickey "{build.source.path}/public.key" --out "{build.path}/core/Updater_Signing.h"
+
+
+

## windows-compatible version without git
-recipe.hooks.core.prebuild.1.pattern.windows=cmd.exe /c mkdir {build.path}\core & (echo #define ARDUINO_ESP8266_GIT_VER 0x00000000 & echo #define ARDUINO_ESP8266_GIT_DESC win-{version} ) > {build.path}\core\core_version.h
-recipe.hooks.core.prebuild.2.pattern.windows=cmd.exe /c if exist {build.source.path}\public.key echo #error Cannot automatically build signed binaries on Windows > {build.path}\core\Updater_Signing.h
-recipe.hooks.core.prebuild.3.pattern.windows=
+
+
+

## Build the app.ld linker file
recipe.hooks.linking.prelink.1.pattern="{compiler.path}{compiler.c.cmd}" -CC -E -P {build.vtable_flags} "{runtime.platform.path}/tools/sdk/ld/eagle.app.v6.common.ld.h" -o "{build.path}/local.eagle.app.v6.common.ld"
@@ -130,7 +130,7 @@ recipe.size.regex.data=^(?:.data|.rodata|.bss)\s+([0-9]+).*

tools.esptool.cmd=esptool
tools.esptool.cmd.windows=esptool.exe
-tools.esptool.path={runtime.platform.path}/tools/esptool
+tools.esptool.path={runtime.tools.esptool.path}
tools.esptool.network_cmd=python
tools.esptool.network_cmd.windows=python.exe

@@ -142,4 +142,4 @@ tools.esptool.upload.network_pattern="{network_cmd}" "{runtime.platform.path}/to

tools.mkspiffs.cmd=mkspiffs
tools.mkspiffs.cmd.windows=mkspiffs.exe
-tools.mkspiffs.path={runtime.platform.path}/tools/mkspiffs
+tools.mkspiffs.path={runtime.tools.mkspiffs.path}
````

Still actual

hack to fix (more general solution than @Swiftnesses's):

chmod u+rwx $HOME/Library/Arduino15/packages/esp8266/hardware/esp8266/2.5.0-beta1/tools/signing.py

Until -beta2 is released this is not going to show up ini tour board-manager installs.

However, the fix doesn't actually amke signing work. The platform.txt file needs to be corrected, which is that the PR does and you'll get with the next beta.

Why beta versions available in stable update channel?

@a-x- I suggest reading our release model.

  1. It's a release channel, not a "stable" release channel.
  2. The term "stable release" usually refers to the head of a version branch, where the branch base is the base release, and commits after that are only bug fixes. Hence, releases from that branch are usualy progressivley stable. We don't follow that release model, as explained in the link above. That means we don't do "stable" releases, we just do releases.
  3. Beta releases require wide testing (that's actually true of all releases, but betas more so). Wide testing requires exposure to users. Exposure to users means the release must be made available through all channels.
  4. The fact that the release version explicitly says "beta" should be enough for users to expect some issues. It's up to each user to decide installing, testing, reporting issues, and helping out with fixing them.

I have spend a few day with different versions old and new, any kind of config none of working.

Why this that happen with esp-01 since i have remember off and on bump with uploading code we got error: espcomm_open failed.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Marcelphilippeandrade picture Marcelphilippeandrade  Â·  3Comments

eliabieri picture eliabieri  Â·  3Comments

hoacvxd picture hoacvxd  Â·  3Comments

tttapa picture tttapa  Â·  3Comments

horendus picture horendus  Â·  3Comments