Skip to content

mcr.microsoft.com/devcontainers/base:ubuntu seems to have invalid /etc/timezone value "/UTC" #1709

@epicwhale

Description

@epicwhale

The Ubuntu variant of the base devcontainer image sets /etc/timezone to /UTC (with leading slash) instead of Etc/UTC. This breaks Python's zoneinfo module and any library that reads system timezone (e.g., Pendulum, Prefect).

Reproduction:
docker run --rm mcr.microsoft.com/devcontainers/base:ubuntu cat /etc/timezone

Output: /UTC

Expected: Etc/UTC or UTC

Actual: /UTC

Error:

  from zoneinfo import ZoneInfo
  ZoneInfo('/UTC')
  # ValueError: ZoneInfo keys may not be absolute paths, got: /UTC

oddly, using :debian variant doesn't have the same issue

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions