Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR: KeyError: key "April" not found with tzdata 2024b #471

Closed
omus opened this issue Sep 6, 2024 · 1 comment · Fixed by #472
Closed

ERROR: KeyError: key "April" not found with tzdata 2024b #471

omus opened this issue Sep 6, 2024 · 1 comment · Fixed by #472

Comments

@omus
Copy link
Member

omus commented Sep 6, 2024

julia> TimeZones.build("2024b")
[ Info: Downloading tzdata 2024b archive
[ Info: Decompressing tzdata 2024b region data
[ Info: Compiling tzdata 2024b region data
ERROR: KeyError: key "April" not found
Stacktrace:
  [1] getindex
    @ ./dict.jl:498 [inlined]
  [2] parse(::Type{TimeZones.TZData.Rule}, str::SubString{String})
    @ TimeZones.TZData ~/.julia/dev/TimeZones/src/tzdata/compile.jl:300
  [3] load!(tz_source::TimeZones.TZData.TZSource, filename::String, io::IOStream)
    @ TimeZones.TZData ~/.julia/dev/TimeZones/src/tzdata/compile.jl:614
  [4] #34
    @ ~/.julia/dev/TimeZones/src/tzdata/compile.jl:635 [inlined]
  [5] open(::TimeZones.TZData.var"#34#35"{TimeZones.TZData.TZSource, String}, ::String, ::Vararg{String}; kwargs::@Kwargs{})
    @ Base ./io.jl:396
  [6] open
    @ ./io.jl:393 [inlined]
  [7] load!
    @ ~/.julia/dev/TimeZones/src/tzdata/compile.jl:634 [inlined]
  [8] TimeZones.TZData.TZSource(files::Vector{String})
    @ TimeZones.TZData ~/.julia/dev/TimeZones/src/tzdata/compile.jl:71
  [9] build(version::String, working_dir::String)
    @ TimeZones.TZData ~/.julia/dev/TimeZones/src/tzdata/build.jl:59
 [10] build(version::String; force::Bool)
    @ TimeZones ~/.julia/dev/TimeZones/src/build.jl:12
 [11] build(version::String)
    @ TimeZones ~/.julia/dev/TimeZones/src/build.jl:11
 [12] top-level scope
    @ REPL[5]:1

The tzdata 2024b release introduced this problematic rule:

# Rule	NAME	FROM	TO	-	IN	ON	AT	SAVE	LETTER/S
Rule	Mexico	1931	only	-	April	30	0:00	1:00	D

The reason this is an issue is that historically the "IN" month has always been a 3-letter length abbreviation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant