Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Occur error when swiping on bar chart such as example 1 and 2 #313

Closed
isoppp opened this issue Apr 20, 2020 · 2 comments
Closed

Occur error when swiping on bar chart such as example 1 and 2 #313

isoppp opened this issue Apr 20, 2020 · 2 comments
Labels
Bar Chart bug Something isn't working

Comments

@isoppp
Copy link
Contributor

isoppp commented Apr 20, 2020

Describe the bug
When swiping on bar chart example 1 or 2, occur error.
I guess when swiping or tapping the gaps between bars occur errors.

════════ Exception caught by gesture ═══════════════════════════════════════════════════════════════
The following NoSuchMethodError was thrown while handling a gesture:
The getter 'length' was called on null.
Receiver: null
Tried calling: length

When the exception was thrown, this was the stack: 
#0      Object.noSuchMethod (dart:core-patch/object_patch.dart:53:5)
#1      BarChartPainter._getNearestTouchedSpot (package:fl_chart/src/chart/bar_chart/bar_chart_painter.dart:577:43)
#2      BarChartPainter.handleTouch (package:fl_chart/src/chart/bar_chart/bar_chart_painter.dart:564:9)
#3      _BarChartState.build.<anonymous closure> (package:fl_chart/src/chart/bar_chart/bar_chart.dart:84:58)
#4      GestureRecognizer.invokeCallback (package:flutter/src/gestures/recognizer.dart:182:24)
...
Handler: "onCancel"
Recognizer: PanGestureRecognizer#1bc80
  debugOwner: GestureDetector
  start behavior: start
════════════════════════════════════════════════════════════════════════════════════════════════════

To Reproduce
Use bar chart example 1 and 2 and see the following video

Screenshots

bug-report

Versions

  • which version of the Flutter are you using?
    1.18.0-dev.5.0

  • which version of the FlChart are you using?
    0.9.2 ( cloned master branch today to check example in local )

@jlubeck
Copy link
Contributor

jlubeck commented Apr 21, 2020

I'm seeing the same problem

imaNNeo added a commit that referenced this issue Apr 23, 2020
@imaNNeo imaNNeo added Bar Chart bug Something isn't working labels Apr 23, 2020
imaNNeo added a commit that referenced this issue Apr 23, 2020
imaNNeo added a commit that referenced this issue Apr 23, 2020
@imaNNeo imaNNeo mentioned this issue Apr 23, 2020
@imaNNeo
Copy link
Owner

imaNNeo commented Apr 23, 2020

Fixed in 0.9.3,
Thanks for reporting!

@imaNNeo imaNNeo closed this as completed Apr 23, 2020
ezmegy pushed a commit to ezmegy/fl_chart that referenced this issue Nov 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bar Chart bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants