Skip to content

Draft: Add integration tests - #288

Open
mutlusun wants to merge 10 commits into
kaixxx:mainfrom
mutlusun:refactor/model-and-ci
Open

Draft: Add integration tests#288
mutlusun wants to merge 10 commits into
kaixxx:mainfrom
mutlusun:refactor/model-and-ci

Conversation

@mutlusun

@mutlusun mutlusun commented Apr 8, 2026

Copy link
Copy Markdown
Contributor

This MR is based on #282 and should be merged after it.

The goal of this MR was to add first integration tests. I refactored the code on the way to have a cleaner solution for this.

Changes:

  • To have a whisper model in the CI to run the integration tests, I added a feature to download certain models into the package directory. This has the advantage that also for the packaging of new version only the download command needs to be used to get the models. Model origin and version (commit hash) is set in the python code. This should prevent the use of other/newer models without specifying them before. To implement this cleanly, I refactored the code related to detect whisper models as well.
  • I refactored the code to follow the model-view-controller paradigm (see here for example for dive-in). This makes it easier to separate the code between UI and background logic. It should also make it easier to implement another GUI in the future for noScribe.

I'm sorry for the rather big MR but I think noScribe profits from the integration tests and the started refactorings.

Best

@mutlusun
mutlusun force-pushed the refactor/model-and-ci branch 2 times, most recently from 13cd61d to 4594e80 Compare April 8, 2026 13:18
@mutlusun
mutlusun force-pushed the refactor/model-and-ci branch 5 times, most recently from 3960036 to 74b5285 Compare April 14, 2026 07:59
Increase the lowest tested python version. In python 3.10 the
importlib.resources module works differently and tests fail. Thus
increase to 3.12.
@mutlusun
mutlusun force-pushed the refactor/model-and-ci branch from 74b5285 to 6e332f8 Compare April 14, 2026 08:05
@kaixxx

kaixxx commented Apr 14, 2026

Copy link
Copy Markdown
Owner

Hey @mutlusun, thank you, this looks very reasonable.
I have started this project from a simple script that was extended step by step into a fully fledged application. A fundamental refactoring and modularization of the code is definitely overdue. I will need a little bit of time to take a proper look.

One thing to consider: I plan to extend noScribe in the direction of a client-server-architecture that can also be run on a powerful server in a local network. Several university research institutes have asked for such a feature. It would be great if you could keep that in mind when working on separating front- and backend logic.
I'm not completely sure what the best approach would be for such a client-server architecture. Maybe TCP for piping the communication between front- and backend, similar to the current communication with background processes in noScribe? I have zero experience with client-server architectures.
If you have any ideas, I would be happy to hear them. We could continue the discussion in a separate issue threat.

@gernophil

gernophil commented Apr 14, 2026

Copy link
Copy Markdown
Collaborator

I have some experience using apache2 with a reverse proxy with a shiny for python based app like here: https://bescreen.ostendorflab.org
This is the backend: https://github.com/ostendorflab/bescreen. The frontend is a simple Python script that's not publicly available, but I can share it amongst us.

@kaixxx kaixxx mentioned this pull request Apr 14, 2026
@kaixxx

kaixxx commented Apr 14, 2026

Copy link
Copy Markdown
Owner

@mutlusun @gernophil : Lets continue here: #289

@mutlusun

Copy link
Copy Markdown
Contributor Author

@kaixxx Thanks for your feedback!

Please make sure to look at #282 before looking at this MR as changes of both MR appear here at the moment.

@mutlusun

Copy link
Copy Markdown
Contributor Author

I will rebase this after #282 is merged.

@mutlusun mutlusun changed the title Add integration tests Draft: Add integration tests Jun 2, 2026
@kaixxx

kaixxx commented Jun 2, 2026

Copy link
Copy Markdown
Owner

@mutlusun I've seen you've changed this to a draft again, probably for the rebase. Take your time, no hurry. Thank you for all the work.

@mutlusun

mutlusun commented Jun 3, 2026

Copy link
Copy Markdown
Contributor Author

Thanks! Yes, only for the rebase but I think this will take some time as the previous PR and this are a bit overlapping at the moment. I need to clean this up before.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants