Commit graph

208 commits

Author SHA1 Message Date
Joe Knapper
bf82f37c47 Dependency bump for camera_stage_mapping to 0.1.8
Returns the errors we expect
2025-04-08 12:09:15 +00:00
Julian Stirling
928d5ef300 Try pinning pydantic version as server now fails tests with error 2025-04-02 14:05:38 +01:00
Richard Bowman
e8ae496d08 Use published packages
I've published [pre]releases on PyPI. This commit uses the mos recent releases of labthings-picamera2 and camera-stage-mapping.
2024-12-18 14:26:15 +00:00
Richard Bowman
db11e03321 Constrain numpy < 2
picamera2 fails to import with numpy 2.
2024-12-18 14:23:44 +00:00
Richard Bowman
1d59cddac1 Disable pytest code quality report
Code quality report plugin clashes with the version of pytest specced in labthings.

If we resolve this upstream, we can re-enable it.
2024-12-03 14:19:36 +00:00
Richard Bowman
c3cd30b642 Only rebuild docker for changes
Docker is now only rebuilt when it's changed, and on `v3`  branch.

I've also added code quality reporting for pytest.
2024-12-03 12:54:34 +00:00
Richard Bowman
71e6d84aa4 Build docker image and run ruff/pytest 2024-12-03 12:18:45 +00:00
Richard Bowman
77794c94eb Update documentation on dependencies/dev tools 2024-12-03 11:18:24 +00:00
Richard Bowman
1e7069b375 Add more tests, speed up dummy stage
I've sped up the stage motion, to run tests in a more reasonable time.

CSM doesn't yet calibrate in the test - I suspect debugging of capture_array
is needed.
2024-12-03 00:16:26 +00:00
Richard Bowman
1ba799de22 Migrate to new Blob type and update imports
This now uses the latest version of labthings-fastapi.
2024-11-28 17:35:56 +00:00
Richard Bowman
b8ca12314c Lock labthings/picamera2 deps
v0.0.7 of labthings includes breaking changes, we're not ready for that yet.
2024-11-28 10:30:53 +00:00
Richard Bowman
7b584d3e64 Add labthings version constraint 2024-11-16 10:58:31 +00:00
Richard Bowman
7fb4417ebe Configuration files and other tweaks
The OFM server can now be run in "stub" mode on
my development machine, using an OpenCV
camera feed.
2024-08-09 02:42:32 +01:00
Richard Bowman
e3e248c46e Move server config to a config file
Currently this is "just" a LabThings config file.
2024-08-09 01:51:11 +01:00
Richard Bowman
3f92ed8266 Add a stub OpenCV-based camera
This allows the server to run on a laptop, to some extent. I've not tested if this will make the whole
web app work properly.

As StreamingPiCamera2 is hardcoded in various places, this certainly doesn't make cameras totally
interchangeable - but it is a step towards that.
2024-08-09 00:52:31 +01:00
Richard Bowman
3abddc3b39 Fix labthings dependency
I changed the labthings package such that it will
only install the client dependencies by default.
This is now fixed by requiring the [server] extras.
In the future we might split labthings into client
and server packages.
2024-07-18 13:17:26 +01:00
Richard Bowman
bcc13475b6 Propagate logs from camera-stage-mapping 2024-01-04 13:19:00 +00:00
Richard Bowman
deeb2c7b9b Explicitly mention anyio as a dependency
This is already in via fastapi, but I just got caught out by a
v3 -> v4 change. I've added a dependency to make this explicit.
2024-01-03 17:12:15 +00:00
Richard Bowman
968136e22e Add opencv as a dependency 2023-12-14 17:21:22 +00:00
Richard Bowman
796622b802 Relax scipy version 2023-10-31 22:28:47 +00:00
Richard Bowman
63d7a6eb4d WIP: camera stage mapping
This still has some bugs, mostly related to numpy and serialisation.
2023-08-31 19:37:09 +01:00
Richard Bowman
081654533f First images on labthings-fastapi
We now have very basic camera and stage support.
2023-08-29 17:02:16 +01:00
Richard
e33e92b43a Generate and use pytest XML reports
This generates XML reports when we run pytest through poe, and
uploads them in the relevant CI stage.

