Friday, May 3, 2024
 Popular · Latest · Hot · Upcoming
68
rated 0 times [  68] [ 0]  / answers: 1 / hits: 39792  / 3 Years ago, thu, october 28, 2021, 5:19:15

Been trying to install git-core package for almost more than half a day now. Every time I do, I get this error:



dpkg: error: parsing file '/var/lib/dpkg/available' near line 0:
newline in field name `../../../../../share/pyshared/UpdateManager/Core/__init__.py'


I've also tried running sudo apt-get update and sudo apt-get install --fix-missing. Even tried rebooting and cleaning the apt-get cache, still doesnt work.


More From » apt

 Answers
0

The problem is that your /var/lib/dpkg/available file is damaged.



This is not necessarily related to the git or git-core packages. Try to install any other package and they will fail too.



To fix this you have to delete/clear the file using the command:



sudo dpkg --clear-avail


then rebuild the file using the command:



sudo apt-get update


Now you should be able to install git and git-core.


[#44055] Friday, October 29, 2021, 3 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
initiallartebeest

Total Points: 24
Total Questions: 118
Total Answers: 105

Location: Venezuela
Member since Thu, Jul 15, 2021
3 Years ago
;