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

Integer filter values result in error for Boxplot visualizations #1441

Closed
3 tasks done
ananya77041 opened this issue Oct 27, 2016 · 3 comments
Closed
3 tasks done

Integer filter values result in error for Boxplot visualizations #1441

ananya77041 opened this issue Oct 27, 2016 · 3 comments

Comments

@ananya77041
Copy link

ananya77041 commented Oct 27, 2016

Make sure these boxes are checked before submitting your issue - thank you!

  • I have checked the caravel logs for python stacktraces and included it here as text if any

2016-10-27 00:05:55,609:ERROR:root:argument of type 'int' is not iterable
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/caravel/views.py", line 1183, in explore
viz_obj.get_json(),
File "/usr/local/lib/python2.7/dist-packages/caravel/viz.py", line 318, in get_json
'data': self.get_data(),
File "/usr/local/lib/python2.7/dist-packages/caravel/viz.py", line 816, in get_data
df = self.get_df()
File "/usr/local/lib/python2.7/dist-packages/caravel/viz.py", line 737, in get_df
df = super(BoxPlotViz, self).get_df(query_obj)
File "/usr/local/lib/python2.7/dist-packages/caravel/viz.py", line 153, in get_df
query_obj = self.query_obj()
File "/usr/local/lib/python2.7/dist-packages/caravel/viz.py", line 271, in query_obj
'filter': self.query_filters(),
File "/usr/local/lib/python2.7/dist-packages/caravel/viz.py", line 225, in query_filters
vals = ["'{}'".format(x) if "," in x else x for x in vals]
TypeError: argument of type 'int' is not iterable

  • I have reproduced the issue with at least the latest released version of caravel
  • I have checked the issue tracker for the same issue and I haven't found one similar

Caravel version

0.11.0

Expected results

After selecting an INTEGER type value from a Filter box dropdown selector, any Boxplot type slice to be impacted by that filter is correctly filtered.

Actual results

After selecting an INTEGER type value from a Filter box dropdown selector, any Boxplot type slice to be impacted by that filter errors out with "TypeError: argument of type 'int' is not iterable".

Steps to reproduce

  1. Set up a datasource and table with at least 1 INTEGER typed column
  2. Create Boxplot visualization and Filter box slices using the INTEGER column, and create a dashboard from these slices
  3. Attempt to use integer filter. Encounter error
@mwullink
Copy link

mwullink commented Nov 1, 2016

I am having the same issue with 0.11.0.
Is there a workaround?

@ananya77041
Copy link
Author

@mwullink Workaround I've been using so far is to cast the integer column as another type such as varchar in the table configuration. Works just fine for filtering purposes.

@mistercrunch
Copy link
Member

Notice: this issue has been closed because it has been inactive for 536 days. Feel free to comment and request for this issue to be reopened.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants