Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Guillaume Hervier
slapos.core
Commits
0288d97e
Commit
0288d97e
authored
May 23, 2012
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
getResultValue too easily hide problem
parent
b6363ec6
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
2 deletions
+10
-2
master/bt5/vifib_slapos_core/WorkflowTemplateItem/portal_workflow/instance_slap_interface_workflow/scripts/RequesterInstance_request.xml
..._interface_workflow/scripts/RequesterInstance_request.xml
+9
-1
master/bt5/vifib_slapos_core/bt/revision
master/bt5/vifib_slapos_core/bt/revision
+1
-1
No files found.
master/bt5/vifib_slapos_core/WorkflowTemplateItem/portal_workflow/instance_slap_interface_workflow/scripts/RequesterInstance_request.xml
View file @
0288d97e
...
...
@@ -103,7 +103,7 @@ while True:\n
predecessor_list.extend(current_software_instance_predecessor_list)\n
\n
# Check if it already exists\n
request_software_instance
= portal.portal_catalog.getResultValue
(\n
request_software_instance
_list = portal.portal_catalog
(\n
# Fetch all portal type, as it is not allowed to change it\n
portal_type=["Software Instance", "Slave Instance"],\n
title=software_title,\n
...
...
@@ -111,7 +111,15 @@ request_software_instance = portal.portal_catalog.getResultValue(\n
# Do not fetch destroyed instances\n
# XXX slap_state=["start_requested", "stop_requested"],\n
validation_state="validated",\n
limit=2,\n
)\n
instance_count = len(request_software_instance_list)\n
if instance_count == 0:\n
request_software_instance = None\n
elif instance_count == 1:\n
request_software_instance = request_software_instance_list[0].getObject()\n
else:\n
raise ValueError, "Too many instances \'%s\' found: %s" % (software_title, [x.path for x in request_software_instance_list])\n
\n
if (request_software_instance is None):\n
# First time that the software instance is requested\n
...
...
master/bt5/vifib_slapos_core/bt/revision
View file @
0288d97e
30
\ No newline at end of file
31
\ No newline at end of file
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