APT repository InRelease Date field sometimes gets invalid Timezone. (MUST be +0000, UTC, GMT, or Z)

At random times, after adding packages manually or via a Jenkins job, we get a ‘corrupt’ InRelease file in apt repos.

apt-get update returns
‘W: Invalid ‘Date’ entry in Release file /var/lib/apt/lists/partial/repository_dists_all_InRelease’.

“The time zone must be specified using one of the strings +0000, UTC, GMT, or Z.”

The file at https:///repository//dists/all/InRelease then indeed contains a ‘Date:’ field with an unacceptable timezone.
We have had the following occurances:

  • Date: Thu, 18 Jun 2020 03:48:37 EDT
  • Date: Tue, 18 Aug 2020 19:33:17 KRAT
  • Date: Wed, 19 Aug 2020 11:00:04 UZT

Uploading a package manually, or running a different Jenkins Job that adds a package, sometimes fixes this.

Looking at the code nexus-public/AptHostedFacet.java at master · sonatype/nexus-public · GitHub This should just use the TZ of the server, which is set at ‘/etc/localtime -> /usr/share/zoneinfo/Etc/UTC’, and not randomly change…

1 Like

This has been reported as NEXUS-24846. Please watch that ticket for further updates.

1 Like