Comments (8)
A bit of background:
I had an issue reported (#6) for Mac OS X last week.
It seemed that there was a problem with some socket system calls on Mac OS X, so I have rewritten the exit logic using polling (instead of calling shutdown()
on the listening socket) at fb0d0a5.
However, I have tested this only on my Debian workstation, so I am not sure this fix works on Mac OS.
from trezor-agent.
Does the Resource temporarily unavailable
error happens all the time?
Does it happen always after the first list_pubs()
reply is sent?
What version of SSH client are you using on Mac OS X?
from trezor-agent.
An idea: can you tweak server.UNIX_SOCKET_TIMEOUT
constant (at https://github.com/romanz/trezor-agent/blob/master/trezor_agent/server.py#L13)?
Currently, it is set 100 ms, but it may be increased to a few seconds to check if it affects the error.
from trezor-agent.
It seems that EAGAIN on Mac OS X has errno=35:
http://stackoverflow.com/questions/14595269/errno-35-eagain-returned-on-recv-call
from trezor-agent.
If the problem is that the recv()
system call is failing with EAGAIN due to a timeout, could you please try the following patch (to make sure that the accepted connection is set to blocking mode) on Mac OS?
diff --git a/trezor_agent/server.py b/trezor_agent/server.py
index 38835fe..a04a3a4 100644
--- a/trezor_agent/server.py
+++ b/trezor_agent/server.py
@@ -63,6 +63,7 @@ def server_thread(server, handler, quit_event):
def accept_connection():
conn, _ = server.accept()
+ conn.settimeout(None)
return conn
while True:
from trezor-agent.
You can also now set the timeout via a command-line argument: b101281
from trezor-agent.
@romanz The conn.settimeout(None) fixed it. I tried with both KeepKey and Trezor and they both work.
from trezor-agent.
Great!
I will push the fix to master
.
from trezor-agent.
Related Issues (20)
- Rename NotFoundError exception to DeviceNotFoundError HOT 1
- ECDH curve hard-coded HOT 2
- Apply consistent style to imports in the hardware device agent scripts HOT 1
- Please enable discussions HOT 2
- [Suggestion] Use concurrency tag for GitHub workflows HOT 2
- Trezor session can't be reset if trezor-aegnt crashes or is killed during input HOT 2
- Unable to generate new GPG primary key HOT 8
- gpg addkey hangs for 2 days HOT 4
- gpg: signing failed: End of file HOT 4
- [gpg] Unable to init gpg identity HOT 4
- Invalid status 6a80 (Unknown reason)) communicating with LedgerNanoS
- protobuf issue with keepkey_agent 0.9.0
- ledger-agent <hostname> -vs fails to sign key HOT 6
- trezor-gpg-agent + pass + aws-vault does not work
- Unexpected behavior of trezor-gpg-agent after `trezorctl clear-session` call
- Risk of pip Typosquatting attack HOT 2
- age-plugin-trezor: support sessions
- trezor-gpg-agent cache expiration HOT 2
- Pinentry with trezor HOT 3
- Selection among multiple keys fails
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from trezor-agent.