Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Tobias Langer
/
experiment
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
1751f9cf
authored
Oct 11, 2016
by
Tobias Langer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed problem with tasksets getting the same name.
parent
c0b78645
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
+7
-0
tasksetgen.py
+7
-0
No files found.
tasksetgen.py
View file @
1751f9cf
...
@@ -193,6 +193,7 @@ def main():
...
@@ -193,6 +193,7 @@ def main():
os
.
makedirs
(
args
.
target
)
os
.
makedirs
(
args
.
target
)
print
(
'Writing tasks…'
,
file
=
sys
.
stderr
)
print
(
'Writing tasks…'
,
file
=
sys
.
stderr
)
taken_names
=
{}
for
taskset
in
tasksets
:
for
taskset
in
tasksets
:
task_out
=
[]
task_out
=
[]
for
task
in
taskset
:
for
task
in
taskset
:
...
@@ -208,6 +209,12 @@ def main():
...
@@ -208,6 +209,12 @@ def main():
name
=
'taskset_{}_{}_{}'
.
format
(
now
.
strftime
(
'
%
Y_
%
m_
%
d'
),
name
=
'taskset_{}_{}_{}'
.
format
(
now
.
strftime
(
'
%
Y_
%
m_
%
d'
),
len
(
taskset
),
len
(
taskset
),
utilization
)
utilization
)
try
:
taken_names
[
name
]
+=
1
except
KeyError
:
taken_names
[
name
]
=
1
name
+=
'_{}'
.
format
(
taken_names
[
name
])
out
=
{}
out
=
{}
out
[
'name'
]
=
name
out
[
'name'
]
=
name
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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