mintsourceが不明な理由で機能しない

mintsourceが不明な理由で機能しない

rootアクセス権を取得し、誤ってmintsourcesLinux Mint 20 Cinnamonを実行しました。

Traceback (most recent call last):
  File "/usr/lib/linuxmint/mintSources/mintSources.py", line 1919, in <module>
    Application().run()
  File "/usr/lib/linuxmint/mintSources/mintSources.py", line 968, in __init__
    self.detect_official_sources()
  File "/usr/lib/linuxmint/mintSources/mintSources.py", line 1834, in detect_official_sources
    self.update_flags()
  File "/usr/lib/linuxmint/mintSources/mintSources.py", line 1841, in update_flags
    if selected_mirror[-1] == "/":
IndexError: string index out of range

これが一般ユーザーとして実行できない理由かどうかはわかりません。 GUIにパスワードを入力すると、同じ結果が表示されます。

Traceback (most recent call last):
  File "/usr/lib/linuxmint/mintSources/mintSources.py", line 1919, in <module>
    Application().run()
  File "/usr/lib/linuxmint/mintSources/mintSources.py", line 968, in __init__
    self.detect_official_sources()
  File "/usr/lib/linuxmint/mintSources/mintSources.py", line 1834, in detect_official_sources
    self.update_flags()
  File "/usr/lib/linuxmint/mintSources/mintSources.py", line 1841, in update_flags
    if selected_mirror[-1] == "/":
IndexError: string index out of range

私は逆追跡呼び出しを理解していないので、それを理解するのに役立つと確信しています。私はmintsources1年間使ったことがないので、それは原因ではないかもしれません。どこから始めるべきかわかりません。

ベストアンサー1

解決しました。このファイルからすべての二重スペース(および追加のスペース)を削除しました。

/etc/apt/sources.list.d/official-package-repositories.list

列を並べ替えるためにスペースを追加して、好きなように編集したことを覚えています。そして、一部の項目はマージされることがあります。

これらの組み合わせは明らかに問題ではありませんが、余分なスペースは(to mintsources、not apt)ありません。


だから結局、次のように見えます。

deb http://packages.linuxmint.com ulyana main upstream import backport 
deb http://archive.ubuntu.com/ubuntu focal main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu focal-updates main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu focal-backports main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu focal-security main restricted universe multiverse
deb http://archive.canonical.com/ubuntu focal partner

その後、mintsources通常のユーザーまたはrootとして実行できます。

おすすめ記事