Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
CIRCLE
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
94
Merge Requests
10
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
1cb28964
authored
Apr 09, 2020
by
Máhonfai Bálint
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove unused exception
parent
fb4f60b6
Pipeline
#1062
passed with stage
in 0 seconds
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
circle/dashboard/models.py
+4
-2
No files found.
circle/dashboard/models.py
View file @
1cb28964
...
@@ -50,7 +50,7 @@ from common.models import HumanReadableObject, create_readable, Encoder
...
@@ -50,7 +50,7 @@ from common.models import HumanReadableObject, create_readable, Encoder
from
vm.models.instance
import
ACCESS_METHODS
from
vm.models.instance
import
ACCESS_METHODS
from
.store_api
import
Store
,
NoStoreException
,
NotOkException
,
Timeout
from
.store_api
import
Store
,
NoStoreException
,
NotOkException
from
.validators
import
connect_command_template_validator
from
.validators
import
connect_command_template_validator
logger
=
getLogger
(
__name__
)
logger
=
getLogger
(
__name__
)
...
@@ -351,6 +351,7 @@ if hasattr(settings, 'SAML_ORG_ID_ATTRIBUTE'):
...
@@ -351,6 +351,7 @@ if hasattr(settings, 'SAML_ORG_ID_ATTRIBUTE'):
logger
.
debug
(
"Register save_org_id to djangosaml2 pre_user_save"
)
logger
.
debug
(
"Register save_org_id to djangosaml2 pre_user_save"
)
from
djangosaml2.signals
import
pre_user_save
from
djangosaml2.signals
import
pre_user_save
def
save_org_id
(
sender
,
instance
,
attributes
,
**
kwargs
):
def
save_org_id
(
sender
,
instance
,
attributes
,
**
kwargs
):
logger
.
debug
(
"save_org_id called by
%
s"
,
instance
.
username
)
logger
.
debug
(
"save_org_id called by
%
s"
,
instance
.
username
)
atr
=
settings
.
SAML_ORG_ID_ATTRIBUTE
atr
=
settings
.
SAML_ORG_ID_ATTRIBUTE
...
@@ -403,6 +404,7 @@ if hasattr(settings, 'SAML_ORG_ID_ATTRIBUTE'):
...
@@ -403,6 +404,7 @@ if hasattr(settings, 'SAML_ORG_ID_ATTRIBUTE'):
return
False
# User did not change
return
False
# User did not change
pre_user_save
.
connect
(
save_org_id
)
pre_user_save
.
connect
(
save_org_id
)
...
@@ -415,7 +417,7 @@ def update_store_profile(sender, **kwargs):
...
@@ -415,7 +417,7 @@ def update_store_profile(sender, **kwargs):
profile
.
disk_quota
)
profile
.
disk_quota
)
except
NoStoreException
:
except
NoStoreException
:
logger
.
debug
(
"Store is not available."
)
logger
.
debug
(
"Store is not available."
)
except
(
NotOkException
,
Timeout
)
:
except
NotOkException
:
logger
.
critical
(
"Store is not accepting connections."
)
logger
.
critical
(
"Store is not accepting connections."
)
...
...
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