Closed eredo closed 6 years ago
I'm seeing this on 0.2.5 as well
the work around in #26 of using double also results in a stack overflow
double ccv;
double bZip;
FINER: 2015-10-31 15:45:25.734: Serializing field: isInfinite
FINER: 2015-10-31 15:45:25.734: Start serializing field: isNaN
FINER: 2015-10-31 15:45:25.734: Property: null
FINER: 2015-10-31 15:45:25.734: Serializing field: isNaN
FINER: 2015-10-31 15:45:25.734: Start serializing field: isFinite
FINER: 2015-10-31 15:45:25.734: Property: null
FINER: 2015-10-31 15:45:25.734: Serializing field: isFinite
FINER: 2015-10-31 15:45:25.734: Start serializing field: sign
FINER: 2015-10-31 15:45:25.734: Property: null
FINER: 2015-10-31 15:45:25.734: Serializing field: sign
FINER: 2015-10-31 15:45:25.734: Start serializing field: runtimeType
FINER: 2015-10-31 15:45:25.734: Property: null
FINER: 2015-10-31 15:45:25.734: Serializing field: runtimeType
FINER: 2015-10-31 15:45:25.734: Serialization completed.
FINER: 2015-10-31 15:45:25.734: Start serializing field: isNegative
FINER: 2015-10-31 15:45:25.734: Property: null
FINER: 2015-10-31 15:45:25.734: Serializing field: isNegative
FINER: 2015-10-31 15:45:25.734: Start serializing field: isInfinite
FINER: 2015-10-31 15:45:25.734: Property: null
FINER: 2015-10-31 15:45:25.734: Serializing field: isInfinite
FINER: 2015-10-31 15:45:25.734: Start serializing field: isNaN
FINER: 2015-10-31 15:45:25.734: Property: null
FINER: 2015-10-31 15:45:25.734: Serializing field: isNaN
FINER: 2015-10-31 15:45:25.734: Start serializing field: isFinite
FINER: 2015-10-31 15:45:25.734: Property: null
FINER: 2015-10-31 15:45:25.734: Serializing field: isFinite
FINER: 2015-10-31 15:45:25.734: Start serializing field: sign
FINER: 2015-10-31 15:45:25.734: Property: null
FINER: 2015-10-31 15:45:25.734: Serializing field: sign
Unhandled exception:
Uncaught Error: Stack Overflow
Stack Trace:
#0 DefaultSegmentRouter.handle.<handle_async_body> (package:shelf_route/src/default_segment_router.dart)
#1 _asyncCatchHelper.<anonymous closure> (dart:core-patch/core_patch.dart:14)
#2 _rootRunBinary (dart:async/zone.dart:923)
#3 _CustomZone.runBinary (dart:async/zone.dart:819)
#4 _Future._propagateToListeners.handleError (dart:async/future_impl.dart:521)
#5 _Future._propagateToListeners (dart:async/future_impl.dart:580)
#6 _Future._completeWithValue (dart:async/future_impl.dart:368)
#7 _Future._asyncComplete.<anonymous closure> (dart:async/future_impl.dart:422)
#8 _rootRun (dart:async/zone.dart:904)
#9 _CustomZone.run (dart:async/zone.dart:803)
#10 _CustomZone.runGuarded (dart:async/zone.dart:709)
#11 _CustomZone.bindCallback.<anonymous closure> (dart:async/zone.dart:734)
#12 _microtaskLoop (dart:async/schedule_microtask.dart:43)
#13 _microtaskLoopEntry (dart:async/schedule_microtask.dart:52)
#14 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:96)
#15 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:149)
#16 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:96)
#17 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:149)
#0 _rootHandleUncaughtError.<anonymous closure> (dart:async/zone.dart:895)
#1 _microtaskLoop (dart:async/schedule_microtask.dart:43)
#2 _microtaskLoopEntry (dart:async/schedule_microtask.dart:52)
#3 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:96)
#4 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:149)
Process finished with exit code 255
This is kind of problematic. Angular 2 accepts input types as either text or numbers. Because All numbers in JavaScript are floating point, i'm getting only floating point numbers back as a response.
I also just pulled down HEAD and it seems like the unit tests are not passing:
00:00 +11 -1: parse: parser simple
Cannot instantiate abstract class double: _url 'null' line null
dart:mirrors _LocalClassMirror.newInstance
lib/dartson.dart 320:25 Dartson._initiateClass
lib/dartson.dart 227:17 Dartson._convertValue
lib/dartson.dart 189:15 Dartson._fillObject.
I updated the PR to also include a fix for an infinite loop caused by trying to serialize a double
Any update on this? Still seeing bug with 0.2.5
Closed in 1.0.0-alpha
As mentioned in #26, the following code will fail: