Skip to content

Commit

Permalink
Restrict LatitudeLongitueGrid topologies (#3694)
Browse files Browse the repository at this point in the history
* Restrict LatitudeLongitueGrid topologies

* Remove restriction on TZ
  • Loading branch information
glwagner authored Aug 19, 2024
1 parent 088f973 commit 8eaba36
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Grids/latitude_longitude_grid.jl
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,10 @@ function validate_lat_lon_grid_args(topology, size, halo, FT, latitude, longitud
TZ = Bounded
end

if TY() isa Periodic
throw(ArgumentError("LatitudeLongitudeGrid cannot be Periodic in latitude!"))
end

# Validate longitude and latitude
λ₁, λ₂ = get_domain_extent(longitude, Nλ)
λ₂ - λ₁ 360 || throw(ArgumentError("Longitudinal extent cannot be greater than 360 degrees."))
Expand Down

0 comments on commit 8eaba36

Please sign in to comment.