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

chore: starter make file #13970

Merged
merged 6 commits into from
Apr 22, 2021
Merged

chore: starter make file #13970

merged 6 commits into from
Apr 22, 2021

Conversation

hughhhh
Copy link
Member

@hughhhh hughhhh commented Apr 6, 2021

SUMMARY

Using this PR to start enhancing our dev env setup! Developers will now be able to run make install to install superset and pre-commit env

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

TEST PLAN

ADDITIONAL INFORMATION

  • Has associated issue:
  • Changes UI
  • Includes DB Migration (follow approval process in SIP-59)
    • Migration is atomic, supports rollback & is backwards-compatible
    • Confirm DB migration upgrade and downgrade tested
    • Runtime estimates and downtime expectations provided
  • Introduces new feature or API
  • Removes existing feature or API

@codecov
Copy link

codecov bot commented Apr 6, 2021

Codecov Report

Merging #13970 (eee44e9) into master (8b9c142) will increase coverage by 0.77%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #13970      +/-   ##
==========================================
+ Coverage   77.87%   78.65%   +0.77%     
==========================================
  Files         935      935              
  Lines       47375    47375              
  Branches     5964     5964              
==========================================
+ Hits        36895    37262     +367     
+ Misses      10323     9980     -343     
+ Partials      157      133      -24     
Flag Coverage Δ
cypress 56.04% <ø> (+5.27%) ⬆️
hive 80.27% <ø> (ø)
javascript 67.11% <ø> (ø)
mysql 80.56% <ø> (ø)
postgres 80.60% <ø> (ø)
presto 80.29% <ø> (?)
python 81.15% <ø> (+0.16%) ⬆️
sqlite 80.16% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...set-frontend/src/dashboard/util/getDropPosition.js 90.90% <0.00%> (ø)
...-frontend/src/dashboard/components/SliceHeader.tsx 58.00% <0.00%> (ø)
...tend/src/filters/components/Time/transformProps.ts 0.00% <0.00%> (ø)
...end/src/SqlLab/components/RunQueryActionButton.tsx 64.28% <0.00%> (ø)
...src/filters/components/TimeGrain/transformProps.ts 0.00% <0.00%> (ø)
...rc/filters/components/TimeColumn/transformProps.ts 0.00% <0.00%> (ø)
...ts/nativeFilters/FilterBar/FilterControls/state.ts 80.00% <0.00%> (ø)
superset-frontend/src/SqlLab/actions/sqlLab.js 63.26% <0.00%> (+0.20%) ⬆️
superset/models/core.py 89.37% <0.00%> (+0.27%) ⬆️
.../src/explore/components/ControlPanelsContainer.tsx 97.34% <0.00%> (+0.88%) ⬆️
... and 49 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8b9c142...eee44e9. Read the comment docs.

@pull-request-size pull-request-size bot added size/M and removed size/S labels Apr 15, 2021
Copy link
Member

@betodealmeida betodealmeida left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is awesome!


venv:
# Create a virtual environment and activate it (recommended)
python3 -m venv venv # setup a python3 virtualenv
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Later we should add a check target that runs before all other targets, verifying that the user has the proper Python version installed.

Copy link
Contributor

@benjreinhart benjreinhart Apr 22, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have we considered naming the superset virtual environment something other than venv (perhaps specific to this application)? This could reduce the chance it will conflict with existing virtual environments on folks' machines.

@robdiciuccio
Copy link
Member

Cloned a fresh repo and ran make install. Got the following error:

10:25 $ make install
# Create a virtual environment and activate it (recommended)
python3 -m venv venv # setup a python3 virtualenv
source venv/bin/activate
make: source: No such file or directory
make: *** [venv] Error 1

Copy link

@stevenuray stevenuray left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Like Rob, I got the same error when running from my machine:

# Create a virtual environment and activate it (recommended)
python3 -m venv venv # setup a python3 virtualenv
source venv/bin/activate
make: source: No such file or directory
make: *** [venv] Error 1 

I assume this has to do with my use of the virtualenv plugin for pyenv. Link to the GH page. I installed it with brew.

Perhaps if we detected this condition we could make the requisite virtualenv using this plugin via pyenv virtualenv-init. This is not enough of a blocker for me to request changes, but wanted to bring it up for consideration.

Copy link
Contributor

@benjreinhart benjreinhart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If possible, it'd be good to make these commands applicable to a wide range of environments. I wonder if we can solve the issue with sourcing the virtual env?

If there's time, I agree with @betodealmeida that checking for proper pre-requisites and rendering a helpful message would be 👌🏻


venv:
# Create a virtual environment and activate it (recommended)
python3 -m venv venv # setup a python3 virtualenv
Copy link
Contributor

@benjreinhart benjreinhart Apr 22, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have we considered naming the superset virtual environment something other than venv (perhaps specific to this application)? This could reduce the chance it will conflict with existing virtual environments on folks' machines.

@hughhhh
Copy link
Member Author

hughhhh commented Apr 22, 2021

Going to merge for superset install, but going to look into the venv install and checking for prerequisites in the next PR.

@hughhhh hughhhh merged commit 01de309 into master Apr 22, 2021
QAlexBall pushed a commit to QAlexBall/superset that referenced this pull request Dec 29, 2021
* starter make file

* yea

* update docs

* lit

* remove venv from comamnds

* venv
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 1.2.0 labels Mar 12, 2024
@mistercrunch mistercrunch deleted the makefile branch March 26, 2024 16:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels size/M 🚢 1.2.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants