Private GIT
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
SickRage-1
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
vlbox
SickRage-1
Commits
06569fcb
Commit
06569fcb
authored
Nov 7, 2015
by
miigotu
Browse files
Options
Downloads
Plain Diff
Merge pull request #3121 from labrys/pep8-cache_db
Update cache_db.py for PEPs 8 and 263
parents
74ef60df
49af8d2c
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
sickbeard/databases/cache_db.py
+8
-0
8 additions, 0 deletions
sickbeard/databases/cache_db.py
with
8 additions
and
0 deletions
sickbeard/databases/cache_db.py
+
8
−
0
View file @
06569fcb
# coding=utf-8
# Author: Nic Wolfe <nic@wolfeden.ca>
# URL: http://code.google.com/p/sickbeard/
#
...
...
@@ -18,6 +20,7 @@
from
sickbeard
import
db
# Add new migrations at the bottom of the list; subclass the previous migration.
class
InitialSchema
(
db
.
SchemaUpgrade
):
def
test
(
self
):
...
...
@@ -49,6 +52,7 @@ class AddSceneExceptions(InitialSchema):
self
.
connection
.
action
(
"
CREATE TABLE scene_exceptions (exception_id INTEGER PRIMARY KEY, indexer_id INTEGER KEY, show_name TEXT);
"
)
class
AddSceneNameCache
(
AddSceneExceptions
):
def
test
(
self
):
return
self
.
hasTable
(
"
scene_names
"
)
...
...
@@ -64,6 +68,7 @@ class AddNetworkTimezones(AddSceneNameCache):
def
execute
(
self
):
self
.
connection
.
action
(
"
CREATE TABLE network_timezones (network_name TEXT PRIMARY KEY, timezone TEXT);
"
)
class
AddLastSearch
(
AddNetworkTimezones
):
def
test
(
self
):
return
self
.
hasTable
(
"
lastSearch
"
)
...
...
@@ -71,6 +76,7 @@ class AddLastSearch(AddNetworkTimezones):
def
execute
(
self
):
self
.
connection
.
action
(
"
CREATE TABLE lastSearch (provider TEXT, time NUMERIC);
"
)
class
AddSceneExceptionsSeasons
(
AddLastSearch
):
def
test
(
self
):
return
self
.
hasColumn
(
"
scene_exceptions
"
,
"
season
"
)
...
...
@@ -78,6 +84,7 @@ class AddSceneExceptionsSeasons(AddLastSearch):
def
execute
(
self
):
self
.
addColumn
(
"
scene_exceptions
"
,
"
season
"
,
"
NUMERIC
"
,
-
1
)
class
AddSceneExceptionsCustom
(
AddSceneExceptionsSeasons
):
def
test
(
self
):
return
self
.
hasColumn
(
"
scene_exceptions
"
,
"
custom
"
)
...
...
@@ -85,6 +92,7 @@ class AddSceneExceptionsCustom(AddSceneExceptionsSeasons):
def
execute
(
self
):
self
.
addColumn
(
"
scene_exceptions
"
,
"
custom
"
,
"
NUMERIC
"
,
0
)
class
AddSceneExceptionsRefresh
(
AddSceneExceptionsCustom
):
def
test
(
self
):
return
self
.
hasTable
(
"
scene_exceptions_refresh
"
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment