Skip to content

Commit 556dd53

Browse files
committed
merging latest changes from master
2 parents 3cb9303 + 60ada7c commit 556dd53

File tree

207 files changed

+502
-15076
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

207 files changed

+502
-15076
lines changed

.circleci/config.yml

+33-74
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,13 @@ commands:
1818
command: |
1919
python -m venv venv
2020
. venv/bin/activate
21-
pip install --upgrade pip wheel
21+
pip install -e .
2222
pip install -r ./test_requirements/requirements_<<parameters.py>>_core.txt
2323
- run:
2424
name: Test core
2525
command: |
2626
. venv/bin/activate
27-
pytest plotly/tests/test_core
27+
pytest tests/test_core
2828
no_output_timeout: 20m
2929

3030
test_optional:
@@ -41,7 +41,7 @@ commands:
4141
command: |
4242
python -m venv venv
4343
. venv/bin/activate
44-
pip install --upgrade pip wheel
44+
pip install -e .
4545
pip install -r ./test_requirements/requirements_<<parameters.py>>_optional.txt
4646
cd js
4747
npm ci
@@ -55,36 +55,36 @@ commands:
5555
name: Test core
5656
command: |
5757
. venv/bin/activate
58-
pytest plotly/tests/test_core
58+
pytest tests/test_core
5959
no_output_timeout: 20m
6060
- run:
6161
name: Test optional
6262
command: |
6363
. venv/bin/activate
64-
pytest plotly/tests/test_optional
64+
pytest tests/test_optional
6565
no_output_timeout: 40m
6666
- run:
6767
name: Test utils
6868
command: |
6969
. venv/bin/activate
70-
pytest _plotly_utils/tests/
70+
pytest tests/test_plotly_utils/
7171
no_output_timeout: 20m
7272
- run:
7373
name: Test io
7474
command: |
7575
. venv/bin/activate
76-
pytest plotly/tests/test_io
76+
pytest tests/test_io
7777
no_output_timeout: 20m
7878
- run:
7979
name: Test dependencdies not imported
8080
command: |
8181
. venv/bin/activate
82-
pytest -x test_init/test_dependencies_not_imported.py
82+
python -m pytest -x test_init/test_dependencies_not_imported.py
8383
- run:
8484
name: Test lazy imports
8585
command: |
8686
. venv/bin/activate
87-
pytest -x test_init/test_lazy_imports.py
87+
python -m pytest -x test_init/test_lazy_imports.py
8888
test_orca:
8989
parameters:
9090
py:
@@ -99,7 +99,6 @@ commands:
9999
command: |
100100
python -m venv venv
101101
. venv/bin/activate
102-
pip install --upgrade pip wheel
103102
pip install -r ./test_requirements/requirements_<<parameters.py>>_optional.txt
104103
- run:
105104
name: Install plotly-geo
@@ -118,10 +117,10 @@ commands:
118117
name: Test orca
119118
command: |
120119
. venv/bin/activate
121-
pytest plotly/tests/test_orca
120+
pytest tests/test_orca
122121
no_output_timeout: 20m
123122
- store_artifacts:
124-
path: plotly/tests/test_orca/images/linux/failed
123+
path: tests/test_orca/images/linux/failed
125124

