-
Notifications
You must be signed in to change notification settings - Fork 277
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
Split composite status into status and quality, add Unknown as valid quality #4221
Conversation
medusa/databases/main_db.py
Outdated
self.connection.action("DROP TABLE IF EXISTS new_tv_episodes;") | ||
|
||
log.info(u'Split composite status in to ep_status and ep_quality') | ||
sql_results = self.connection.select("SELECT status from tv_episodes GROUP BY status HAVING status > -1") |
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.
@medariox Im not sure if we also need to translate status of -1
Pff this will require a lot of testing. |
Action will include the status, quality (hasn't changed) but will include quality. Action will only have status, quality has been removed from it. * Changed show/history.py, to include quality. As we can't get it from action anymore.
Replace other occurrences of Quality.STATUS.
…d-db-status-quality-fields
This to keep the db sane, while changing all the composite statusses.
This comment has been minimized.
This comment has been minimized.
* Set status to app.EP_DEFAULT_DELETED_STATUS if episode file was delete and old status was ARCHIVED or DOWNLOADED or IGNORED or SKIPPED * Add some episode attributes that should be reset if a file is deleted
55e01c5
to
25346d9
Compare
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.
Looks good to me, but I also committed to this branch.
I would prefer it if the compact history "duplicate" qualities could be fixed, but I don't think it should stop you from merging.
Continued in a comment.
I tried to fix the history "bug" myself but hit a snag. But because of the composite statuses split, now Edit: as I was writing this comment, I figured out what was the issue I encountered, the 2 newest commits should restore the compact layout to what it was (without affecting detailed) |
+ fix quality sorting
Both History and episode status management where broken for me. |
…elds' into feature/add-db-status-quality-fields
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.
I think this is good to go 🎉
I dont know. I feel like we should really do more testing. The last two bugs i noticed where really obvious. And i couldnt test it sooner. As my db is a mess. |
That's why we should merge it to develop ASAP, to have some more people actually test it. |
Good point |
This PR contains major changes to our quality system.
Downloaded
,Skipped
, etc.) and quality (HDTV
,720p WEB-DL
, etc.). This allows us to remove a lot of superfluous code and will make a better quality system possible in the future.Unknown
as a valid quality (the lowest available), thus eliminating a bunch of annoying hacks and allowing it to be set even as Preferred (e.g. forx265
content)It goes without saying that these are massive changes that should be tested thoroughly over a minimum period of time. It would be great if anyone could give this a spin in the next couple of days. The upgrade process is automated and backup files for
main.db
,failed.db
andcache.db
will be created.