Malformed entry 1 in list file /etc/apt/sources.list.d/brave-browser-release-.list (Component)

Hi Brave Browser Community,

I am stuck in the following error whenever I try to work in ubuntu 18.1 terminal

E: Malformed entry 1 in list file /etc/apt/sources.list.d/brave-browser-release-.list (Component)

E: The list of sources could not be read.

E: Malformed entry 1 in list file /etc/apt/sources.list.d/brave-browser-release-.list (Component)

E: The list of sources could not be read.

What should I do?

I tried a solution in https://www.reddit.com/r/brave_browser/comments/aex31y/malformed_entry_1_in_list_file/
but it is showing the following error:

rm: cannot remove ‘/etc/apt/sources.list.d/brave-browser-dev-.list’: No such file or directory

Kindly help me out in this as I have a lot of stuff to install and work;

I am a newbie to tech and ubuntu?

1 Like

I solved this on ubuntu 18.04 by editing
#sudo nano /etc/apt/sources.list.d/brave-browser-release-.list

A.) change from:
deb [arch=amd64] https://brave-browser-apt-release.s3.brave.com/ main

[ !!! IF YOU COPY PASTE: Watch out the webpage will format links to:
http:link (NUMBER) main ,
if you copy paste remove the (NUMBER) ]

B.) change to:
deb [arch=amd64] https://brave-browser-apt-release.s3.brave.com/ bionic main

[ IF YOU COPY PASTE: Watch out the webpage will format links to:
http:link (NUMBER) bionic main ,
if you copy paste remove the (NUMBER) ]

C.) use keyboard to save changes:
Ctrl o / Strg o

D.) use keyboard to exit nano editor:
Ctrl x / Strg x

E.) then, try
#sudo apt update

F.) If the error persists, try rename the file with:
#sudo mv /etc/apt/sources.list.d/brave-browser-release-.list /etc/apt/sources.list.d/brave-browser-release-bionic.list

Applying both resolved my issues with “Malformed entry 1 in list file /etc/apt/sources.list.d/brave-browser-release-.list (Component)”, but I am not sure what it was. Apparently there is an issue with the expression “${UBUNTU_CODENAME}” on ubuntu minimal installs.

1 Like

Thank you very much. It worked.

1 Like

I tried with beta version this way. Not working : (

It works, thanks a lot!

1 Like

[ !!! IF YOU COPY PASTE: Watch out the webpage will format links to:
http:link (NUMBER) main ,
if you copy paste remove the (NUMBER) ]

lucky you, for me the same is happening so i tryed to forget it, but when i tried to install something else through the command line, it told me it again

You can download it from the Snap Store