Score:0

E: Re-installation of package `st-stlink-udev-rules` is required, but the required archive file cannot be found

in flag

I just started using Ubuntu and I got an error like this after downloading a program. I can't fix this error. I can't update or when I want to do any download I am getting this:

Reading package lists... Done
Creating dependency tree... Done
Reading status info... Done
E: The package st-stlink-udev-rules needs to be reinstalled, but the required archive file cannot be found. 

I think I also corrupted the sources.list file while trying to fix this. I need to install a few programs but I can't download anything including updates. Also I don't know how to download the st-stlink-udev-rules package. Since I am in the middle of a very important job, I need to fix this error without reinstalling the system.

pLumo avatar
in flag
Welcome to askubuntu. (1) This is an English speaking community. If you don't speak English, you can use an online translater. (2) Please don't add screenshots of textual output. Rather paste the text and format it as code.
FedKad avatar
cn flag
Since you are new Ubuntu user, I would recommend a complete re-install. Please, backup any important documents and other files to a USB drive and re-install Ubuntu.
pLumo avatar
in flag
See [How do I restore the default repositories?](https://askubuntu.com/questions/124017/how-do-i-restore-the-default-repositories)
Buket avatar
in flag
Nothing has changed.
N0rbert avatar
zw flag
Please run `grep -r "^deb " /etc/apt/ --include="*.list"` and upload output to pastebin. The `st-stlink-udev-rules` packages was probably installed for STM32 microcontrollers. Do you plan to use them in near future?
Buket avatar
in flag
Yes I encountered this error after downloading and deleting STM32Cube and I don't plan to use it anytime soon. Output: `/etc/apt/sources.list:deb http://tr.archive.ubuntu.com/ubuntu/ hirsute main universe`
Score:0
in flag

I fixed with this command:

sudo dpkg --remove --force-remove-reinstreq st-stlink-udev-rules
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.