I've also ignored mypy cache files - I'm not sure why this hasn't
been an issue before...
2021-08-10 11:29:09 +01:00
Richard
fe3fb5c66b Incorporate LabThings 1.3
The necessary changes to produce valid OpenAPI docs are now in
the latest release of LabThings.  This change updates it.

Also, isort was trying to sort my virtual environment, hence
the change to pyproject.toml.
I don't know why that happened - maybe an update to isort?
2021-07-25 22:23:54 +01:00
Richard Bowman
42f00b69a4 Merge remote-tracking branch 'origin/master' into auto-exposure-gain-awb
This was primarily done to disable the warning about f strings in
logging statements, globally rather than per-file.
2021-04-27 17:16:19 +01:00
Richard Bowman
a2ba95c1d3 Minor linting improvements
I have now disabled W1203 globally, see comment in
pyproject.toml
2021-04-27 11:17:11 +01:00
Richard Bowman
1f1a75c02a Merge branch 'master' into auto-exposure-gain-awb 2021-04-21 12:10:47 +01:00
Richard Bowman
1b5b576664 Improved comments 2021-04-21 11:28:30 +01:00
Richard Bowman
17b19d7dfd fix poe
poe was assuming we were using poetry - I have
configured it not to use poetry now. This required
using a newer version.
2021-03-29 16:59:40 +01:00
Richard Bowman
af7ef08f63 Move away from poetry
More or less everything is now done by setup.py
Pipfile simply installs the module in editable mode, which
recursively resolves dependencies as defined in setup.py.
2021-03-26 21:11:22 +00:00
Richard Bowman
bc0995d0cf Added poe serve
To save some typing ``poe serve`` now runs a debug server.
2021-02-18 18:03:42 +00:00
Richard Bowman
414fd55c5b Upgrade numpy
numpy/scipy were mismatched in version, which led to a confusing
import error.  I've removed the numpy version specification entirely
and left it to scipy to ensure numpy
is installed.  This could do with
review in the future...
2021-02-18 14:33:07 +00:00
Richard Bowman
20001e4946 Force installation only from piwheels
Forcing the use of piwheels avoids trying
to install numpy/scipy from source,
which is the Right Answer.

Unfortunately, sometimes packages fail on piwheels, but poetry still
tries to install them.  I've had to fix
pyyaml at 5.4.0 for that reason.
2021-02-18 13:29:02 +00:00
Joel Collins
5f48be3807 Merge branch 'master' into 'mypy-coverage'
# Conflicts:
#   poetry.lock
2021-01-08 10:51:15 +00:00
Joel Collins
bb7d543ecd Actually removed pynpm and updated sphinx 2021-01-08 10:22:04 +00:00
Joel Collins
5232b36644 Test cobertura mypy coverage report 2021-01-08 10:05:31 +00:00
Joel Collins
180d73f9c4 Upgraded to LabThings ^1.2.2 2021-01-07 10:23:46 +00:00
Joel Collins
f330cc93ec v2.9.3 2020-12-14 15:05:14 +00:00
Joel Collins
72d33fff7d Patch version 2020-12-08 18:26:31 +00:00
Joel Collins
47680fd23b v2.9.1 2020-12-07 17:11:02 +00:00
Joel Collins
b6a0a6395e Bumped version number 2020-12-04 17:09:52 +00:00
Joel Collins
63b633ba44 2.9 dev numpy types 2020-12-04 13:35:11 +00:00
Joel Collins
249e3014cb Updated to LabThings 1.2.1 2020-12-01 15:06:25 +00:00
Joel Collins
d9d58d03dd Upgraded to LabThings 1.2.0 2020-11-30 16:58:12 +00:00
Joel Collins
7a849c725a Test on new LabThings branch 2020-11-30 16:23:02 +00:00
Joel Collins
5091ee8983 Updated to LabThings 1.1.6 2020-11-30 13:52:41 +00:00
Joel Collins
7866ec0f47 Static type analysis 2020-11-30 13:36:45 +00:00
Joel Collins
f1060d9e6d Merge branch 'master' into 'pytest'
# Conflicts:
#   poetry.lock
2020-11-25 15:26:20 +00:00
Joel Collins
5137d1b9dc Added basic unit tests of non-integrated functions 2020-11-25 15:25:17 +00:00
Joel Collins
6819ded7ef Removed unused pynpm package 2020-11-24 17:49:50 +00:00