Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
mkexp
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Package registry
Operate
Terraform modules
Analyze
Contributor analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
esmenv
mkexp
Commits
04cf1c71
Commit
04cf1c71
authored
12 years ago
by
Karl-Hermann Wieners
Browse files
Options
Downloads
Patches
Plain Diff
Changed mkexp configuration to allow sensible defaults for local desktops
parent
8ade5fca
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
expconfig.py
+7
-5
7 additions, 5 deletions
expconfig.py
with
7 additions
and
5 deletions
expconfig.py
+
7
−
5
View file @
04cf1c71
...
...
@@ -70,9 +70,9 @@ class ExpConfig(ConfigObj):
experiment_type
=
extra_dict
.
get
(
'
EXP_TYPE
'
,
pre_config
[
'
EXP_TYPE
'
])
environment
=
extra_dict
.
get
(
'
ENVIRONMENT
'
,
pre_config
.
get
(
'
ENVIRONMENT
'
,
'
local
'
))
ExpConfig
.
default_name
))
# Backwards compatibility ENVIRONMENT -> QUEUE_TYPE
if
environment
==
'
local
'
and
'
QUEUE_TYPE
'
in
pre_config
:
if
environment
==
ExpConfig
.
default_name
and
'
QUEUE_TYPE
'
in
pre_config
:
feedback
.
warning
(
"
found obsolete keyword
'
QUEUE_TYPE
'
;
"
"
should be replaced by
'
ENVIRONMENT
'"
)
environment
=
pre_config
[
'
QUEUE_TYPE
'
]
...
...
@@ -116,9 +116,11 @@ class ExpConfig(ConfigObj):
lib_config_name
=
os
.
path
.
join
(
ExpConfig
.
env_lib_dir
,
environment
+
'
.config
'
)
pre_config
.
merge
(
ConfigObj
(
lib_config_name
,
interpolation
=
False
))
config_versions
.
append
(
pre_config
[
'
VERSION_
'
])
del
pre_config
[
'
VERSION_
'
]
if
os
.
path
.
exists
(
lib_config_name
):
pre_config
.
merge
(
ConfigObj
(
lib_config_name
,
interpolation
=
False
))
config_versions
.
append
(
pre_config
[
'
VERSION_
'
])
del
pre_config
[
'
VERSION_
'
]
# Re-read config to allow overriding default settings
# TODO: probably nicer if default experiment is given as argument
...
...
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