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
Gabriel Monnerat
slapos.core
Commits
daab29e5
Commit
daab29e5
authored
May 02, 2012
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Log errors on ERROR level.
parent
afa9fa85
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
master/product/Vifib/Tool/VifibRestApiV1Tool.py
master/product/Vifib/Tool/VifibRestApiV1Tool.py
+3
-3
No files found.
master/product/Vifib/Tool/VifibRestApiV1Tool.py
View file @
daab29e5
...
@@ -34,7 +34,7 @@ from AccessControl import ClassSecurityInfo, getSecurityManager
...
@@ -34,7 +34,7 @@ from AccessControl import ClassSecurityInfo, getSecurityManager
from
Products.ERP5Type.Globals
import
InitializeClass
from
Products.ERP5Type.Globals
import
InitializeClass
from
Products.ERP5Type
import
Permissions
from
Products.ERP5Type
import
Permissions
from
ComputedAttribute
import
ComputedAttribute
from
ComputedAttribute
import
ComputedAttribute
from
zLOG
import
LOG
,
INFO
from
zLOG
import
LOG
,
ERROR
import
json
import
json
import
transaction
import
transaction
...
@@ -96,7 +96,7 @@ class InstancePublisher(GenericPublisher):
...
@@ -96,7 +96,7 @@ class InstancePublisher(GenericPublisher):
person
=
self
.
getPortalObject
().
ERP5Site_getAuthenticatedMemberPersonValue
()
person
=
self
.
getPortalObject
().
ERP5Site_getAuthenticatedMemberPersonValue
()
if
person
is
None
:
if
person
is
None
:
transaction
.
abort
()
transaction
.
abort
()
LOG
(
'VifibRestApiV1Tool'
,
INFO
,
LOG
(
'VifibRestApiV1Tool'
,
ERROR
,
'Currenty logged in user %r has no Person document.'
%
'Currenty logged in user %r has no Person document.'
%
self
.
getPortalObject
().
getAuthenticatedMember
())
self
.
getPortalObject
().
getAuthenticatedMember
())
response
.
setStatus
(
500
)
response
.
setStatus
(
500
)
...
@@ -129,7 +129,7 @@ class InstancePublisher(GenericPublisher):
...
@@ -129,7 +129,7 @@ class InstancePublisher(GenericPublisher):
person
.
requestSoftwareInstance
(
**
request_dict
)
person
.
requestSoftwareInstance
(
**
request_dict
)
except
Exception
:
except
Exception
:
transaction
.
abort
()
transaction
.
abort
()
LOG
(
'VifibRestApiV1Tool'
,
INFO
,
'Problem with request.'
,
LOG
(
'VifibRestApiV1Tool'
,
ERROR
,
'Problem with request.'
,
error
=
True
)
error
=
True
)
response
.
setStatus
(
500
)
response
.
setStatus
(
500
)
response
.
setBody
(
json
.
dumps
({
'error'
:
response
.
setBody
(
json
.
dumps
({
'error'
:
...
...
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