Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
dream
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
dream
Commits
aeb0c73a
Commit
aeb0c73a
authored
Mar 06, 2015
by
Ioannis Papagiannopoulos
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
outputResultJSON of Operator does not update entity of schedule if entity is not instance of Job
parent
6acc02ef
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
7 deletions
+4
-7
dream/simulation/Operator.py
dream/simulation/Operator.py
+3
-1
dream/tests/dump/SkilledOperator02.json.result
dream/tests/dump/SkilledOperator02.json.result
+0
-2
dream/tests/dump/SkilledOperatorParallel01.json.result
dream/tests/dump/SkilledOperatorParallel01.json.result
+1
-4
No files found.
dream/simulation/Operator.py
View file @
aeb0c73a
...
...
@@ -303,7 +303,9 @@ class Operator(ObjectResource):
if
record
.
get
(
"exitTime"
,
None
)
!=
None
:
json
[
'results'
][
'schedule'
][
-
1
][
"exitTime"
]
=
record
[
"exitTime"
]
if
record
.
get
(
"entity"
,
None
):
json
[
'results'
][
'schedule'
][
-
1
][
"entityId"
]
=
record
[
"entity"
].
id
from
Job
import
Job
if
issubclass
(
record
[
"entity"
].
__class__
,
Job
):
json
[
'results'
][
'schedule'
][
-
1
][
"entityId"
]
=
record
[
"entity"
].
id
if
record
.
get
(
"task_id"
,
None
):
json
[
'results'
][
'schedule'
][
-
1
][
"task_id"
]
=
record
[
"task_id"
]
G
.
outputJSON
[
'elementList'
].
append
(
json
)
...
...
dream/tests/dump/SkilledOperator02.json.result
View file @
aeb0c73a
...
...
@@ -83,13 +83,11 @@
],
"schedule": [
{
"entityId": "P1",
"entranceTime": 0,
"exitTime": 17.0,
"stationId": "M1"
},
{
"entityId": "P1",
"entranceTime": 20.0,
"exitTime": 22.0,
"stationId": "M2"
...
...
dream/tests/dump/SkilledOperatorParallel01.json.result
View file @
aeb0c73a
...
...
@@ -92,8 +92,7 @@
],
"schedule": [
{
"entityId": "Batch22047",
"entranceTime": 0,
"entranceTime": 0.0,
"stationId": "M1"
}
],
...
...
@@ -115,13 +114,11 @@
],
"schedule": [
{
"entityId": "Batch22048",
"entranceTime": 0,
"exitTime": 80.0,
"stationId": "M2"
},
{
"entityId": "Batch22049",
"entranceTime": 80.0,
"stationId": "M2"
}
...
...
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