Skip to content

Commit 58c7c3c

Browse files
committed
Squashed commit of the following:
commit 509cb05 Author: David Meyer <dihm.meyer@gmail.com> Date: Mon Mar 16 13:26:20 2026 -0400 Missed some pin updates :( commit 2a54557 Merge: fc0c2d6 1adcf29 Author: David Meyer <dihm@users.noreply.github.com> Date: Mon Mar 16 13:22:18 2026 -0400 Merge pull request #120 from dihm/release_fixes Release fixes commit 1adcf29 Author: David Meyer <dihm.meyer@gmail.com> Date: Mon Mar 16 13:18:24 2026 -0400 Remove version guard on conda-build now that setuptools-conda supports modern versions. commit cd0eb42 Author: David Meyer <dihm.meyer@gmail.com> Date: Mon Mar 16 13:18:00 2026 -0400 Update setup-conda arguments commit 4b2cfeb Author: David Meyer <dihm.meyer@gmail.com> Date: Mon Mar 16 13:17:41 2026 -0400 Bump action pins commit fc0c2d6 Merge: d20e495 6506b7e Author: David Meyer <dihm@users.noreply.github.com> Date: Mon Mar 16 12:53:19 2026 -0400 Merge pull request #119 from dihm/pyside6 More PySide6 compatibility changes commit 6506b7e Author: David Meyer <dihm.meyer@gmail.com> Date: Mon Dec 1 15:41:13 2025 -0500 Ensure header view widget text follows OS theme coloring commit 1d015e5 Author: David Meyer <dihm.meyer@gmail.com> Date: Fri Nov 21 16:54:35 2025 -0500 Change deprecated `QFontMetrics.width` to `QFontMetrics.horizontalAdvance` commit d20e495 Merge: afae8e0 1a54ed8 Author: David Meyer <dihm@users.noreply.github.com> Date: Tue Aug 19 16:56:30 2025 -0400 Merge pull request #118 from dihm/rtd_fixes Sphinx autosummary fixes commit 1a54ed8 Author: David Meyer <dihm.meyer@gmail.com> Date: Tue Aug 19 16:53:20 2025 -0400 Minor change to re-trigger RTD build. commit f3c594d Author: David Meyer <dihm.meyer@gmail.com> Date: Tue Aug 19 16:33:18 2025 -0400 Ensure intersphinx mapping isn't used for current module. commit 40b45e9 Author: David Meyer <dihm.meyer@gmail.com> Date: Tue Aug 19 16:32:25 2025 -0400 Re-add autosummary template, and update it so it is compatible. commit afae8e0 Author: David Meyer <dihm@users.noreply.github.com> Date: Sat Aug 2 23:22:43 2025 -0400 Fix source-suffix warning in sphinx build. commit 7a33e4a Author: David Meyer <dihm@users.noreply.github.com> Date: Sat Aug 2 23:03:33 2025 -0400 Add version to index page New sphinx theme >2 does not automatically display the version in the sidebar.
1 parent d9bc9db commit 58c7c3c

7 files changed

Lines changed: 64 additions & 49 deletions

File tree

.github/workflows/release.yml

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434

3535
steps:
3636
- name: Checkout
37-
uses: actions/checkout@v4
37+
uses: actions/checkout@v6
3838
with:
3939
fetch-depth: 0
4040

@@ -43,7 +43,7 @@ jobs:
4343
run: git tag -d $(git tag --points-at HEAD)
4444

4545
- name: Install Python
46-
uses: actions/setup-python@v5
46+
uses: actions/setup-python@v6
4747
with:
4848
python-version: '3.x'
4949

@@ -222,7 +222,7 @@ jobs:
222222

223223
steps:
224224
- name: Checkout
225-
uses: actions/checkout@v4
225+
uses: actions/checkout@v6
226226
with:
227227
fetch-depth: 0
228228

@@ -231,7 +231,7 @@ jobs:
231231
run: git tag -d $(git tag --points-at HEAD)
232232

233233
- name: Install Python
234-
uses: actions/setup-python@v5
234+
uses: actions/setup-python@v6
235235
with:
236236
python-version: ${{ env.DEFAULT_PYTHON }}
237237

@@ -252,7 +252,7 @@ jobs:
252252

253253
- name: Upload artifact
254254
if: env.PURE == 'false' || strategy.job-index == 0
255-
uses: actions/upload-artifact@v4
255+
uses: actions/upload-artifact@v6
256256
with:
257257
name: dist-${{ matrix.os }}
258258
path: ./dist
@@ -264,7 +264,7 @@ jobs:
264264
miniforge-version: "latest"
265265
auto-update-conda: true
266266
conda-remove-defaults: true
267-
auto-activate-base: true
267+
auto-activate: true
268268
activate-environment: ""
269269

270270
- name: Conda package
@@ -274,11 +274,11 @@ jobs:
274274
# Short path to minimise odds of hitting Windows max path length
275275
CONDA_BUILD_ARGS+=" --croot ${{ runner.temp }}\cb"
276276
fi
277-
conda install -c labscript-suite setuptools-conda "conda-build<25"
277+
conda install -c labscript-suite setuptools-conda
278278
setuptools-conda build $CONDA_BUILD_ARGS .
279279
280280
- name: Upload artifact
281-
uses: actions/upload-artifact@v4
281+
uses: actions/upload-artifact@v6
282282
with:
283283
name: conda_packages-${{ matrix.os }}
284284
path: ./conda_packages
@@ -298,7 +298,7 @@ jobs:
298298

299299
steps:
300300
- name: Download Artifact
301-
uses: actions/download-artifact@v4
301+
uses: actions/download-artifact@v8
302302
with:
303303
pattern: dist*
304304
path: ./dist
@@ -332,7 +332,7 @@ jobs:
332332

333333
steps:
334334
- name: Download Artifact
335-
uses: actions/download-artifact@v4
335+
uses: actions/download-artifact@v8
336336
with:
337337
pattern: dist*
338338
path: ./dist
@@ -360,7 +360,7 @@ jobs:
360360

361361
steps:
362362
- name: Download Artifact
363-
uses: actions/download-artifact@v4
363+
uses: actions/download-artifact@v8
364364
with:
365365
pattern: dist*
366366
path: ./dist
@@ -378,7 +378,7 @@ jobs:
378378

379379
steps:
380380
- name: Download Artifact
381-
uses: actions/download-artifact@v4
381+
uses: actions/download-artifact@v8
382382
with:
383383
pattern: conda_packages-*
384384
path: ./conda_packages
@@ -390,7 +390,7 @@ jobs:
390390
miniforge-version: "latest"
391391
auto-update-conda: true
392392
conda-remove-defaults: true
393-
auto-activate-base: true
393+
auto-activate: true
394394
activate-environment: ""
395395

396396
- name: Install Anaconda cloud client
@@ -417,7 +417,7 @@ jobs:
417417

418418
steps:
419419
- name: Download Artifact
420-
uses: actions/download-artifact@v4
420+
uses: actions/download-artifact@v8
421421
with:
422422
pattern: conda_packages-*
423423
path: ./conda_packages
@@ -429,7 +429,7 @@ jobs:
429429
miniforge-version: "latest"
430430
auto-update-conda: true
431431
conda-remove-defaults: true
432-
auto-activate-base: true
432+
auto-activate: true
433433
activate-environment: ""
434434

435435
- name: Install Anaconda cloud client
Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,9 @@
11
{{ fullname | escape | underline}}
22

3-
{% block submodules %}
4-
{% if modules %}
5-
.. rubric:: {{ _('Sub-Modules') }}
6-
.. autosummary::
7-
:toctree:
8-
:template: autosummary-module.rst
9-
:recursive:
10-
11-
{% for item in modules %}
12-
{{ item }}
13-
{%- endfor %}
14-
{% endif %}
15-
{% endblock %}
16-
173
.. automodule:: {{ fullname }}
184

195
{% block attributes %}
20-
{% if attributes %}
6+
{%- if attributes %}
217
.. rubric:: {{ _('Module Attributes') }}
228

239
.. autosummary::
@@ -26,10 +12,10 @@
2612
{{ item }}
2713
{%- endfor %}
2814
{% endif %}
29-
{% endblock %}
15+
{%- endblock %}
3016

31-
{% block functions %}
32-
{% if functions %}
17+
{%- block functions %}
18+
{%- if functions %}
3319
.. rubric:: {{ _('Functions') }}
3420

3521
.. autosummary::
@@ -38,10 +24,10 @@
3824
{{ item }}
3925
{%- endfor %}
4026
{% endif %}
41-
{% endblock %}
27+
{%- endblock %}
4228

43-
{% block classes %}
44-
{% if classes %}
29+
{%- block classes %}
30+
{%- if classes %}
4531
.. rubric:: {{ _('Classes') }}
4632

4733
.. autosummary::
@@ -51,10 +37,10 @@
5137
{{ item }}
5238
{%- endfor %}
5339
{% endif %}
54-
{% endblock %}
40+
{%- endblock %}
5541

56-
{% block exceptions %}
57-
{% if exceptions %}
42+
{%- block exceptions %}
43+
{%- if exceptions %}
5844
.. rubric:: {{ _('Exceptions') }}
5945

6046
.. autosummary::
@@ -63,4 +49,18 @@
6349
{{ item }}
6450
{%- endfor %}
6551
{% endif %}
66-
{% endblock %}
52+
{%- endblock %}
53+
54+
{%- block modules %}
55+
{%- if modules %}
56+
.. rubric:: Modules
57+
58+
.. autosummary::
59+
:toctree:
60+
:template: autosummary-module.rst
61+
:recursive:
62+
{% for item in modules %}
63+
{{ item }}
64+
{%- endfor %}
65+
{% endif %}
66+
{%- endblock %}

docs/source/api/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ API Reference
44

55
.. autosummary::
66
:toctree: _autosummary
7+
:template: autosummary-module.rst
78
:recursive:
89

910
labscript_utils

docs/source/conf.py

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,10 @@
8383
exclude_patterns = []
8484

8585
# The suffix(es) of source filenames.
86-
source_suffix = ['.rst', '.md']
86+
source_suffix = {
87+
'.rst': 'restructuredtext',
88+
'.md': 'markdown',
89+
}
8790

8891
# The master toctree document.
8992
master_doc = 'index'
@@ -160,20 +163,29 @@
160163
labscript_suite_doc_version = 'latest'
161164

162165
# add intersphinx references for each component
166+
labscript_intersphinx_mapping = {}
163167
for ls_prog in labscript_suite_programs:
164-
intersphinx_mapping[ls_prog] = (
168+
val = (
165169
'https://docs.labscriptsuite.org/projects/{}/en/{}/'.format(
166170
ls_prog, labscript_suite_doc_version
167171
),
168172
None,
169173
)
174+
labscript_intersphinx_mapping[ls_prog] = val
175+
if ls_prog != project:
176+
# don't add intersphinx for current project
177+
# if internal links break, they can silently be filled by links to existing online docs
178+
# this is confusing and difficult to detect
179+
intersphinx_mapping[ls_prog] = val
170180

171181
# add intersphinx reference for the metapackage
172182
if project != "the labscript suite":
173-
intersphinx_mapping['labscript-suite'] = (
183+
val = (
174184
'https://docs.labscriptsuite.org/en/{}/'.format(labscript_suite_doc_version),
175185
None,
176186
)
187+
intersphinx_mapping['labscript-suite'] = val
188+
labscript_intersphinx_mapping['labscript-suite'] = val
177189

178190
# Make `some code` equivalent to :code:`some code`
179191
default_role = 'code'
@@ -223,7 +235,7 @@ def setup(app):
223235
with open(Path(__file__).resolve().parent / 'components.rst', 'w') as f:
224236
f.write(
225237
template.render(
226-
intersphinx_mapping=intersphinx_mapping,
238+
intersphinx_mapping=labscript_intersphinx_mapping,
227239
programs=labscript_suite_programs,
228240
current_project=project,
229241
img_path=img_path

docs/source/index.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
You can adapt this file completely to your liking, but it should at least
44
contain the root `toctree` directive.
55
6-
labscript-utils
7-
===============
6+
labscript-utils |version|
7+
=========================
88

99
**labscript-utils** contains code shared between multiple programs in the labscript suite.
1010
This documentation is primarily for developers who might want to use this common code in their own custom features.

docs/source/labconfig.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ The name of this file must be the host computer's system name.
77
So if my system's name was `heisenberg`, the labconfig file name would be `heisenberg.ini`.
88
This file should be located in the `labscript-suite` directory in the user space, in the `labconfig` subdirectory.
99

10-
When :doc:`installing the **labscript-suite** for the first time <labscript-suite:installation/index>`, running the `labscript-profile-create` command will automatically generate the `labscript-suite` user space directory in the correct place and generate a `labconfig.ini` file for use on your system.
10+
When :doc:`installing the **labscript-suite** for the first time <labscript-suite:installation/index>`,
11+
running the `labscript-profile-create` command will automatically generate the `labscript-suite` user space directory in the correct place
12+
and generate a `labconfig.ini` file for use on your system.
1113
By editing the `ini` file named after your system, you can update the configuration settings of your **labscript-suite** installation.
1214

1315
The Default *labconfig.ini*

labscript_utils/qtwidgets/headerview_with_widgets.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ class HorizontalHeaderViewWithWidgets(QtWidgets.QHeaderView):
2020
/* Required, otherwise set to zero upon setting any stylesheet at all: */
2121
padding-left: 4px;
2222
/* Required for some reason, otherwise other settings ignored: */
23-
color: black;
23+
color: palette(text);
2424
}
2525
2626
/* Any other style goes here: */
@@ -122,7 +122,7 @@ def update_indents(self):
122122
font = item.font()
123123
fontmetrics = QtGui.QFontMetrics(font, self)
124124
indent = ''
125-
while fontmetrics.width(indent) < desired_indent:
125+
while fontmetrics.horizontalAdvance(indent) < desired_indent:
126126
indent += self.thinspace
127127
self.indents[widget] = indent
128128
font = self.font()

0 commit comments

Comments
 (0)