Bug 1799638 Comment 6 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

I've reproduced this issue in Firefox v107.0 and verified the fix in Beta v108.0b4 and Nightly v109.0a1 In Windows 10.

Test results:
* Tokyo Time Zone:
  * Release v107.0: 
    * console.log((new Date("1948-05-01T23:59:59")));  ->  Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000"))); -> Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.001"))); -> Date Sun May 02 1948 00:59:59 GMT+1000 (Japan Daylight Time) (**INCORRECT**)
    * console.log((new Date("1948-05-01T23:59:59.001")).getTimezoneOffset()); -> -600 (**INCORRECT**)
    * console.log((new Date("1948-05-02T00:00:00"))); -> Date Sun May 02 1948 01:00:00 GMT+1000 (Japan Daylight Time) (CORRECT?)
    * console.log((new Date("1948-05-02T00:00:00")).getTimezoneOffset()); -> -600 (CORRECT?)
  * Beta v108.0b4:
    * console.log((new Date("1948-05-01T23:59:59")));  ->  Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000"))); -> Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.001"))); -> Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (**CORRECTED!**)
    * console.log((new Date("1948-05-01T23:59:59.001")).getTimezoneOffset()); -> -540 (**CORRECTED!**)
    * console.log((new Date("1948-05-02T00:00:00"))); -> Date Sun May 02 1948 01:00:00 GMT+1000 (Japan Daylight Time) (CORRECT?)
    * console.log((new Date("1948-05-02T00:00:00")).getTimezoneOffset()); -> -600 (CORRECT?)
  * Nightly v109.0a1:
    * console.log((new Date("1948-05-01T23:59:59")));  ->  Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000"))); -> Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.001"))); -> Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (**CORRECTED!**)
    * console.log((new Date("1948-05-01T23:59:59.001")).getTimezoneOffset()); -> -540 (**CORRECTED!**)
    * console.log((new Date("1948-05-02T00:00:00"))); -> Date Sun May 02 1948 01:00:00 GMT+1000 (Japan Daylight Time) (CORRECT?)
    * console.log((new Date("1948-05-02T00:00:00")).getTimezoneOffset()); -> -600 (CORRECT?)
I've reproduced this issue in Firefox v107.0 and verified the fix in Beta v108.0b4 and Nightly v109.0a1 In Windows 10.

Test results:
* Tokyo Time Zone:
  * Release v107.0: 
    * console.log((new Date("1948-05-01T23:59:59")));  ->  Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000"))); -> Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.001"))); -> Date Sun May 02 1948 00:59:59 GMT+1000 (Japan Daylight Time) (**INCORRECT**)
    * console.log((new Date("1948-05-01T23:59:59.001")).getTimezoneOffset()); -> -600 (**INCORRECT**)
    * console.log((new Date("1948-05-02T00:00:00"))); -> Date Sun May 02 1948 01:00:00 GMT+1000 (Japan Daylight Time) (CORRECT)
    * console.log((new Date("1948-05-02T00:00:00")).getTimezoneOffset()); -> -600 (CORRECT)
  * Beta v108.0b4:
    * console.log((new Date("1948-05-01T23:59:59")));  ->  Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000"))); -> Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.001"))); -> Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (**CORRECTED!**)
    * console.log((new Date("1948-05-01T23:59:59.001")).getTimezoneOffset()); -> -540 (**CORRECTED!**)
    * console.log((new Date("1948-05-02T00:00:00"))); -> Date Sun May 02 1948 01:00:00 GMT+1000 (Japan Daylight Time) (CORRECT)
    * console.log((new Date("1948-05-02T00:00:00")).getTimezoneOffset()); -> -600 (CORRECT)
  * Nightly v109.0a1:
    * console.log((new Date("1948-05-01T23:59:59")));  ->  Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000"))); -> Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.000")).getTimezoneOffset()); -> -540 (CORRECT)
    * console.log((new Date("1948-05-01T23:59:59.001"))); -> Date Sat May 01 1948 23:59:59 GMT+0900 (Japan Standard Time) (**CORRECTED!**)
    * console.log((new Date("1948-05-01T23:59:59.001")).getTimezoneOffset()); -> -540 (**CORRECTED!**)
    * console.log((new Date("1948-05-02T00:00:00"))); -> Date Sun May 02 1948 01:00:00 GMT+1000 (Japan Daylight Time) (CORRECT)
    * console.log((new Date("1948-05-02T00:00:00")).getTimezoneOffset()); -> -600 (CORRECT)

Back to Bug 1799638 Comment 6