pioarduino/platform-espressif32

Problem with new platform package

Closed this issue ยท 18 comments

PROBLEM DESCRIPTION

Getting an error with new platform

Resolving alpha3Dev dependencies...
Platform Manager: Installing https://github.com/pioarduino/platform-espressif32/releases/download/55.03.30/platform-espressif32.zip
Downloading 0% 10% 20% 30% 40% 50% 60% 70% 80% 90% 100%
Unpacking 0% 10% 20% 30% 40% 50% 60% 70% 80% 90% 100%
Platform Manager: espressif32@55.3.30 has been installed!
MissingPackageManifestError: Could not find one of 'package.json' manifest files in the package

Everything was fine with

platform = https://github.com/pioarduino/platform-espressif32/releases/download/54.03.20/platform-espressif32.zip

but breaks with newer versions
platform = https://github.com/pioarduino/platform-espressif32/releases/download/55.03.30/platform-espressif32.zip

or

TO REPRODUCE

Steps to reproduce the behavior:
Switch to new package

EXPECTED BEHAVIOUR

A clear and concise description of what you expected to happen.

Able to buile

SCREENSHOTS

If applicable, add screenshots to help explain your problem.

ADDITIONAL CONTEXT

Add any other context about the problem here.

this is on window

(Please, remember to close the issue when the problem has been addressed)

Nearly no relevant Infos. Which OS, what have been tried? platformio.ini? Project example?

I can generate a smaller project if you have some details on what could cause this.

I do say it is on Windows.

; PlatformIO Project Configuration File
;
;   Build options: build flags, source filter
;   Upload options: custom upload port, speed and extra flags
;   Library options: dependencies, extra library storages
;   Advanced options: extra scripting
;
; Please visit documentation for the other options and examples
; https://docs.platformio.org/page/projectconf.html

[platformio]
include_dir = src
boards_dir = boards

[env]
; monitor_filters = default, esp32_exception_decoder, colorize
monitor_raw = yes
platform = https://github.com/pioarduino/platform-espressif32/releases/download/55.03.30-1/platform-espressif32.zip
framework = arduino, espidf

[env:board]
board = esp32dev
upload_speed = 460800

There error is early enough that it doesn't really matter what is in my platformio other than that platform item, so I didn't feel it was relevant

All examples do work in CI with Linux, Windows and MacOS. There is no general issue.
You have to provide a setup which shows a problem. Without a reproducable issue nothing can be done.

Ok are there any hints on how to reproduce this?

This is literally the minimum set up I can think of and it doesn't work, I don't know how to make this reproducible or debug this any further, it is just not finding this package.json and is unable to build

What setup has changed between these two versions? Am I even opening a bug in the right place?

I have exhausted all possible knowledge I have on this, and something is wrong after updating this.

Can you share where the test run information is, so I can figure out why my set up may be different?

Ok I went went into the \examples\espidf-arduino-blink and just changed the platform to

platform = https://github.com/pioarduino/platform-espressif32/releases/download/55.03.30/platform-espressif32.zip

And it reproes

On windows 10 Pro

Platform IO last updated
2025-05-28, 09:14:59

Vscode 1.89

Let me know what other information I can provide

The test does this

Platform Manager: Installing file://.
Platform Manager: espressif32@55.3.30 has been installed!

So it is not 1:1 as it is not actually downloading the generated platform zip.

What's wrong? It has installed the platform.

That wat not my logs, that was from the test. That was me explaining that the test wasn't doing the same thing

I get

MissingPackageManifestError: Could not find one of 'package.json' manifest files in the package

With the \examples\espidf-arduino-blink and just changed the platform to

platform = https://github.com/pioarduino/platform-espressif32/releases/download/55.03.30/platform-espressif32.zip

I have the exact same problem!

  • OS: Windows 11 Pro
  • Platformio Version: 6.1.18
  • Vscode Version: 1.102.3

My Platformio.ini file:

[env:stable]
platform = https://github.com/pioarduino/platform-espressif32/releases/download/55.03.30/platform-espressif32.zip
board = esp32dev
framework = Arduino

Error:

Resolving stable dependencies...
MissingPackageManifestError: Could not find one of 'package.json' manifest files in the package

The same problem

Please try #241 :

platform = https://github.com/pioarduino/platform-espressif32.git#win_test

if this does not help or solve the issues you see, i dont have any idea left why it is not working for some Windows users. All CI test do run without any problems for Windows, MacOS and Linux

It still happens.

It does seem to just get stuck while installing something initially, I'm really unsure of how this happens.

I will point out again though that your test doesn't actually download the zip and install anything, it is just using the local code. Maybe add a test that downloads the actual generated zip files? And maybe make sure that there aren't any special steps/setup in the testing infrastructure.

Again, i cant test with Windows. I dont have any Windows capable PC / Laptop. It is working in general. Have feedback from some Windows testers which have no issues at all. To be clear i cant solve what i cant reproduce.

