Add a Python data source with Redash

Introduction

A reminder of the settings that enable Redash to use Python data sources.

environment


$sw_vers
ProductName:	Mac OS X
ProductVersion:	10.13.6
BuildVersion:	17G14042

$docker --version
Docker version 20.10.0, build 7287ab3

I installed Redash locally based on Docker. The version of Redash uses v8.0.0. The installation method is here

Settings required to use a Python data source

Python data source is not available by default, so to enable it

redash/settings/__init__.default listed in py_query_to runners



#### **`"redash.query_runner.python"To add.`**

redash/settings/__init__.py



(abridgement)

322 
323 # Query Runners
324 default_query_runners = [                                                                                                                                   
325     "redash.query_runner.python",
326     "redash.query_runner.athena",
327     "redash.query_runner.big_query",
328     "redash.query_runner.google_spreadsheets",
329     "redash.query_runner.graphite",
330     "redash.query_runner.mongodb",
 

Then run docker-compose up. `Docker-compose restart` if it is already running.

Verification

After accessing localhost: 5000 with a browser and opening the Redash screen, Settings → Data Sources tab → + New Data Source. You can now select a Python data source by typing "Python" in the search window.

python_datasource.png

Recommended Posts

Add a Python data source with Redash
Data analysis with Python
A story stuck with handling Python binary data
Folium: Visualize data on a map with Python
Extract data from a web page with Python
Sample data created with python
Get financial data with python (then a little tinkering)
Execute raw SQL using python data source with redash and display the result
Get Youtube data with python
Make a fortune with Python
A server that echoes data POSTed with flask / python
Create a directory with python
Read json data with python
A memo that reads data from dashDB with Python & Spark
Problems when using Elasticsearch as a data source in Redash
[Python] What is a with statement?
Operate a receipt printer with python
A python graphing manual with Matplotlib.
Let's make a GUI with python.
Install Python from source with Ansible
Solve ABC166 A ~ D with Python
Create a virtual environment with Python!
[Python] Get economic data with DataReader
I made a fortune with Python.
Building a virtual environment with Python 3
Solve ABC168 A ~ C with Python
Python data structures learned with chemoinformatics
Make a recommender system with python
[Python] Generate a password with Slackbot
Solve ABC162 A ~ C with Python
Solve ABC167 A ~ C with Python
Solve ABC158 A ~ C with Python
Easy data visualization with Python seaborn.
Let's make a graph with python! !!
Process Pubmed .xml data with python
Data analysis starting with python (data visualization 1)
[Python] Inherit a class with class variables
I made a daemon with Python
Data analysis starting with python (data visualization 2)
Write a batch script with Python3.5 ~
Python application: Data cleansing # 2: Data cleansing with DataFrame
Make multiple numerical elevation data into a single picture with Python
Get data from MySQL on a VPS with Python 3 and SQLAlchemy
How to update a Tableau packaged workbook data source using Python
[Python] Read a csv file with a large data size using a generator
Try to get CloudWatch metrics with re: dash python data source
Create a USB boot Ubuntu with a Python environment for data analysis
[Pyenv] Building a python environment with ubuntu 16.04
Get additional data in LDAP with python
Data pipeline construction with Python and Luigi
Spiral book in Python! Python with a spiral book! (Chapter 14 ~)
Create a Python function decorator with Class
Creating a simple PowerPoint file with Python
[Python] A program that creates stairs with #
Building a Python3 environment with Amazon Linux2
[Note] Get data from PostgreSQL with Python
Let's make a shiritori game with Python
Install Python as a Framework with pyenv
Build a blockchain with Python ① Create a class
How to add a package with PyCharm
Create a dummy image with Python + PIL.