Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mpsd-software-manager
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
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
MPSD Computational Science
mpsd-software-manager
Commits
c4609953
Commit
c4609953
authored
1 year ago
by
Ashwin Kumar Karnad
Browse files
Options
Downloads
Patches
Plain Diff
black
parent
5145b063
No related branches found
Branches containing commit
No related tags found
2 merge requests
!39
Split logfile templates usage
,
!29
Restructure log location
Pipeline
#370251
passed
1 year ago
Stage: test
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
mpsd-software-environment.py
+9
-7
9 additions, 7 deletions
mpsd-software-environment.py
tests.py
+0
-1
0 additions, 1 deletion
tests.py
with
9 additions
and
8 deletions
mpsd-software-environment.py
+
9
−
7
View file @
c4609953
...
@@ -51,6 +51,7 @@ config_vars = {
...
@@ -51,6 +51,7 @@ config_vars = {
"
spack_environments_repo
"
:
"
https://gitlab.gwdg.de/mpsd-cs/spack-environments.git
"
,
"
spack_environments_repo
"
:
"
https://gitlab.gwdg.de/mpsd-cs/spack-environments.git
"
,
}
}
def
create_log_file_names
(
def
create_log_file_names
(
mpsd_release
:
str
,
mpsd_release
:
str
,
mpsd_microarch
:
str
,
mpsd_microarch
:
str
,
...
@@ -82,7 +83,7 @@ def create_log_file_names(
...
@@ -82,7 +83,7 @@ def create_log_file_names(
only install and remove are valid for build log file.
only install and remove are valid for build log file.
toolchain : str
toolchain : str
toolchain name (only for build log file)
toolchain name (only for build log file)
Returns
Returns
-------
-------
str
str
...
@@ -101,12 +102,13 @@ def create_log_file_names(
...
@@ -101,12 +102,13 @@ def create_log_file_names(
log_template
=
config_vars
[
"
installer_log_template
"
]
log_template
=
config_vars
[
"
installer_log_template
"
]
return
log_template
.
substitute
(
return
log_template
.
substitute
(
mpsd_release
=
mpsd_release
,
mpsd_release
=
mpsd_release
,
mpsd_microarch
=
mpsd_microarch
,
mpsd_microarch
=
mpsd_microarch
,
date
=
date
,
date
=
date
,
action
=
action
,
action
=
action
,
toolchain
=
toolchain
,
toolchain
=
toolchain
,
)
)
def
log_metadata
(
key
:
str
,
value
:
str
)
->
None
:
def
log_metadata
(
key
:
str
,
value
:
str
)
->
None
:
"""
Log metadata to the log file.
"""
Log metadata to the log file.
...
...
This diff is collapsed.
Click to expand it.
tests.py
+
0
−
1
View file @
c4609953
...
@@ -383,7 +383,6 @@ def test_metadata_logging(tmp_path):
...
@@ -383,7 +383,6 @@ def test_metadata_logging(tmp_path):
assert
len
(
read_dict
)
==
len
(
keys
)
assert
len
(
read_dict
)
==
len
(
keys
)
def
test_create_log_file_names
():
def
test_create_log_file_names
():
"""
Test that the log file names are created correctly.
"""
"""
Test that the log file names are created correctly.
"""
create_log_file_names
=
mod
.
create_log_file_names
create_log_file_names
=
mod
.
create_log_file_names
...
...
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