Bug #2796

JS: xs:date() can modify timezone for pure dates

Added by John Lumley almost 3 years ago. Updated almost 2 years ago.

Start date:
Due date:
% Done:


Applies to JS Branch:
Fix Committed on JS Branch:
Fixed in JS Release:
SEF Generated with:
Contact person:
Additional contact persons:


Atomic.js - dateTimeFromString("1993-03-31") returns a date of 1993-03-30 at least in BST! (Internally it generates 1993-03-30T23:00:00Z). Unsure whether this behaviour is correct, but at least one QT3 test (op-concatentate-mix-args-013) assumes the string value should be 1993-03-31


#1 Updated by Debbie Lockett almost 3 years ago

  • Status changed from New to In Progress

Was this running the test directly in the browser (with your new test driver)? The QT3-to-XSLT converted version of the test op-concatentate-mix-args-013 passes when I run it in the XsltTestSuiteDriverJS. Since dealing with dates is so fiddly, I wouldn't be too surprised if something is different in the JS Date object returned by browsers so there is some further work to be done!

#2 Updated by Michael Kay almost 3 years ago

  • Project changed from Saxon - Internal to Saxon-JS

#3 Updated by John Lumley over 2 years ago

  • Status changed from In Progress to Resolved

Appears now to be working correctly, but I raised the issue in a BST situation and now we're back to GMT so no daylight savings corrections are required. Marking as resolved, but may need to check this again in April 2017!

#4 Updated by Debbie Lockett over 2 years ago

  • Status changed from Resolved to Closed
  • % Done changed from 0 to 100
  • Found in version set to 0.9
  • Fixed in version set to 0.9.1

Bug fix applied in the Saxon-JS 0.9.1 beta release.

#5 Updated by Community Admin almost 2 years ago

  • Fixed in JS Release set to Saxon-JS 0.9.1
  • Applies to JS Branch 0.9 added
  • Fix Committed on JS Branch 0.9 added

Please register to edit this issue

Also available in: Atom PDF Tracking page