Repository Error regarding Mattermost Desktop Client for Ubuntu/Debian

Summary
Installation or update of Mattermost Desktop Client for Ubuntu/Debian is not possible with the current repository.

Steps to reproduce
Using Debian/Ubuntu (or similiar)

Open Terminal.

curl -o- https://deb.packages.mattermost.com/setup-repo.sh | sudo bash

sudo apt install mattermost-desktop OR sudo apt upgrade mattermost-desktop

Expected behavior
Should simply install without error message

Observed behavior
Installation or update of Mattermost Desktop Client for Ubuntu/Debian is not possible with the current repository. An error occurs due to a corrupted file. Error message during update as follows:

Failure to fetch https://deb.packages.mattermost.com/pool/main/m/mattermost-desktop/mattermost-desktop_5.3.1-1_amd64.deb file has an unexpected size (74034020 != 74048594). Possibly a mirror synchronization is in progress?
Hashes of expected file:
-SHA512:4c87f8ffc783c02fa2cf8bab9032b16d488de0b4280f45e0dd3b15cd902378ed45f98ce039a3ea9dcd77e54d35fd01b17d01dd663f1b43892d0b29af06d32af8

  • SHA256:df1c6731af6d24407254be640082f0b252445097920905fae4c15eae1ee49512
  • SHA1:e58fcba69cb43954aeeff5d948d875c466a0fa06 [weak]
  • MD5Sum:8000df987a2c125b0d571662b9ac257a [weak]
  • Filesize:74048594 [weak]
1 Like

Hi @Salomon and welcome to the Mattermost forums!

This is a known issue and I’ve already Mattermost about it. There’s also a GitHub issue on that topic:

If you do not want to wait for Mattermost to fix it, you can run the following commands:

wget https://deb.packages.mattermost.com/pool/main/m/mattermost-desktop/mattermost-desktop_5.3.1-1_amd64.deb
dpkg -i mattermost-desktop_5.3.1-1_amd64.deb

Update 2023-04-06:
This workaround of course should only be used if the integrity of the file has been verified otherwise. I did not mention it here, but I compared the filesize and hashsums to the ones from GitHub (the official Mattermost release) and found out that a new release has hit the mirrors (5.3.1-495 compared to 5.3.1), so that’s most likely the reason for the difference, but besides that, the source looks good.

This command can be used to download the file directly from GitHub.

wget https://releases.mattermost.com/desktop/5.3.1/mattermost-desktop_5.3.1-1_amd64.deb
dpkg -i mattermost-desktop_5.3.1-1_amd64.deb

Right now, the problem is not solved, the package is still not installable (same error, but a new release (5.3.1-496) on the mirrors).

The package manager still shows a slightly newer version for update after manually installing

https://deb.packages.mattermost.com/pool/main/m/mattermost-desktop/mattermost-desktop_5.3.1-1_amd64.deb

AFAIK it’s recommended to use apt over dpkg whenever possible, because it will not only copy files but also do configuration. A path with ./ will make sure a downloaded file is installed.

sudo apt install ./mattermost-desktop_5.3.1-1_amd64.deb

dpkg -i does also do the configuration and run the scripts, there’s no difference in this regard. The only difference is that it does not care about fulfilling dependencies, aptand apt-get do, but in this specific case, all dependencies should have been met already and we explicitly do not want to fulfil dependencies from the online repositories since they’re still broken unfortunately.

1 Like

This has been fixed now - version 5.3.1-496 can be pulled from the official debian repositories again without errors.