Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
SiCKRAGE
sickrage
Commits
3e50472a
Commit
3e50472a
authored
Nov 03, 2018
by
echel0n
Browse files
Added code to build show name cache on startup of app.
Fixed issue with show lookup during name parsing.
parent
f00e4ace
Changes
3
Hide whitespace changes
Inline
Side-by-side
changelog.md
View file @
3e50472a
# Changelog
-
*
ea173ba - 2018-10-28: Release v9.4.4
-
*
ceb1967 - 2018-11-03: Added code to build show name cache on startup of app. Fixed issue with show lookup during name parsing.
-
*
f91c70b - 2018-10-28: Release v9.4.4
-
*
bb87bb2 - 2018-10-28: Added code to get default download location from Synology Download Station
-
*
d32be97 - 2018-10-28: Release v9.4.3
-
*
f7c0464 - 2018-10-28: Fixed issue with unrar unpack directory setting
...
...
sickrage/core/__init__.py
View file @
3e50472a
...
...
@@ -345,7 +345,7 @@ class Core(object):
IntervalTrigger
(
hours
=
self
.
config
.
version_updater_freq
),
next_run_time
=
datetime
.
datetime
.
now
(),
next_run_time
=
datetime
.
datetime
.
now
()
+
datetime
.
timedelta
(
minutes
=
1
)
,
name
=
self
.
version_updater
.
name
,
id
=
self
.
version_updater
.
name
)
...
...
@@ -356,7 +356,7 @@ class Core(object):
IntervalTrigger
(
days
=
1
),
next_run_time
=
datetime
.
datetime
.
now
(),
next_run_time
=
datetime
.
datetime
.
now
()
+
datetime
.
timedelta
(
minutes
=
1
)
,
name
=
self
.
tz_updater
.
name
,
id
=
self
.
tz_updater
.
name
)
...
...
@@ -544,9 +544,12 @@ class Core(object):
self
.
quicksearch_cache
.
load
()
for
dbData
in
self
.
main_db
.
all
(
'tv_shows'
):
show
=
TVShow
(
int
(
dbData
[
'indexer'
]),
int
(
dbData
[
'indexer_id'
]))
try
:
self
.
log
.
debug
(
"Loading data for show: [{}]"
.
format
(
dbData
[
'show_name'
]))
self
.
showlist
.
append
(
TVShow
(
int
(
dbData
[
'indexer'
]),
int
(
dbData
[
'indexer_id'
])))
self
.
quicksearch_cache
.
add_show
(
dbData
[
'indexer_id'
])
self
.
log
.
debug
(
"Loading data for show: [{}]"
.
format
(
show
.
name
))
self
.
showlist
.
append
(
show
)
self
.
name_cache
.
build
(
show
)
self
.
quicksearch_cache
.
add_show
(
show
.
indexerid
)
except
Exception
as
e
:
self
.
log
.
debug
(
"Show error in [%s]: %s"
%
(
dbData
[
'
location
'
]
,
str
(
e
)))
self
.
log
.
debug
(
"Show error in [%s]: %s"
%
(
show
.
location
,
str
(
e
)))
\ No newline at end of file
sickrage/core/nameparser/__init__.py
View file @
3e50472a
...
...
@@ -88,20 +88,18 @@ class NameParser(object):
# lookup show id
for
lookup
in
lookup_list
:
if
show
or
show_id
is
not
None
:
continue
try
:
show_id
=
int
(
lookup
())
if
show_id
==
0
:
continue
sickrage
.
app
.
name_cache
.
put
(
show_name
,
show_id
)
if
self
.
validate_show
:
show
=
findCertainShow
(
show_id
)
else
:
from
sickrage.core.tv.show
import
TVShow
show
=
TVShow
(
1
,
show_id
)
if
not
show
:
sickrage
.
app
.
name_cache
.
put
(
show_name
,
show_id
)
if
self
.
validate_show
:
show
=
findCertainShow
(
show_id
)
else
:
from
sickrage.core.tv.show
import
TVShow
show
=
TVShow
(
1
,
show_id
)
except
Exception
:
pass
...
...
@@ -519,7 +517,8 @@ class NameParser(object):
# if there's no useful info in it then raise an exception
if
final_result
.
season_number
is
None
and
not
final_result
.
episode_numbers
and
final_result
.
air_date
is
None
and
not
final_result
.
ab_episode_numbers
and
not
final_result
.
series_name
:
raise
InvalidNameException
(
"Unable to parse {} to a valid episode. Parser result: {}"
.
format
(
name
,
final_result
))
raise
InvalidNameException
(
"Unable to parse {} to a valid episode. Parser result: {}"
.
format
(
name
,
final_result
))
if
cache_result
and
final_result
.
show
:
name_parser_cache
.
add
(
name
,
final_result
)
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment