Steps to install superset under win10 system

Steps to install superset under win10 system

Superset is a lightweight self-service BI framework with elegant interface and dynamic data generation based on data tables as its main features.

1. Environment

Python 3.7 on Windows 10 64-bit

2. Installation steps

Install Python

It is recommended to install Python 3.7 version, Python official website: https://www.python.org/downloads/release/python-373/

Download 64-bit Python and download python-3.7.3-amd64.exe. You can directly use the exe installation package. During the installation process, select Add to Environment Variables.

Install VS2015

Some libraries that Superset depends on need to be compiled using Microsoft Visual C++ 2010.

Directly install Visual C++ 2015 Build Tools: http://xiazai.jb51.net/201912/yuanma/VisualBuild_Tools.rar

Install superset

First cmd to enter the dos interface

(1) pip install virtualenv

Use virtualenv to create a working directory on drive D, for example: D:\vir_env

Enter the following command in CMD:

d:
cd D:\vir_env
virtualenv env

Activate environment: env\Scripts\activate

insert image description here

(2) Download sasl according to the python version and install it. Download address: http://www.lfd.uci.edu/~gohlke/pythonlibs/#sasl

Select the appropriate version to download. For example, if the currently installed Python is version 3.7 and the system is 64-bit, download sasl-0.2.1-cp37-cp37m-win_amd64.whl.

Be sure to check the version here, otherwise the installation will fail and an error will be reported (sasl.h cannot be found). This article installs 3.7;

Copy it to the D:\vir_env path and execute the command

pip install sasl-0.2.1-cp37-cp37m-win_amd64.whl

(3) Install superset

pip install superset

Possible problem 1:

insert image description here

Solution:

a. Find the corresponding package in https://www.lfd.uci.edu/~gohlke/pythonlibs/, the py version and the system version must match, and download it to the D:\vir_env directory

b. Install the corresponding whl file

pip install filename

Possible problem 2:

error: could not create 'build\bdist.win-amd64\wheel.\superset\static\assets\dist\vendors-deckgl\layers\arc-deckgl\layers\geojson-deckgl\layers\grid-deckgl\layers\hex-deckgl\layers\p-39b91eb9.81565bc93ff56be4e334.chunk.js': No such file or directory ---------------------------------------- ERROR: Failed building wheel for superset

Solution:

Enable long path support on Windows:

Open the registry editor: regedit

Find the following path: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSytem

Find the following key value: LongPathsEnabled

Change the value to 1: The default is 0, which is not enabled.

insert image description here

(4) Create an administrator account

fabmanager create-admin --app superset

Possible problems: Error Was unable to import superset Error: cannot import name '_maybe_box_datetimelike'

This is caused by the pandas library version being too high. You need to install a lower version of the pandas library.

Solution:

a. pip uninstall pandas

b. pip install pandas==0.23.4

Create Success

insert image description here

(5) Set the working directory

cd D:\vir_env\env\Lib\site-packages\superset\bin

(6) Initialize the database

Python superset db upgrade

Possible problems

InvalidRequestError: Can't determine which FROM clause to join from, there are multiple FROMS which can join to this entity. Try adding an explicit ON clause to help resolve the ambiguity. 报错误.png

Solution:

This is caused by the SQLAlchemy library version being too high. You need to install a lower version of the SQLAlchemy library.

pip uninstall SQLAlchemypip install SQLAlchemy==1.3.5

Then re-run

Python superset db upgrade

(7) Load test example

Python superset load_examples

Possible problem 1:

ConnectionRefusedError: [WinError 10061] No connection could be made because the target machine actively refused it.

Solution: Open the Network and Sharing Center, click Internet Options, select LAN Settings in Connections, check Automatically detect settings, and then confirm;

Possible problem 2:

It may fail due to network conditions. Just switch networks and try a few more times.

(8) Initialize roles and permissions

Python superset init

(9) Enable the service

Python superset runserver -d

Possible problems:

Error: No such command "runserver".

Solution:

Start it with the following command:

Python superset run -p 8088

(10) Open http://localhost:8088 and log in using the username and password you set previously;

Summarize

The above are the steps for installing superset under win10 system introduced by the editor. I hope it will be helpful to everyone. If you have any questions, please leave me a message and the editor will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website! If you find this article helpful, please feel free to reprint it and please indicate the source. Thank you!

You may also be interested in:
  • Detailed tutorial on installation and deployment of superset in Linux and Windows

<<:  Detailed explanation of the principle and example of the new operator in JavaScript

>>:  Mini Program Development to Implement Unified Management of Access_Token

Recommend

Use of Linux gzip command

1. Command Introduction The gzip (GNU zip) comman...

Element sample code to implement dynamic table

Table of contents 【Code background】 【Code Impleme...

Vue implements 3 ways to switch tabs and switch to maintain data status

3 ways to implement tab switching in Vue 1. v-sho...

Make a nice flip login and registration interface based on html+css

Make a nice flip login and registration interface...

How to automatically execute SQL statements when MySQL in Docker starts

When creating a MySQL container with Docker, some...

How to migrate the data directory in Docker

Table of contents View Disk Usage Disk Cleanup (D...

mysqldump parameters you may not know

In the previous article, it was mentioned that th...

Detailed explanation of the use of React.cloneElement

Table of contents The role of cloneElement Usage ...

Introduction to TypeScript interfaces

Table of contents 1. Interface definition 2. Attr...

Nginx prohibits direct access via IP and redirects to a custom 500 page

Directly to the configuration file server { liste...

Detailed explanation of common operations of Docker images and containers

Image Accelerator Sometimes it is difficult to pu...

JavaScript event capture bubbling and capture details

Table of contents 1. Event Flow 1. Concept 2. DOM...

React+Koa example of implementing file upload

Table of contents background Server Dependencies ...

Summary of Linux ps and pstree command knowledge points

The ps command in Linux is the abbreviation of Pr...