He's alive AND single. The exception from the console is:
NullPointerException at com.webobjects.foundation.NSTimestampFormatter.format(NSTimestampFormatter.java:621) at java.text.Format.format(Format.java:157) at er.rest.ERXRestUtils.coerceValueToTypeNamed(ERXRestUtils.java:337) at er.rest.ERXRestUtils.coerceValueToAttributeType(ERXRestUtils.java:473) at er.rest.ERXRestRequestNode.updateObjectWithFilter(ERXRestRequestNode.java:1396) at er.rest.ERXRestRequestNode.createObjectWithFilter(ERXRestRequestNode.java:859) at er.rest.routes.ERXRouteController.create(ERXRouteController.java:668) at er.rest.routes.ERXRouteController.create(ERXRouteController.java:636) at er.rest.routes.ERXRouteController.create(ERXRouteController.java:621) at com.druide.stats.sparkle.rest.SparkleController.createAction(SparkleController.java:52) ... skipped 4 stack elements at er.rest.routes.ERXRouteController.performActionWithArguments(ERXRouteController.java:1575) at er.rest.routes.ERXRouteController.performRouteActionNamed(ERXRouteController.java:1526) at er.rest.routes.ERXRouteController.performActionNamed(ERXRouteController.java:1401) at er.rest.routes.ERXRouteController.performActionNamed(ERXRouteController.java:1344) ... skipped 8 stack elements but the real one is: Failed to parse '2015-07-22T08:43:43-0400' as a timestamp Formatter: com.webobjects.foundation.NSTimestampFormatter < parseTimeZone = null ; formatTimeZone = null ; pattern = %Y-%m-%dT%H:%M:%S%z > Value: "2015-07-22T08:43:43-0400" ----- Mail original ----- De: "Chuck Hill" <ch...@gevityinc.com> À: "Pascal Robert" <prob...@macti.ca>, "WebObjects-Dev List" <webobjects-dev@lists.apple.com> Envoyé: Mercredi 22 Juillet 2015 10:39:32 Objet: Re: Problem with %z in NSTimestampFormatter He lives! Hi Pascal! Where is the exception thrown from? Do you have a stack trace? Chuck On 2015-07-22, 7:32 AM, "webobjects-dev-bounces+chill=gevityinc....@lists.apple.com on behalf of Pascal Robert" <webobjects-dev-bounces+chill=gevityinc....@lists.apple.com on behalf of prob...@macti.ca> wrote: >Hi, > >Yes, I'm still alive. Anyway, I'm trying to build a small REST app as a >prototype, and I need to parse a date that have this format: > > 2015-07-22T08:43:43-0400 > >So I did: > > protected ERXRestContext createRestContext() { > ERXRestContext restContext = new ERXRestContext(editingContext()); > restContext.setUserInfoForKey("%Y-%m-%d'T'%H:%M:%S%z", >"er.rest.timestampFormat"); > return restContext; > } > >But I get an exception saying it's an illegal format. The problem is %z, >if I remove that part, it works (as long as I remove -0400 from the >date). It this a bug specific to WO 5.4 ?? > _______________________________________________ >Do not post admin requests to the list. They will be ignored. >Webobjects-dev mailing list (Webobjects-dev@lists.apple.com) >Help/Unsubscribe/Update your Subscription: >https://lists.apple.com/mailman/options/webobjects-dev/chill%40gevityinc.c >om > >This email sent to ch...@gevityinc.com _______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (Webobjects-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com