You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: RELEASE.md
+18-7Lines changed: 18 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -110,9 +110,9 @@ Once these are verified working, you can move on to publishing the release.
110
110
111
111
### Publishing to PyPI
112
112
113
-
The final step is to publish the release to PyPI. **You will need special permissions from Plotly leadership to do this.**.
113
+
The final step is to publish the release to PyPI. **You will need special permissions from Plotly leadership to do this.**
114
114
115
-
You must install first install [Twine](https://pypi.org/project/twine/) (`pip install twine`) if not already installed.
115
+
You must first install [Twine](https://pypi.org/project/twine/) (`pip install twine`) if not already installed.
116
116
117
117
Publishing to PyPI:
118
118
```bash
@@ -132,10 +132,21 @@ Your account must have permissions to publish to the `plotly` project on PyPI.
132
132
start by doing it first if not. Then merge `main` into `doc-prod` to deploy the doc related
133
133
to features in the release.
134
134
3. in a clone of the [`graphing-library-docs` repo](https://github.com/plotly/graphing-library-docs):
135
-
1. bump the version of plotly.py in `_data/pyversion.json`
135
+
1. bump the version of plotly.py in `_data/pyversion.json`
136
136
2. bump the version of plotly.js with `cd _data && python get_plotschema.py <PLOTLY.JS VERSION>` fixing any errors that come up.
137
-
- If plotly.js contains any new traces or trace or layout attributes, you'll get a warning `“missing key in attributes: <attribute-name>`. To resolve, add the attribute to the relevant section in `/_data/orderings.json` in the position you want it to appear in the reference docs.
138
-
3. rebuild the Algolia `schema` index with `ALGOLIA_API_KEY=<key> make update_ref_search`
137
+
138
+
**About `_data/orderings.json`:**`get_plotschema.py` downloads the raw `plot-schema.json` from the specified plotly.js release and uses `_data/orderings.json` (which lives in `graphing-library-docs`, not plotly.js) to determine the order in which traces, trace attributes, and layout attributes appear in the [reference documentation](https://plotly.com/python/reference/). The file has three sections:
-`traces` — order of trace types (e.g. `scatter`, `bar`, `pie`)
141
+
-`trace_attr_order` — order of attributes shared across traces
142
+
143
+
If plotly.js adds new traces or trace/layout attributes that aren't listed in `orderings.json`, `get_plotschema.py` prints a warning like `missing key in attributes: <attribute-name>` and appends the missing entry to the end of its section. To resolve:
144
+
145
+
- Add each missing attribute to the appropriate section of `/_data/orderings.json` in the position you want it to appear in the reference docs.
146
+
- When in doubt about trace-attribute placement, match plotly.js's native order: open the regenerated `_data/plotschema.json` and find where plotly.js itself places the attribute (e.g. inspect a representative trace's `attributes` keys in order). Following the native order keeps related attributes grouped (for example, `texttemplate` → `texttemplatefallback` → `texttemplatesrc`).
147
+
- For new top-level layout attributes, group them with semantically related entries rather than appending to the end (for example, a new click-behavior attribute like `clickanywhere` belongs next to `clickmode`).
148
+
- Re-run `python get_plotschema.py <PLOTLY.JS VERSION>` after editing `orderings.json` and confirm the warnings are gone.
149
+
3. Rebuild the Algolia `schema` index with `ALGOLIA_API_KEY=<key> make update_ref_search`
139
150
4. Rebuild the Algolia `python` index with `ALGOLIA_API_KEY=<key> make update_python_search`
140
151
5. Commit and push the changes to `master` in that repo
141
152
@@ -158,5 +169,5 @@ PyPI RC (no special flags, just the `rc1` suffix):
158
169
(plotly_dev) $ twine upload dist/plotly-X.Y.Zrc1*
159
170
```
160
171
161
-
The `--tag next` part ensures that users won't install this version unless
162
-
they explicitly ask for the version or for the version with the `next` tag.
172
+
The `rc1` suffix ensures that users won't install this version by default —
173
+
they must explicitly request it (e.g., `pip install plotly==X.Y.Zrc1`).
0 commit comments