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
289bba8d
Commit
289bba8d
authored
May 09, 2018
by
Georgios Dagkakis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix situation where skilled router could get stuck expecting messages
parent
b92b8b78
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
10 deletions
+10
-10
dream/simulation/Machine.py
dream/simulation/Machine.py
+8
-7
dream/simulation/SkilledOperatorRouter.py
dream/simulation/SkilledOperatorRouter.py
+2
-3
No files found.
dream/simulation/Machine.py
View file @
289bba8d
...
...
@@ -1226,14 +1226,15 @@ class Machine(CoreObject):
operator
.
unAssign
()
# set the flag operatorAssignedTo to None
operator
.
workingStation
=
None
self
.
outputTrace
(
operator
.
name
,
"released from "
+
self
.
objName
)
self
.
toBeOperated
=
False
# if the Router is expecting for signal send it
from
Globals
import
G
from
SkilledOperatorRouter
import
SkilledRouter
self
.
toBeOperated
=
False
if
G
.
RouterList
[
0
].
__class__
is
SkilledRouter
:
if
G
.
RouterList
[
0
].
expectedFinishSignals
:
if
self
.
id
in
G
.
RouterList
[
0
].
expectedFinishSignalsDict
:
signal
=
G
.
RouterList
[
0
].
expectedFinishSignalsDict
[
self
.
id
]
if
not
signal
.
triggered
:
self
.
sendSignal
(
receiver
=
G
.
RouterList
[
0
],
signal
=
signal
)
self
.
broker
.
invokeType
=
'release'
self
.
broker
.
invoke
()
...
...
dream/simulation/SkilledOperatorRouter.py
View file @
289bba8d
...
...
@@ -444,7 +444,7 @@ class SkilledRouter(Router):
station
=
findObjectById
(
solution
[
id
])
signal
=
True
# signal only the stations in the original list
if
station
not
in
self
.
toBeSignalled
:
if
station
not
in
self
.
toBeSignalled
or
(
not
operator
.
onShift
)
or
operator
.
onBreak
:
signal
=
False
# signal only if the operator is free
if
operator
.
workingStation
:
...
...
@@ -455,7 +455,6 @@ class SkilledRouter(Router):
# signal the station so that it gets the operator
self
.
signalStation
(
station
,
operator
)
#===================================================================
# default behaviour
#===================================================================
...
...
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