tenbaht / sduino

An Arduino-like programming API for the STM8
http://tenbaht.github.io/sduino/
GNU Lesser General Public License v2.1
355 stars 218 forks source link

Package install error: searching package root dir: no unique root dir in archive #150

Open EstevanTH opened 1 year ago

EstevanTH commented 1 year ago

Hey there,

I had an issue while installing the platform sduino:stm8, in any version (the current last version being 0.5).

Characteristics:

Installation failed with:

C:\Program Files\Arduino IDE\resources\app\node_modules\arduino-ide-extension\build>arduino-cli core install "sduino:stm8@0.5" --additional-urls "https://raw.githubusercontent.com/tenbaht/sduino/master/package_sduino_stm8_index.json"
Tool sduino:STM8Tools@2019.02.05 already installed
Tool sduino:sdcc@build.11242 already installed
Téléchargement des paquets...
sduino:stm8@0.5 sduino:stm8@0.5 déjà téléchargé
Installing platform sduino:stm8@0.5...
Error during install: Cannot install platform: installing platform sduino:stm8@0.5: searching package root dir: no unique root dir in archive, found 'C:\Users\xxx\AppData\Local\Arduino15\tmp\package-4125649767\STM8S_StdPeriph_Driver' and 'C:\Users\xxx\AppData\Local\Arduino15\tmp\package-4125649767\cores'

Opening the archive with 7-zip, I saw inside that the root directory inside of the tar archive is named .. This misled the installation procedure.

image

So I rebuilt the archive, putting all the content inside of a single root directory sduino-core-0.5. I modified my local package_sduino_stm8_index.json to make the size and the SHA-256 correspond with the new values. Hurray, it works!

image

C:\Program Files\Arduino IDE\resources\app\node_modules\arduino-ide-extension\build>arduino-cli core install "sduino:stm8@0.5" --additional-urls "package_sduino_stm8_index.json"
Tool sduino:STM8Tools@2019.02.05 already installed
Tool sduino:sdcc@build.11242 already installed
Téléchargement des paquets...
sduino:stm8@0.5 sduino:stm8@0.5 déjà téléchargé
Installing platform sduino:stm8@0.5...
Configuration de la plateforme....
Platform sduino:stm8@0.5 installed

Thank you!

Cheers ❤️

cintix commented 1 year ago

I have the same issue on both my OSX and Windows 11

mf0o commented 11 months ago

Thanks Estevan.

Facing the same issue on macOS and Arduino IDE 2.2.1. Thanks to your precise description I could replicate the fix fast and installed the package successfully.

Thank you a lot!

paturiaadarsh commented 4 months ago

Hey there,

I had an issue while installing the platform sduino:stm8, in any version (the current last version being 0.5).

Characteristics:

  • OS: Windows 11 x86-64
  • Arduino IDE 2.1.1

Installation failed with:

C:\Program Files\Arduino IDE\resources\app\node_modules\arduino-ide-extension\build>arduino-cli core install "sduino:stm8@0.5" --additional-urls "https://raw.githubusercontent.com/tenbaht/sduino/master/package_sduino_stm8_index.json"
Tool sduino:STM8Tools@2019.02.05 already installed
Tool sduino:sdcc@build.11242 already installed
Téléchargement des paquets...
sduino:stm8@0.5 sduino:stm8@0.5 déjà téléchargé
Installing platform sduino:stm8@0.5...
Error during install: Cannot install platform: installing platform sduino:stm8@0.5: searching package root dir: no unique root dir in archive, found 'C:\Users\xxx\AppData\Local\Arduino15\tmp\package-4125649767\STM8S_StdPeriph_Driver' and 'C:\Users\xxx\AppData\Local\Arduino15\tmp\package-4125649767\cores'

Opening the archive with 7-zip, I saw inside that the root directory inside of the tar archive is named .. This misled the installation procedure.

image

So I rebuilt the archive, putting all the content inside of a single root directory sduino-core-0.5. I modified my local package_sduino_stm8_index.json to make the size and the SHA-256 correspond with the new values. Hurray, it works!

image

C:\Program Files\Arduino IDE\resources\app\node_modules\arduino-ide-extension\build>arduino-cli core install "sduino:stm8@0.5" --additional-urls "package_sduino_stm8_index.json"
Tool sduino:STM8Tools@2019.02.05 already installed
Tool sduino:sdcc@build.11242 already installed
Téléchargement des paquets...
sduino:stm8@0.5 sduino:stm8@0.5 déjà téléchargé
Installing platform sduino:stm8@0.5...
Configuration de la plateforme....
Platform sduino:stm8@0.5 installed

Thank you!

Cheers ❤️

hey there, if u dont mind can u explain this thing breifly, i am having the same issue

Shoieb-Morad commented 1 month ago

Hey there, I had an issue while installing the platform sduino:stm8, in any version (the current last version being 0.5). Characteristics:

  • OS: Windows 11 x86-64
  • Arduino IDE 2.1.1

Installation failed with:

C:\Program Files\Arduino IDE\resources\app\node_modules\arduino-ide-extension\build>arduino-cli core install "sduino:stm8@0.5" --additional-urls "https://raw.githubusercontent.com/tenbaht/sduino/master/package_sduino_stm8_index.json"
Tool sduino:STM8Tools@2019.02.05 already installed
Tool sduino:sdcc@build.11242 already installed
Téléchargement des paquets...
sduino:stm8@0.5 sduino:stm8@0.5 déjà téléchargé
Installing platform sduino:stm8@0.5...
Error during install: Cannot install platform: installing platform sduino:stm8@0.5: searching package root dir: no unique root dir in archive, found 'C:\Users\xxx\AppData\Local\Arduino15\tmp\package-4125649767\STM8S_StdPeriph_Driver' and 'C:\Users\xxx\AppData\Local\Arduino15\tmp\package-4125649767\cores'

Opening the archive with 7-zip, I saw inside that the root directory inside of the tar archive is named .. This misled the installation procedure. image So I rebuilt the archive, putting all the content inside of a single root directory sduino-core-0.5. I modified my local package_sduino_stm8_index.json to make the size and the SHA-256 correspond with the new values. Hurray, it works! image

C:\Program Files\Arduino IDE\resources\app\node_modules\arduino-ide-extension\build>arduino-cli core install "sduino:stm8@0.5" --additional-urls "package_sduino_stm8_index.json"
Tool sduino:STM8Tools@2019.02.05 already installed
Tool sduino:sdcc@build.11242 already installed
Téléchargement des paquets...
sduino:stm8@0.5 sduino:stm8@0.5 déjà téléchargé
Installing platform sduino:stm8@0.5...
Configuration de la plateforme....
Platform sduino:stm8@0.5 installed

Thank you! Cheers ❤️

hey there, if u dont mind can u explain this thing breifly, i am having the same issue

did you solve the problem?