-
Notifications
You must be signed in to change notification settings - Fork 33
Processor multi output #1344
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Processor multi output #1344
Conversation
- `OcrdPageResult`: replace by proxy class `OcrdPageResultVariadicListWrapper`
with list semantics and variadic constructor (with the original class now
under `SingleOcrdPageResult`)
- `Processor.process_page_file`: handle results from `process_page_pcgts`
as lists:
* split `output_file_grp` with commas (just as `input_file_grp`)
* iterate over output file groups and `OcrdPageResult`
* log error if there are more results than output file groups
(that _will_ get lost)
* raise `FileExistsError` (in order to skip actual computation)
iff output file exists for _all_ output file groups
* make output files (and file IDs), and save images etc for each
output independently
- add test coverage
…porting order=document)
|
I don't understand the failing Any ideas, @MehmedGIT perhaps? |
kba
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM - I am still reading up on the PRs though, not yet the discussion about the problems with them ;)
@MehmedGIT How compatible with current versions of RabbitMQ are we? I have been using But that isn't the reason for the test failure - what actually is? Could not determine that quickly from the logs 😕 |
See above Happens for
|
|
@bertsky, seems all ubuntu-22.04 tests are passing currently. I have manually restarted the CI/CD pipeline for that failing test and it runs fine. All tests of core v3.8.1 (+ ocrd_network module and integration tests) are also passing on my local machine Ubuntu 24.04 with Python 3.12.3. I can no longer produce the Pydantic and MongoDB issues. The package versions I have in the environment are: |
|
@MehmedGIT wow, indeed! So is that the result of 53b8e2b actually? I am stunned, as I would have expected this to fail in the normal CI already. And in the network test, why don't we see any concrete error message related to the broken exception f-string? |
Not sure, seems so. I thought it could be a deadlock somewhere but I could not identify any change that could cause that. However, the job failure here is not because of a timeout. The job itself has failed for whatever reason and returned
The logs are redirected to the log file. No exception is raised on the processing server level. EDIT: Actually, we don't even need to know where are the logs are stored. The client can just request the log file from the processing server and print its content if the job has FAILED. I will create a PR. |
Ee! So I was completely misled by the pymongo messages – they were actually harmless of themselves! I did not notice that we did not even show the actual job logs in the test output.
Fantastic – thanks @MehmedGIT ! |
Yes, they are. RabbitMQ ones are usually also harmless. I actually find the outputs of these services to be cluttering the logs when something fails. At least when running the tests locally. Would be good if somehow they could be disabled while keeping the outputs of the other relevant test containers. |
I have a hard time reproducing this locally. I tried reverting 53b8e2b and then merged in #1348 to see if I get more useful error logs. But it's the exact same picture: the |
Update: the problem for me was the wrongly configured |
I remember that we had a difference between the workers running locally and in docker environment. Hence, we had this mechanism to switch between the two, based on whether the Maybe @joschrew remembers more since he was testing the workers in the docker environment with his setup. |
I have pushed the fix change to #1348 |
|
@kba I added a unit test to cover directly what I previously missed (and thus ended up problematic in network-integration-test). So all done now. |
No description provided.