Skip to content

Commit 49e50de

Browse files
authored
Dynamic collection of bindings (#429)
1 parent 08f6a4d commit 49e50de

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

ephys_link.spec

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,27 @@
11
# -*- mode: python ; coding: utf-8 -*-
22

3-
from ephys_link.__about__ import __version__ as version
4-
53
from argparse import ArgumentParser
64

5+
from PyInstaller.utils.hooks import collect_submodules
6+
7+
from ephys_link.__about__ import __version__ as version
8+
79
parser = ArgumentParser()
810
parser.add_argument("-d", "--dir", action="store_true", help="Outputs a directory")
911
options = parser.parse_args()
1012

1113
FILE_NAME = f"EphysLink-v{version}"
1214

15+
# Collect binding modules.
16+
bindings = [binding for binding in collect_submodules("ephys_link.bindings") if binding != "ephys_link.bindings"]
17+
1318
# noinspection PyUnresolvedReferences
1419
a = Analysis(
1520
['src\\ephys_link\\__main__.py'],
1621
pathex=[],
1722
binaries=[('src\\ephys_link\\resources', 'ephys_link\\resources')],
1823
datas=[],
19-
hiddenimports=['engineio.async_drivers.aiohttp'],
24+
hiddenimports=['engineio.async_drivers.aiohttp'] + bindings,
2025
hookspath=[],
2126
hooksconfig={},
2227
runtime_hooks=[],

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ el = "ephys_link.__main__:main"
5656
path = "src/ephys_link/__about__.py"
5757

5858
[tool.hatch.build.targets.sdist]
59-
exclude = ["/.github", "/.idea"]
59+
exclude = ["/.github", "/.idea", "/docs"]
6060

6161
[tool.hatch.envs.default]
6262
python = "3.13.1"

src/ephys_link/__about__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = "2.0.0b9"
1+
__version__ = "2.0.0b10"

0 commit comments

Comments
 (0)