Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
aura-engine
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
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Lars Kruse
aura-engine
Commits
7d81e7b6
Commit
7d81e7b6
authored
5 years ago
by
Gottfried Gaisbauer
Browse files
Options
Downloads
Patches
Plain Diff
added switch for using testdata
parent
99498fb4
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
aura.py
+7
-26
7 additions, 26 deletions
aura.py
modules/scheduling/calendar.py
+1
-1
1 addition, 1 deletion
modules/scheduling/calendar.py
with
8 additions
and
27 deletions
aura.py
+
7
−
26
View file @
7d81e7b6
...
...
@@ -47,19 +47,9 @@ class Aura(AuraLogger):
def
__init__
(
self
):
super
(
Aura
,
self
).
__init__
()
def
test_yourself
(
self
):
self
.
run_test
(
TestConfig
)
self
.
run_test
(
TestLogger
)
def
run_test
(
self
,
testingClass
):
runner
=
unittest
.
TextTestRunner
()
result
=
runner
.
run
(
unittest
.
makeSuite
(
testingClass
))
def
startup
(
self
):
server
=
object
# self.controller = AuraController(self.config)
# self.controller = AuraController(self.config)
# create scheduler and ls_communicator
self
.
liquidsoapcommunicator
=
LiquidSoapCommunicator
(
self
.
config
)
self
.
scheduler
=
AuraScheduler
(
self
.
config
)
...
...
@@ -73,16 +63,8 @@ class Aura(AuraLogger):
self
.
messenger
.
scheduler
=
self
.
scheduler
self
.
messenger
.
liquidsoapcommunicator
=
self
.
liquidsoapcommunicator
self
.
diskspace_watcher
=
DiskSpaceWatcher
(
self
.
config
,
self
.
logger
,
self
.
liquidsoapcommunicator
)
self
.
diskspace_watcher
.
start
()
def
receive_signal
(
signum
,
stack
):
print
(
"
received signal
"
)
server
.
reload
()
signal
.
signal
(
signal
.
SIGUSR1
,
receive_signal
)
#self.diskspace_watcher = DiskSpaceWatcher(self.config, self.logger, self.liquidsoapcommunicator)
#self.diskspace_watcher.start()
# and finally wait for redis message
self
.
join_comm
()
...
...
@@ -91,7 +73,6 @@ class Aura(AuraLogger):
self
.
start_web_service
()
def
join_comm
(
self
):
# start listener thread
self
.
messenger
.
start
()
...
...
@@ -112,10 +93,10 @@ class Aura(AuraLogger):
def
main
():
aura
=
Aura
()
if
len
(
sys
.
argv
)
>=
2
and
sys
.
argv
[
1
]
==
"
--na-gspiast-di-?
"
:
aura
.
test_yourself
(
)
else
:
aura
.
startup
()
if
len
(
sys
.
argv
)
>=
2
and
"
--use-test-data
"
in
sys
.
argv
:
aura
.
config
.
set
(
"
use_test_data
"
,
True
)
aura
.
startup
()
# # ## ## ## ## ## ## # #
...
...
This diff is collapsed.
Click to expand it.
modules/scheduling/calendar.py
+
1
−
1
View file @
7d81e7b6
...
...
@@ -312,7 +312,7 @@ class AuraCalendarService(threading.Thread):
# fetch data from importer
json_response
=
self
.
__fetch_data__
(
servicetype
)
if
not
json_response
:
if
not
json_response
and
self
.
config
.
get
(
"
use_test_data
"
)
:
use_testdata
=
True
# if a playlist is already fetched, do not fetch it again
...
...
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