Crash when using Date.toLocaleString in a query

Using Date.toLocaleString in a query makes my EventStore crash. I’m running it from console in a Windows 8.1 and I’ve tried with versions 3.6.1 and 3.6.2. I don’t think it has any impact but I’ve tried running the query from both Chrome and Internet Explorer.

The moment I run the query, EventStore crashes showing the usual Windows dialog stating that my “EventStore.ClusterNode.exe has stopped working” and immediately exiting in the console without showing any error message there. I’ve found no information regarding the crash in neither -cluster-node.log nor -cluster-node-err.log.

Others Date methods such as toDateString (which is what I ended up using) work without problem.

Reproduction:

Will confirm that it’s not working in windows. Linux seems fine.

Ok, confirmed that it crashes in windows, will investigate.
Thanks for reporting the issue.

We opened an issue on the Event Store github page here to be tracked.

Great, glad to help.

I know projections are still beta but how unlikely is it for EventStore to crash like this?

This made me quite wary of running queries in production as we only use a single node. Luckily in this case we tested it first in our dev server but still I’m considering setting up a secondary node for querying / setting projections.

I don’t recall having seen Event Store crash like this because of running a query.
We appreciate feedback like this as we are busy working on moving projections out of beta into a production quality feature.

From the outset this looks like its likely to be v8 crashing but needs
more looking at.

This PR resolves the issue, please don’t hesitate to shout if you run into any further issues. Thank you for reporting this.

I am still having this issue in EventStore 4.1.2 and 5.0.0 on Windows 10. When I try to use toLocaleString() in a projection, the console prints the following error. This did not show up in the log or the error log. “Fatal error in , line 0 Failed to create ICU date format, are ICU data files missing? FailureMessage Object: 00000051F4BFC530”. I also attached a screen shot of the console before it closed.

EventStore5error.PNG