Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
coco
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ops
coco
Commits
d864a94e
Commit
d864a94e
authored
Mar 18, 2019
by
ibuler
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Update] 添加debug信息
parent
6297328b
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
8 additions
and
6 deletions
+8
-6
app.py
coco/app.py
+1
-0
connector.py
coco/httpd/elfinder/connector.py
+1
-3
ws.py
coco/httpd/ws.py
+2
-1
models.py
coco/models.py
+1
-1
sftp.py
coco/sftp.py
+1
-0
sshd.py
coco/sshd.py
+1
-0
utils.py
coco/utils.py
+1
-1
No files found.
coco/app.py
View file @
d864a94e
...
...
@@ -191,6 +191,7 @@ class Coco:
check_session_idle_too_long
(
s
)
except
Exception
as
e
:
logger
.
error
(
"Unexpected error occur: {}"
.
format
(
e
))
logger
.
error
(
e
,
exc_info
=
True
)
time
.
sleep
(
interval
)
thread
=
threading
.
Thread
(
target
=
func
)
thread
.
start
()
...
...
coco/httpd/elfinder/connector.py
View file @
d864a94e
...
...
@@ -110,9 +110,7 @@ class ElFinderConnector:
func
()
except
Exception
as
e
:
self
.
response
[
'error'
]
=
'
%
s'
%
e
logger
.
error
(
"Error occur ------------------------------"
)
logger
.
exception
(
e
)
logger
.
error
(
"Error end ------------------------------"
)
logger
.
error
(
e
,
exc_info
=
True
)
def
get_request_data
(
self
):
data_source
=
{}
...
...
coco/httpd/ws.py
View file @
d864a94e
...
...
@@ -87,6 +87,7 @@ class ProxyNamespace(BaseNamespace):
forwarder
.
proxy
()
except
Exception
as
e
:
logger
.
error
(
"Unexpected error occur: {}"
.
format
(
e
))
logger
.
error
(
e
,
exc_info
=
True
)
self
.
logout
(
client_id
,
connection
)
self
.
socketio
.
start_background_task
(
proxy
)
...
...
@@ -175,7 +176,7 @@ class ProxyNamespace(BaseNamespace):
try
:
self
.
on_logout
(
client_id
)
except
Exception
as
e
:
logger
.
warn
(
e
)
logger
.
error
(
e
,
exc_info
=
Tru
e
)
Connection
.
remove_connection
(
connection
.
id
)
def
logout
(
self
,
client_id
,
connection
):
...
...
coco/models.py
View file @
d864a94e
...
...
@@ -326,7 +326,7 @@ class BaseServer(object):
self
.
s_parse_input_output_filter
(
data
)
data
=
self
.
s_filter_cmd_filter
(
data
)
except
Exception
as
e
:
logger
.
e
xception
(
e
)
logger
.
e
rror
(
e
,
exc_info
=
Tru
e
)
return
self
.
chan
.
send
(
data
)
def
recv
(
self
,
size
):
...
...
coco/sftp.py
View file @
d864a94e
...
...
@@ -35,6 +35,7 @@ def convert_error(func):
error
=
e
response
=
SFTP_EOF
except
Exception
as
e
:
logger
.
error
(
e
,
exc_info
=
True
)
error
=
e
response
=
SFTP_FAILURE
finally
:
...
...
coco/sshd.py
View file @
d864a94e
...
...
@@ -102,6 +102,7 @@ class SSHServer:
logger
.
warning
(
"Handle connection EOF Error: {}"
.
format
(
e
))
except
Exception
as
e
:
logger
.
error
(
"Unexpect error occur on handle connection: {}"
.
format
(
e
))
logger
.
error
(
e
,
exc_info
=
True
)
finally
:
Connection
.
remove_connection
(
connection
.
id
)
sock
.
close
()
...
...
coco/utils.py
View file @
d864a94e
...
...
@@ -463,7 +463,7 @@ def ignore_error(func):
resp
=
func
(
*
args
,
**
kwargs
)
return
resp
except
Exception
as
e
:
logger
.
error
(
"Error occur: {} {}"
.
format
(
func
.
__name__
,
e
)
)
logger
.
error
(
e
,
exc_info
=
True
)
return
wrapper
...
...
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