Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
P
Printrun
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
machinery
Printrun
Commits
cf8cff2b
Commit
cf8cff2b
authored
Oct 12, 2013
by
Guillaume Seguin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use logError when appropriate in pronterface
parent
91b33f4b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
pronterface.py
printrun/pronterface.py
+7
-7
No files found.
printrun/pronterface.py
View file @
cf8cff2b
...
@@ -1455,7 +1455,7 @@ Printrun. If not, see <http://www.gnu.org/licenses/>."""
...
@@ -1455,7 +1455,7 @@ Printrun. If not, see <http://www.gnu.org/licenses/>."""
wx
.
CallAfter
(
self
.
gviz
.
Refresh
)
wx
.
CallAfter
(
self
.
gviz
.
Refresh
)
if
self
.
p
.
online
:
if
self
.
p
.
online
:
if
self
.
p
.
writefailures
>=
4
:
if
self
.
p
.
writefailures
>=
4
:
logging
.
e
rror
(
_
(
"Disconnecting after 4 failed writes."
))
self
.
logE
rror
(
_
(
"Disconnecting after 4 failed writes."
))
self
.
status_thread
=
None
self
.
status_thread
=
None
self
.
disconnect
()
self
.
disconnect
()
return
return
...
@@ -1818,19 +1818,19 @@ Printrun. If not, see <http://www.gnu.org/licenses/>."""
...
@@ -1818,19 +1818,19 @@ Printrun. If not, see <http://www.gnu.org/licenses/>."""
except
SerialException
as
e
:
except
SerialException
as
e
:
# Currently, there is no errno, but it should be there in the future
# Currently, there is no errno, but it should be there in the future
if
e
.
errno
==
2
:
if
e
.
errno
==
2
:
logging
.
e
rror
(
_
(
"Error: You are trying to connect to a non-existing port."
))
self
.
logE
rror
(
_
(
"Error: You are trying to connect to a non-existing port."
))
elif
e
.
errno
==
8
:
elif
e
.
errno
==
8
:
logging
.
e
rror
(
_
(
"Error: You don't have permission to open
%
s."
)
%
port
)
self
.
logE
rror
(
_
(
"Error: You don't have permission to open
%
s."
)
%
port
)
logging
.
e
rror
(
_
(
"You might need to add yourself to the dialout group."
))
self
.
logE
rror
(
_
(
"You might need to add yourself to the dialout group."
))
else
:
else
:
logging
.
e
rror
(
traceback
.
format_exc
())
self
.
logE
rror
(
traceback
.
format_exc
())
# Kill the scope anyway
# Kill the scope anyway
return
return
except
OSError
as
e
:
except
OSError
as
e
:
if
e
.
errno
==
2
:
if
e
.
errno
==
2
:
logging
.
e
rror
(
_
(
"Error: You are trying to connect to a non-existing port."
))
self
.
logE
rror
(
_
(
"Error: You are trying to connect to a non-existing port."
))
else
:
else
:
logging
.
e
rror
(
traceback
.
format_exc
())
self
.
logE
rror
(
traceback
.
format_exc
())
return
return
self
.
statuscheck
=
True
self
.
statuscheck
=
True
if
port
!=
self
.
settings
.
port
:
if
port
!=
self
.
settings
.
port
:
...
...
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