-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #294 from plotly/update-contributing
Explain versioning system
- Loading branch information
Showing
5 changed files
with
46 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,6 +13,7 @@ | |
"main": "dash_ag_grid/dash_ag_grid.min.js", | ||
"scripts": { | ||
"pre-flight-version": "python test_version.py", | ||
"pre-flight-dag-version": "python test_versioning.py", | ||
"prepublishOnly": "rimraf -rf lib && babel src --out-dir lib --copy-files --config-file ./.babelrc && rimraf --glob -rf lib/jl/ lib/*.jl", | ||
"build:js": "webpack --mode production", | ||
"build:backends": "dash-generate-components ./src/lib/components dash_ag_grid -p package-info.json --r-prefix '' --jl-prefix ''", | ||
|
@@ -24,7 +25,7 @@ | |
"private::lint.eslint": "eslint src", | ||
"private::lint.prettier": "prettier src --list-different --ignore-path=.prettierignore", | ||
"lint": "run-s private::lint.*", | ||
"dist": "npm run build && python setup.py sdist bdist_wheel" | ||
"dist": "npm run build && run-s pre-flight-dag-version && python setup.py sdist bdist_wheel" | ||
}, | ||
"author": "Plotly <[email protected]>", | ||
"license": "MIT", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
from packaging.version import parse | ||
import dash_ag_grid as dag | ||
|
||
|
||
""" | ||
Test that the major and minor versions of bundled Ag Grid align with | ||
the major and minor versions of the Python package. | ||
See CONTRIBUTING.md for more information on versioning this package. | ||
""" | ||
ag_version = parse(dag.grid_version) | ||
dash_ag_version = parse(dag.__version__) | ||
|
||
if not (ag_version.major == dash_ag_version.major and ag_version.minor == dash_ag_version.minor): | ||
raise Exception("There is a version mismatch in DAG and AG-Grid, check your package.json and adjust") | ||
try: | ||
print('DAG version and AG-Grid are in perfect harmony 🎉') | ||
except: | ||
print('DAG version and AG-Grid are in perfect harmony :)') |