Do you have any details about why this one would break but the previous version would not?

What has changed in the setup of this?

What package.json is it even looking for?

Is there something I should look for in the downloaded package that may be missing?

Is there any way to get more information that would help debug this?

I'm not asking to just have you solve it, but this is a real problem, and would love some help figuring out what could be going wrong

A lot has changed. The complete install process. Moved away from Platformio registry and uses a own installer (slightly modified espressif idf installer) and all stuff is fetched from github. Sorry there are changes nearly everywhere and most tools have been updated. The jump from esptool v4.9.x to v5.x needed major changes too. There is no simple change everything relies on each other.
The espressif32 Platform is probably the most sophisticated from all Platformio Platforms
pioarduino is not comparable to the old original Platformio version. It is a new version. how it all works together is described here https://deepwiki.com/pioarduino/platform-espressif32

Ok tried for like the 10th time and got a different result

Tool Manager: Error: Please read https://bit.ly/package-manager-ioerror
ReadTimeout: Traceback (most recent call last):
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\connectionpool.py", line 464, in _make_request
    self._validate_conn(conn)
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\connectionpool.py", line 1093, in _validate_conn
    conn.connect()
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\connection.py", line 741, in connect
    sock_and_verified = _ssl_wrap_socket_and_match_hostname(
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\connection.py", line 920, in _ssl_wrap_socket_and_match_hostname
    ssl_sock = ssl_wrap_socket(
               ^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\util\ssl_.py", line 480, in ssl_wrap_socket
    ssl_sock = _ssl_wrap_socket_impl(sock, context, tls_in_tls, server_hostname)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\util\ssl_.py", line 524, in _ssl_wrap_socket_impl
    return ssl_context.wrap_socket(sock, server_hostname=server_hostname)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\python3\Lib\ssl.py", line 517, in wrap_socket
    return self.sslsocket_class._create(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\python3\Lib\ssl.py", line 1108, in _create
    self.do_handshake()
  File "C:\Users\schla\.platformio\python3\Lib\ssl.py", line 1383, in do_handshake
    self._sslobj.do_handshake()
TimeoutError: _ssl.c:989: The handshake operation timed out

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\requests\adapters.py", line 667, in send
    resp = conn.urlopen(
           ^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\connectionpool.py", line 841, in urlopen
    retries = retries.increment(
              ^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\util\retry.py", line 474, in increment
    raise reraise(type(error), error, _stacktrace)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\util\util.py", line 39, in reraise
    raise value
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\connectionpool.py", line 787, in urlopen
    response = self._make_request(
               ^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\connectionpool.py", line 488, in _make_request
    raise new_e
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\connectionpool.py", line 466, in _make_request
    self._raise_timeout(err=e, url=url, timeout_value=conn.timeout)
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\urllib3\connectionpool.py", line 367, in _raise_timeout
    raise ReadTimeoutError(
urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='release-assets.githubusercontent.com', port=443): Read timed out. (read timeout=10)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\__main__.py", line 103, in main
    cli()  # pylint: disable=no-value-for-parameter
    ^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\click\core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\click\core.py", line 1078, in main
    rv = self.invoke(ctx)
         ^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\cli.py", line 85, in invoke
    return super().invoke(ctx)
           ^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\click\core.py", line 1688, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\click\core.py", line 1688, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\click\core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\click\core.py", line 783, in invoke
    return __callback(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\project\commands\init.py", line 106, in project_init_cmd
    install_project_dependencies(
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\package\commands\install.py", line 107, in install_project_dependencies
    already_up_to_date = not install_project_env_dependencies(env, options)
                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\package\commands\install.py", line 132, in install_project_env_dependencies
    _install_project_env_platform(project_env, options),
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\package\commands\install.py", line 149, in _install_project_env_platform
    PlatformPackageManager().install(
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\package\manager\platform.py", line 62, in install
    p.install_required_packages(force=force)
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\platform\_packages.py", line 76, in install_required_packages
    self.install_package(name, force=force)
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\platform\_packages.py", line 70, in install_package
    return self.pm.install(spec or self.get_package_spec(name), force=force)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\package\manager\_install.py", line 47, in install
    pkg = self._install(spec, skip_dependencies=skip_dependencies, force=force)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\package\manager\_install.py", line 97, in _install
    pkg = self.install_from_uri(spec.uri, spec)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\package\manager\_install.py", line 189, in install_from_uri
    dl_path = self.download(uri, checksum)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\package\manager\_download.py", line 88, in download
    raise exc
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\package\manager\_download.py", line 69, in download
    fd = FileDownloader(url)
         ^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\package\download.py", line 33, in __init__
    self._http_response = self._http_session.get(
                          ^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\requests\sessions.py", line 602, in get
    return self.request("GET", url, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\http.py", line 64, in request
    return super().request(
           ^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\requests\sessions.py", line 589, in request
    resp = self.send(prep, **send_kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\requests\sessions.py", line 724, in send
    history = [resp for resp in gen]
              ^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\requests\sessions.py", line 724, in <listcomp>
    history = [resp for resp in gen]
              ^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\requests\sessions.py", line 265, in resolve_redirects
    resp = self.send(
           ^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\requests\sessions.py", line 703, in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\requests\adapters.py", line 713, in send
    raise ReadTimeout(e, request=request)
requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='release-assets.githubusercontent.com', port=443): Read timed out. (read timeout=10)

============================================================


Then after restarted vscode


FileNotFoundError: [WinError 2] The system cannot find the file specified:
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\builder\main.py", line 173:
    env.SConscript("$BUILD_SCRIPT")
  File "C:\Users\schla\.platformio\packages\tool-scons\scons-local-4.8.1\SCons\Script\SConscript.py", line 620:
    return _SConscript(self.fs, *files, **subst_kw)
  File "C:\Users\schla\.platformio\packages\tool-scons\scons-local-4.8.1\SCons\Script\SConscript.py", line 280:
    exec(compile(scriptdata, scriptname, 'exec'), call_stack[-1].globals)
  File "C:\Users\schla\.platformio\platforms\espressif32@src-b9e7facf3f970c340e2515eee4d26ac6\builder\main.py", line 974:
    target_elf = env.BuildProgram()
  File "C:\Users\schla\.platformio\packages\tool-scons\scons-local-4.8.1\SCons\Util\envs.py", line 252:
    return self.method(*nargs, **kwargs)
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\builder\tools\piobuild.py", line 62:
    env.ProcessProgramDeps()
  File "C:\Users\schla\.platformio\packages\tool-scons\scons-local-4.8.1\SCons\Util\envs.py", line 252:
    return self.method(*nargs, **kwargs)
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\builder\tools\piobuild.py", line 142:
    env.BuildFrameworks(env.get("PIOFRAMEWORK"))
  File "C:\Users\schla\.platformio\packages\tool-scons\scons-local-4.8.1\SCons\Util\envs.py", line 252:
    return self.method(*nargs, **kwargs)
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\builder\tools\piobuild.py", line 352:
    SConscript(env.GetFrameworkScript(name), exports="env")
  File "C:\Users\schla\.platformio\packages\tool-scons\scons-local-4.8.1\SCons\Script\SConscript.py", line 684:
    return method(*args, **kw)
  File "C:\Users\schla\.platformio\packages\tool-scons\scons-local-4.8.1\SCons\Script\SConscript.py", line 620:
    return _SConscript(self.fs, *files, **subst_kw)
  File "C:\Users\schla\.platformio\packages\tool-scons\scons-local-4.8.1\SCons\Script\SConscript.py", line 280:
    exec(compile(scriptdata, scriptname, 'exec'), call_stack[-1].globals)
  File "C:\Users\schla\.platformio\platforms\espressif32@src-b9e7facf3f970c340e2515eee4d26ac6\builder\frameworks\espidf.py", line 1795:
    project_codemodel = get_cmake_code_model(
  File "C:\Users\schla\.platformio\platforms\espressif32@src-b9e7facf3f970c340e2515eee4d26ac6\builder\frameworks\espidf.py", line 490:
    run_cmake(src_dir, build_dir, extra_args)
  File "C:\Users\schla\.platformio\platforms\espressif32@src-b9e7facf3f970c340e2515eee4d26ac6\builder\frameworks\espidf.py", line 1092:
    run_tool(cmd)
  File "C:\Users\schla\.platformio\platforms\espressif32@src-b9e7facf3f970c340e2515eee4d26ac6\builder\frameworks\espidf.py", line 1047:
    result = exec_command(cmd, env=idf_env)
  File "C:\Users\schla\.platformio\penv\Lib\site-packages\platformio\proc.py", line 114:
    with subprocess.Popen(*args, **kwargs) as p:
  File "C:\Users\schla\.platformio\python3\Lib\subprocess.py", line 1026:
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "C:\Users\schla\.platformio\python3\Lib\subprocess.py", line 1538:
    hp, ht, pid, tid = _winapi.CreateProcess(executable, args,

It seems the issue is likely related to error handling and recovery.

It seems like if while stuff is going its fine, but any little hiccup and the setup just completely fails, and its just not possible to recover

Cant fix issues with very unreliable, bad and slow Internet connection, there are recovery routines implemented. Some install enhancements are done in https://github.com/pioarduino/platform-espressif32/releases/download/55.03.30-2/platform-espressif32.zip
use with

platform = https://github.com/pioarduino/platform-espressif32/releases/download/55.03.30-2/platform-espressif32.zip

I solved the issue!!!๐Ÿ˜ just deleting the entire .platformio folder from C:\Users\"your username"\ solved the problem!!
For me, it took 50minutes for platformio to reinstall all the components and then it just compiled my code!!!