johnomernik / jupyter_drill Goto Github PK
View Code? Open in Web Editor NEWA Jupyter Data Integration for Apache Drill using the extensible integration framework.
License: Apache License 2.0
A Jupyter Data Integration for Apache Drill using the extensible integration framework.
License: Apache License 2.0
I seem to be getting an error when I try to execute a query. The error seems to be inconsistent in that some plugins cause this error and others do not. I did validate the query and it is correct.
Here is the stack trace:
0 Records in Approx 0 seconds
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-12-22bc49393c40> in <module>
----> 1 get_ipython().run_cell_magic('drill', '', 'SELECT useragent\nFROM splunk.main\nLIMIT 50\n')
~/anaconda3/lib/python3.7/site-packages/IPython/core/interactiveshell.py in run_cell_magic(self, magic_name, line, cell)
2379 with self.builtin_trap:
2380 args = (magic_arg_s, cell)
-> 2381 result = fn(*args, **kwargs)
2382 return result
2383
<decorator-gen-126> in drill(self, line, cell)
~/anaconda3/lib/python3.7/site-packages/IPython/core/magic.py in <lambda>(f, *a, **k)
185 # but it's overkill for just that one bit of state.
186 def magic_deco(arg):
--> 187 call = lambda f, *a, **k: f(*a, **k)
188
189 if callable(arg):
~/anaconda3/lib/python3.7/site-packages/drill_core/drill_base.py in drill(self, line, cell)
369 print("I am sorry, I don't know what you want to do with your line magic, try just %" + self.name_str + "for help options")
370 else: # This is run is the cell is not none, thus it's a cell to process - For us, that means a query
--> 371 self.handleCell(cell)
372
~/anaconda3/lib/python3.7/site-packages/integration_core/integration_base.py in handleCell(self, cell)
172 else:
173 # Hack to hide the index field
--> 174 display(qgrid.show_grid(result_df, grid_options={'forceFitColumns': False, 'defaultColumnWidth': int(self.opts['qg_defaultColumnWidth'][0])}, column_definitions={ 'index': { 'maxWidth': 0, 'minWidth': 0, 'width': 0 } }))
175
176 else:
~/anaconda3/lib/python3.7/site-packages/qgrid/grid.py in show_grid(data_frame, show_toolbar, precision, grid_options, column_options, column_definitions, row_edit_callback)
498 elif not isinstance(data_frame, pd.DataFrame):
499 raise TypeError(
--> 500 "data_frame must be DataFrame or Series, not %s" % type(data_frame)
501 )
502
TypeError: data_frame must be DataFrame or Series, not <class 'NoneType'>
Here is the code:
from drill_core import Drill
ipy = get_ipython()
Drill = Drill(ipy, drill_embedded=True, pd_display_grid="qgrid")
ipy.register_magics(Drill)
# New Cell
%drill connect
#New Cell
%%drill
SELECT * FROM ....
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.