Closed dreulavelle closed 1 week ago
The changes in the pull request modify the Program
class in src/program/program.py
to implement a chunked processing approach for initializing the database from symlinks. Instead of processing all items in a single batch, items are now filtered into Movie
and Show
instances and processed in chunks of 100. This allows for partial commits to the database after each chunk, improving responsiveness and error handling during initialization. Logging messages have been adjusted to reflect this new processing method, while the overall control flow remains largely unchanged.
File | Change Summary |
---|---|
src/program/program.py | - Replaced single batch processing with chunked processing for items. |
- Items are now processed in chunks of 100, with partial commits to the database. | |
- Improved error handling and logging for chunk processing. |
In the land of code where rabbits play,
Chunks of data hop along the way.
With each small batch, we save the day,
Committing joyfully, come what may!
Hooray for progress, letβs cheer and sway! πβ¨
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
I cant test the rollback part as I dont have a way to force it to break π€
But I tested this on my 30k item library and it finished within 1 minute. π₯³
Pull Request Check List
Resolves: #issue-number-here
Description:
Summary by CodeRabbit
New Features
Bug Fixes