126125
jobs:
127126
check-code-formatting:
@@ -269,7 +268,6 @@ jobs:
269268
command: |
270269
python -m venv venv
271270
. venv/bin/activate
272-
pip install --upgrade pip wheel
273271
pip install -e .
274272
pip install plotly-geo
275273
pip install -r test_requirements/requirements_39_pandas_2_optional.txt
@@ -278,28 +276,28 @@ jobs:
278276
name: Build html figures (Pandas 2)
279277
command: |
280278
. venv/bin/activate
281-
python test/percy/plotly-express.py
279+
python tests/percy/plotly-express.py
282280
- run:
283281
name: Build html figures (Pandas 1) and compare
284282
command: |
285283
. venv/bin/activate
286-
mkdir test/percy/pandas2
287-
mv test/percy/*.html test/percy/pandas2/
284+
mkdir tests/percy/pandas2
285+
mv tests/percy/*.html tests/percy/pandas2/
288286
# 1.1 is the earliest minor with Py3.9 wheels
289287
pip install "pandas==1.1.5"
290-
python test/percy/plotly-express.py
291-
python test/percy/compare-pandas.py
292-
rm -rf test/percy/pandas2
288+
python tests/percy/plotly-express.py
289+
python tests/percy/compare-pandas.py
290+
rm -rf tests/percy/pandas2
293291
- run:
294292
name: Run percy snapshots
295293
command: |
296294
npm i @percy/cli
297-
npx percy snapshot -c test/percy/snapshots.yml test/percy/
298-
rm test/percy/*.html
295+
npx percy snapshot -c tests/percy/snapshots.yml tests/percy/
296+
rm tests/percy/*.html
299297
300298
plotlyjs_dev_build:
301299
docker:
302-
- image: cimg/python:3.8-node
300+
- image: cimg/python:3.11-node
303301
environment:
304302
LANG: en_US.UTF-8
305303
resource_class: large
@@ -311,25 +309,20 @@ jobs:
311309
command: |
312310
python -m venv venv
313311
. venv/bin/activate
314-
pip install --upgrade pip wheel
315-
pip install -r ./test_requirements/requirements_38_core.txt black inflect
312+
pip install -e .
313+
pip install -r ./test_requirements/requirements_311_core.txt black inflect
316314
pip install jupyterlab
317-
- run:
318-
name: Update jupyter widget plotly.js version
319-
command: |
320-
. venv/bin/activate
321-
python setup.py updateplotlywidgetversion
322315
- run:
323316
name: Update plotly.js to dev
324317
command: |
325318
. venv/bin/activate
326-
python setup.py updateplotlyjsdev
319+
python commands.py updateplotlyjsdev
327320
- run:
328321
name: Test core
329322
command: |
330323
. venv/bin/activate
331324
locale
332-
pytest -k 'not nodev' plotly/tests/test_core
325+
pytest -k 'not nodev' tests/test_core
333326
no_output_timeout: 20m
334327
- run:
335328
name: Commit
@@ -343,36 +336,27 @@ jobs:
343336
name: Build source distribution packages
344337
command: |
345338
. venv/bin/activate
346-
python setup.py sdist
339+
pip install build
340+
python -m build --sdist --wheel -o dist
347341
when: always
348342
- store_artifacts:
349343
path: dist/
350344

351345
full_build:
352346
docker:
353-
- image: continuumio/miniconda3:24.3.0-0
347+
- image: cimg/python:3.11-node
354348
environment:
355349
LANG: en_US.UTF-8
356350
resource_class: large
357351

358352
steps:
359353
- checkout
360354

361-
- run:
362-
name: Create conda environment
363-
command: |
364-
conda config --remove channels defaults
365-
conda config --add channels conda-forge
366-
conda create -n env --yes python=3.9 conda-build=3.28.4 conda-verify
367-
conda install -n env -c conda-forge jupyterlab nodejs=16
368-
conda init bash
369-
mkdir output
370-
371355
- run:
372356
name: initial NPM Build
373357
command: |
374-
eval "$(conda shell.bash hook)"
375-
conda activate env
358+
python -m venv venv
359+
. venv/bin/activate
376360
cd js
377361
npm ci
378362
npm run build
@@ -381,41 +365,17 @@ jobs:
381365
- run:
382366
name: PyPI Build
383367
command: |
384-
eval "$(conda shell.bash hook)"
385-
conda activate env
386-
python setup.py sdist bdist_wheel
387-
cp -R dist output/dist
388-
git status
389-
390-
- run:
391-
name: Conda Build
392-
command: |
393-
eval "$(conda shell.bash hook)"
394-
conda activate env
395-
conda build recipe/
396-
mv /opt/conda/envs/env/conda-bld/noarch/plotly*.tar.bz2 output/
368+
. venv/bin/activate
369+
pip install build
370+
python -m build --sdist --wheel -o dist
371+
cp -R dist output
397372
git status
398373
399-
- run:
400-
name: Build Widget javascript bundle
401-
command: |
402-
eval "$(conda shell.bash hook)"
403-
conda activate env
404-
cd js
405-
npm ci
406-
npm run build
407-
408374
- run:
409375
name: Zip output
410376
command: |
411377
tar czf output.tgz output
412378
413-
- run:
414-
name: Git Diff
415-
command: |
416-
git status
417-
git diff
418-
419379
- store_artifacts:
420380
path: output.tgz
421381

@@ -445,7 +405,6 @@ jobs:
445405
cd doc
446406
python -m venv venv
447407
. venv/bin/activate
448-
pip install --upgrade pip wheel
449408
pip uninstall -y plotly
450409
pip install -r requirements.txt
451410
if [ "${CIRCLE_BRANCH}" != "doc-prod" ]; then

.flake8

-2
This file was deleted.

.gitattributes

-1
This file was deleted.

.github/pull_request_template.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ below :-).
2727
2828
## Code PR
2929
30-
- [ ] I have read through the [contributing notes](https://github.com/plotly/plotly.py/blob/master/contributing.md) and understand the structure of the package. In particular, if my PR modifies code of `plotly.graph_objects`, my modifications concern the `codegen` files and not generated files.
30+
- [ ] I have read through the [contributing notes](https://github.com/plotly/plotly.py/blob/master/CONTRIBUTING.md) and understand the structure of the package. In particular, if my PR modifies code of `plotly.graph_objects`, my modifications concern the `codegen` files and not generated files.
3131
- [ ] I have added tests (if submitting a new feature or correcting a bug) or
3232
modified existing tests.
3333
- [ ] For a new feature, I have added documentation examples in an existing or

.gitignore

+6-9
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
0
22
0.html
33
iframe_figures/
4-
plotly/tests/test_orca/images/linux/failed/
4+
tests/test_orca/images/linux/failed/
55

66
*.egg-info
77

@@ -49,20 +49,17 @@ plotly.egg-info/
4949
# macOS utility file
5050
**/.DS_Store
5151

