Axis chart: Unsupported operation: Infinity or NaN toInt
- Dominant language
- Dart
- Stars
- 7.6k
- Forks
- 2k
- Avg merge
- 9d 1h
- Merged PRs (30d)
- 2
Description
**Describe the bug**
```dart
Crashed in non-app: double.dart in double.~/
axis_chart_helper.dart in AxisChartHelper.iterateThroughAxis at line 38 within fl_chart
Called from: async_patch.dart in _SyncStarIterator.moveNext
axis_chart_painter.dart in AxisChartPainter.drawGrid at line 117 within fl_chart
axis_chart_painter.dart in AxisChartPainter.paint at line 47 within fl_chart
bar_chart_painter.dart in BarChartPainter.paint at line 52 within fl_chart
bar_chart_renderer.dart in RenderBarChart.paint at line 91 within fl_chart
Called from: object.dart in RenderObject._paintWithContext within flutter
```
**To Reproduce**
I do not have reproduce sample - this came from Sentry and seems to be internal issue of this package. I found relevent https://github.com/imaNNeo/fl_chart/issues/857.
**Versions**
- which version of the Flutter are you using? 3.22
- which version of the FlChart are you using? ^0.66.0
Contributor guide
Research direction
Start with the stack trace location in axis_chart_helper.dart at line 38, then inspect its callers in axis_chart_painter.dart and the related issue #857. Reproduce the Infinity or NaN failure under Flutter 3.22 and fl_chart 0.66.0 if possible; done means the crash is prevented and the regression is covered by an appropriate test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- dart, flutter
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 28/100