I reproduced the problem just now.
First I built something with snapcraft on bionic, and verified it built fine, no warning.
Then I changed /etc/apt/sources.list to add
deb http://security.ubuntu.com/ubuntu bionic-security main restricted universe multiverse
at the end. Voila, snapcraft now fails with
E:Failed to fetch copy:/home/dank/.cache/snapcraft/stage-packages/apt/ce447e8cd9a9016c1222302927d231c373080838d1dba0fb34fb11e2a4e3a9eeb22060b3057a6e5a6e80e8635399f954/var/lib/apt/lists/partial/archive.ubuntu.com_ubuntu_dists_bionic-security_main_dep11_icons-48x48.tar.gz Hash Sum mismatch
Above that error were several lines with a warning:
W:Target Contents-deb-legacy (Contents-all) is configured multiple times in /home/dank/.cache/snapcraft/stage-packages/apt/ce447e8cd9a9016c1222302927d231c373080838d1dba0fb34fb11e2a4e3a9eeb22060b3057a6e5a6e80e8635399f954/etc/apt/sources.list:15 and /home/dank/.cache/snapcraft/stage-packages/apt/ce447e8cd9a9016c1222302927d231c373080838d1dba0fb34fb11e2a4e3a9eeb22060b3057a6e5a6e80e8635399f954/etc/apt/sources.list:33
Fine, evidently my sources.list is confused, so next I tried replacing the entire /etc/apt/sources.list with minimal correct contents,
deb http://archive.ubuntu.com/ubuntu bionic main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu bionic-updates main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu bionic-backports main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu bionic-security main restricted universe multiverse
This still failed with
Err http://security.ubuntu.com/ubuntu bionic-security/main DEP-11 64x64 Icons
Hash Sum mismatch
...
E:Failed to fetch copy:/home/dank/.cache/snapcraft/stage-packages/apt/9e9bf0558a790d131a6ed6709b20f534d57088f34d355b770f4ec88fbf6c12982a8fb3e28d10682aae632dff4beb4360/var/lib/apt/lists/partial/security.ubuntu.com_ubuntu_dists_bionic-security_main_dep11_icons-48x48.tar.gz Hash Sum mismatch
this time without the ‘multiple configuration’ warning.
OK, so, uh, maybe http://security.ubuntu.com/ubuntu bionic-security/main is broken. And sure enough, removing the word ‘main’ from the line
deb http://security.ubuntu.com/ubuntu bionic-security main restricted universe multiverse
worked.
I don’t think I’m behind any kind of proxy (I’m in downtown Los Angeles on a 100Mbps link).