django / djangopeople

A geographical community site for Django developers

Home Page:https://people.djangoproject.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Invalid longitude when navigating to Japan from US on Change your Location form map

phu opened this issue · comments

commented

My previous location was in the US; when attempting to change it to Tokyo, I zoomed out and dragged my way across the Pacific. On updating the other fields and submitting, nothing visible happened (no POST, no visible error message, nothing at all in the UI).

The (Chromium) console showed this error:

An invalid form control with name='longitude' is not focusable.

Removing the display:none styling from the longitude field's container, the map had set it to about -220, and the client-side validation was trying to display an error on that field, which showed up upon resubmitting with the field visible:

Value must be greater than or equal to -180.

Looking up the correct longitude for Tokyo (139.6917), entering it manually, and submitting resulted in success, and the map displays my location correctly.