(I’m posting it here because I can’t make a GitHub account)
The item infobox on the left should specify whether the date is BC or AD
Also it shouldn’t be possible to select year 0 in the timeslide as it does not exist
Thanks, I opened an issue to track this bug:
opened 02:49PM - 14 Apr 24 UTC
bug
As reported [on the forum](https://forum.openhistoricalmap.org/t/negative-date-e… rrors/165?u=minh_nguyen), the [Pyramid of Khufu](https://www.openhistoricalmap.org/way/198560373) is reported as being built in 2570 CE, even though its `start_date=-2570` should mean 2571 BCE, as discussed in OpenHistoricalMap/issues#624.
The code currently strips out the negative sign but displays the year verbatim after that. Instead, it should rely on [`Intl.DateTimeFormat`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/DateTimeFormat) to format any date, respecting the locale and correctly interpreting negative year values.
https://github.com/OpenHistoricalMap/ohm-inspector/blob/901cd7e0f7063b3abb677e6a38cb66c9841fbc9d/openhistoricalmap-inspector.js#L270
0
is 1 BCE according to the ISO 8601 standard, but several of our software components are off by one. A fix to the time slider is awaiting deployment that will introduce a BC/AD field so that you can enter “1” and “BC” and it’ll be treated as 1 BCE without you having to know about this nuance. “0” will also be ignored as part of this change.
opened 11:39AM - 24 Oct 23 UTC
bug
dates
time
timeslider-v2
The current map seems to interpret negative years as BCE. For example, [this nod… e](https://www.openhistoricalmap.org/node/2102353058) ends in `-0206-11-17` and will terminate rendering on November 17, 206 BC.
But the wiki page [OpenHistoricalMap/Tags/Key/start_date](https://wiki.openstreetmap.org/wiki/OpenHistoricalMap/Tags/Key/start_date) mentions ISO 8601. In the extended representation of this standard, 1 BC is recorded as +0000, 2 BC is recorded as -0001, and so on. Does OHM need to follow this standard?
1 Like