52-
plotly/tests/test_orca/images/*/failed
53-
plotly/tests/test_orca/images/*/tmp
54-
/plotly-package/plotly/tests/test_core/test_offline/plotly.min.js
52+
tests/test_orca/images/*/failed
53+
tests/test_orca/images/*/tmp
54+
tests/test_core/test_offline/plotly.min.js
5555
temp-plot.html
5656
.vscode
5757
doc/python/.ipynb_checkpoints
5858
doc/python/.mapbox_token
5959
doc/.ipynb_checkpoints
6060
tags
6161
doc/check-or-enforce-order.py
62-
63-
jupyterlab_plotly/labextension/
64-
jupyterlab_plotly/nbextension/index.js*
6562
plotly/package_data/widgetbundle.js
6663

67-
test/percy/*.html
68-
test/percy/pandas2/*.html
64+
tests/percy/*.html
65+
tests/percy/pandas2/*.html

.pre-commit-config.yaml

-6
This file was deleted.

CHANGELOG.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -716,7 +716,7 @@ This version includes several performance improvements ([#2368](https://github.c
716716
- Introduce range breaks on date axes (for example, to remove week-ends) via `layout.xaxis.rangebreaks`
717717
- Introduce a new unified x (or y) hovermode (`layout.hovermode="x unified"`), in which the hover box shows the information for all traces at a given x (or y) position
718718
- Add `node.customdata` and `link.customdata` to sankey traces
719-
- Updated [contributing notes](https://github.com/plotly/plotly.py/blob/master/contributing.md) for more explanations on how to contribute to plotly.py [#2290](https://github.com/plotly/plotly.py/pull/2290). Please give feedback on these notes!
719+
- Updated [contributing notes](https://github.com/plotly/plotly.py/blob/master/CONTRIBUTING.md) for more explanations on how to contribute to plotly.py [#2290](https://github.com/plotly/plotly.py/pull/2290). Please give feedback on these notes!
720720
- Updated documentation examples [#2325](https://github.com/plotly/plotly.py/pull/2325), and to show how to color links in Sankey diagrams [#2291](https://github.com/plotly/plotly.py/pull/2291).
721721
- Special thanks to [@SylwiaOliwia2](https://github.com/SylwiaOliwia2) and [@dangercrow](https://github.com/dangercrow) for improving our documentation!
722722

@@ -1738,7 +1738,7 @@ This is a major version with many exciting updates. See the [Introducing plotly.
17381738
- Error message for `plotly.figure_factory.create_choropleth` is now helpful to Anaconda users who do not have the correct modules installed for the County Choropleth figure factory.
17391739

17401740
### Changed / Deprecated
1741-
Please see the [migration guid](migration-guide.md) for a full list of the changes and deprecations in version 3.0.0
1741+
Please see the [migration guide](MIGRATION_GUIDE.md) for a full list of the changes and deprecations in version 3.0.0
17421742

17431743

17441744

0 commit comments

Comments
 (0)