Upload Error > Could not find one of 'package.json' manifest files in the package

Dear Community,

I am facing an error I am not able to solve for a few days already. Can somone shed some light please?

I am trying to upload a program to my WeMos D1 Mini via Platformio.

my pfatformio.ini file:

[env:d1_mini]
platform = espressif8266@2.6.3
board = d1_mini
framework = arduino
board_build.filesystem = littlefs
board_build.ldscript = eagle.flash.1m256.ld
upload_port = COM4
upload_speed = 115200
platform_packages =
   framework-arduinoespressif8266 @ https://github.com/esp8266/Arduino/releases/download/2.6.3/esp8266-2.6.3.zip

My project seems to build all right,

Processing d1_mini (platform: espressif8266@2.6.3; board: d1_mini; framework: arduino)
-----------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif8266/d1_mini.html
PLATFORM: Espressif 8266 (2.6.3) > WeMos D1 R2 and mini
HARDWARE: ESP8266 80MHz, 80KB RAM, 4MB Flash
PACKAGES:
 - framework-arduinoespressif8266 @ 2.6.3
 - tool-esptool @ 1.413.0 (4.13)
 - tool-esptoolpy @ 1.30000.201119 (3.0.0) 
 - toolchain-xtensa @ 2.40802.200502 (4.8.2)
LDF: Library Dependency Finder -> https://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 29 compatible libraries
Scanning dependencies...
No dependencies
Building in release mode
Retrieving maximum program size .pio\build\d1_mini\firmware.elf
Checking size .pio\build\d1_mini\firmware.elf
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM:   [===       ]  32.7% (used 26772 bytes from 81920 bytes)
Flash: [===       ]  33.6% (used 255680 bytes from 761840 bytes)

The problematic part is the error I am getting when trying to run the Upload Command

I am getting following error:

Processing d1_mini (platform: espressif8266@2.6.3; board: d1_mini; framework: arduino)   
Error: Could not find one of 'package.json' manifest files in the package

Maybe someone out there knows what is wrong.

Thank you

Why these two older versions? Which Arduino-ESP8266 core version do you want to use, and which platform-espressif8266 version (which are two completely different entities)?

I think I would like to use 2.6.3.

The reason why to use older version is that I am trying to build a water valve control system and I need to use TimedAction and ArduinoIOT Cloud libraries. There was some clash with the newest version so I decided to use an older version.

The platform-espressif8266 version that uses Arduino-ESP8266 core 2.6.3 is

platform = espressif8266@2.3.2

does that work better?

Unfortunately no, I have simplified the ini file to this:

[env:d1_mini]
platform = espressif8266@2.3.2
board = d1_mini
framework = arduino
board_build.filesystem = littlefs
board_build.ldscript = eagle.flash.1m256.ld
upload_port = COM4
upload_speed = 115200

Build was success
PACKAGES:

  • framework-arduinoespressif8266 @ 2.20603.191216 (2.6.3)
  • tool-esptool @ 1.413.0 (4.13)
  • tool-esptoolpy @ 1.20800.0 (2.8.0)
  • toolchain-xtensa @ 2.40802.200502 (4.8.2)

Upload failed. Same error:
Error: Could not find one of ‘package.json’ manifest files in the package

Thank you

Works just fine on my computer.

Maybe you have a corrupted download / package. Remove all folders in C:\Users\<user>\.platformio\packages\ and C:\Users\<user>\.platformio\.cache, then re-upload the project.

3 Likes

it worked!!! Thank you

thank you, it’s work.

After installing the extension in VS CODE it brought up the error while trying to create a new project, as a last resort, I installed the previous version and configured a new project in the default directory, but for some reason, it won’t accept a custom directory.

Please open a new topic with your exact platformio.ini and error message.