When trying to configure the ubuntu repository with key provided here:
https://code.visualstudio.com/docs/setup/linux
The packages files seems different from the checksums provided
Expected filesize is 35343
Actual filesize in repo is 35578
```Err:3 https://packages.microsoft.com/repos/vscode stable/main amd64 Packages
File has unexpected size (35578 != 35343). Mirror sync in progress?
Hashes of expected file:
Steps to Reproduce:
I have the same problem. My OS is: Linux Mint 17.3 Rosa.
Same problem on ubuntu 16.04.3.
Thanks all for the report, we're investigating. In the meantime you can hopefully still pull the packages from the URLs and install manually via dpkg -i <...>.deb:
If you have issues with those URLs please let me know.
So you can apt-get update, you might want to comment out the entry in /etc/apt/sources.list.d/vscode.list. Change deb [arch=.... to # deb [arch=....... I don't know if there is a better way to do this, but it worked for me.
Hello team, do you have any ETA on this issue? It affects (by braking apt update) one of use cases for our prod service.
Reason: The latest repository update only updated Release and Release.gpg, but InRelease is still from Dec 21st.
Actually, the Release.gpg is still not updated too...

I'm seeing the same thing, but with (35649 > 35343) instead, on Debian 9.3. Same SHA/MD5 sums.
Using Ubuntu 16.04 I get the error:
E: Failed to fetch http://packages.microsoft.com/repos/vscode/dists/stable/main/binary-amd64/Packages Writing more data than expected (228420 > 227140)
E: Some index files failed to download. They have been ignored, or old ones used instead.
Linux Mint 18.3 (based on Ubuntu 16.04) 64-bit
After installation code_1.19.1-1513676564_amd64.deb from official site I get the error when I try update system
$ sudo apt update
....
Reading package lists... Done
E: Failed to fetch http://packages.microsoft.com/repos/vscode/dists/stable/main/binary-amd64/Packages Writing more data than expected (227448 > 227140)
E: Some index files failed to download. They have been ignored, or old ones used instead.
It appears that the "Release" file shown above in the post from @IronGeek is related to an insiders build for v1.20.0 and not the stable build of v1.19.1 from 12-21-2017.
Here is the v1.20.0 insiders build from https://packages.microsoft.com/repos/vscode/pool/main/c/code-insiders/:
code-insiders_1.20.0-1514873705_amd64.deb 03-Jan-2018 21:55 45834862
Here is the v1.19.1 stable build from https://packages.microsoft.com/repos/vscode/pool/main/c/code/:
code_1.19.1-1513676564_amd64.deb 21-Dec-2017 18:21 45385688
Fixed, issue can be closed :tada:

Thanks for your patience everyone, the team is planning on putting together better monitoring to hopefully catch this sort of thing earlier
E: Failed to fetch https://packages.microsoft.com/repos/vscode/dists/stable/main/binary-amd64/Packages.bz2 Writing more data than expected (38219 > 38059)
Hashes of expected file:
- Filesize:38059 [weak]
- SHA512:d960bc2562e8e3914627b1f8a255d6e78506acac42c7c540d6ce09c4d20f0447edb9d2596b87bb64d1d59e4786a89f7c9f7711743d057d10041f95cf8a7f7dd1
- SHA256:692a9d9348b76a7ab30c112a4e1f4e99a8ba99454ec1ed4a5c82d1afa45c43f7
- SHA1:4dfaf756f7b30988ddacc77863a363ffd6f409a4 [weak]
- MD5Sum:256db81b96e2ac1ef30d0d1c63545b85 [weak]
Release file created at: Fri, 26 Jan 2018 18:29:25 +0000
E: Some index files failed to download. They have been ignored, or old ones used instead.
E: Failed to fetch https://packages.microsoft.com/repos/vscode/dists/stable/main/binary-amd64/Packages Writing more data than expected (246868 > 245766)
Linux Mint 18.3
E: Failed to fetch http://packages.microsoft.com/repos/vscode/dists/stable/main/binary-amd64/Packages.bz2 File has unexpected size (38219 != 38059). Mirror sync in progress?
Hashes of expected file:
- Filesize:38059 [weak]
- SHA512:d960bc2562e8e3914627b1f8a255d6e78506acac42c7c540d6ce09c4d20f0447edb9d2596b87bb64d1d59e4786a89f7c9f7711743d057d10041f95cf8a7f7dd1
- SHA256:692a9d9348b76a7ab30c112a4e1f4e99a8ba99454ec1ed4a5c82d1afa45c43f7
- SHA1:4dfaf756f7b30988ddacc77863a363ffd6f409a4 [weak]
- MD5Sum:256db81b96e2ac1ef30d0d1c63545b85 [weak]
Release file created at: Fri, 26 Jan 2018 18:29:25 +0000
E: Some index files failed to download. They have been ignored, or old ones used instead.
Ubuntu 17.10
Thanks very much for your work!
Err:12 http://packages.microsoft.com/repos/vscode stable/main amd64 Packages
File has unexpected size (38219 != 38059). Mirror sync in progress?
Hashes of expected file:
Ubuntu 17.10
Thanks a lot!
I'll try look into this asap, in the meantime you can pull the latest from the repo https://code.visualstudio.com/
I just tried to make an apt-get update, and now the issue is gone away.
Just tried it on Ubuntu DSVM. Still broken
Get:11 http://packages.microsoft.com/repos/vscode stable/main amd64 Packages [38.1 kB]
Err:11 http://packages.microsoft.com/repos/vscode stable/main amd64 Packages
File has unexpected size (38219 != 38059). Mirror sync in progress?
Hashes of expected file:
- Filesize:38059 [weak]
- SHA512:d960bc2562e8e3914627b1f8a255d6e78506acac42c7c540d6ce09c4d20f0447edb9d2596b87bb64d1d59e4786a89f7c9f7711743d057d10041f95cf8a7f7dd1
- SHA256:692a9d9348b76a7ab30c112a4e1f4e99a8ba99454ec1ed4a5c82d1afa45c43f7
- SHA1:4dfaf756f7b30988ddacc77863a363ffd6f409a4 [weak]
- MD5Sum:256db81b96e2ac1ef30d0d1c63545b85 [weak]
Release file created at: Fri, 26 Jan 2018 18:29:25 +0000
...
E: Failed to fetch http://packages.microsoft.com/repos/vscode/dists/stable/main/binary-amd64/Packages.bz2 File has unexpected size (38219 != 38059). Mirror sync in progress?
Hashes of expected file:
- Filesize:38059 [weak]
- SHA512:d960bc2562e8e3914627b1f8a255d6e78506acac42c7c540d6ce09c4d20f0447edb9d2596b87bb64d1d59e4786a89f7c9f7711743d057d10041f95cf8a7f7dd1
- SHA256:692a9d9348b76a7ab30c112a4e1f4e99a8ba99454ec1ed4a5c82d1afa45c43f7
- SHA1:4dfaf756f7b30988ddacc77863a363ffd6f409a4 [weak]
- MD5Sum:256db81b96e2ac1ef30d0d1c63545b85 [weak]
Release file created at: Fri, 26 Jan 2018 18:29:25 +0000
Ubuntu 17.10
Thanks for your help!
Tried again, was successfully able to update.
I just deleted the 1.19.3 package, so you should be able to update to 1.19.2. I'll try republishing 1.19.3 now
The new one seems to work, thanks for the report all.
Err:15 https://packages.microsoft.com/repos/vscode stable/main amd64 Packages
Writing more data than expected (284174 > 281970)
It's happening again:
Err:13 https://packages.microsoft.com/repos/vscode stable/main amd64 Packages
E: Failed to fetch https://packages.microsoft.com/repos/vscode/dists/stable/main/binary-amd64/Packages Writing more data than expected (284174 > 281970)
On Ubuntu 16.04
Yep, happening again for me on Ubuntu 16.04 fresh install (breaking my automatic imaging :smile: )
Also seeing it in Linux Mint 18.3
Err:9 http://packages.microsoft.com/repos/vscode stable/main amd64 Packages
Writing more data than expected (283444 > 281970)
Ubuntu 16.04.1
E: Failed to fetch https://packages.microsoft.com/repos/vscode/dists/stable/main/binary-amd64/Packages Writing more data than expected (284174 > 281970)
Ubuntu 16.04.4
This isn't distro-related. Most likely, the issue is caused by InRelease being older than rest of the repository (it's dated 14 March, while Packages and rest are dated 15 March). and it contains wrong checksums and file sizes.
Most helpful comment
It's happening again:
On Ubuntu 16.04