Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not work on current OS X Yosemite #11

Open
iBobik opened this issue Nov 17, 2014 · 3 comments
Open

Not work on current OS X Yosemite #11

iBobik opened this issue Nov 17, 2014 · 3 comments

Comments

@iBobik
Copy link

iBobik commented Nov 17, 2014

I run the server as writen in README, but it firstly had problem with some permissons issues in my /Applications folder (it is issue, but it should not stop kaas):

Bobik-MacBook-Pro-2:kaas Bobik$ ./remote_server.py 
Traceback (most recent call last):
  File "./remote_server.py", line 31, in <module>
    import remote_handler
  File "/Users/Bobik/Applications/kaas/kaas/remote_handler.py", line 17, in <module>
    import keynote_script
  File "/Users/Bobik/Applications/kaas/kaas/keynote_script.py", line 204, in <module>
    INSTALLED_VERSIONS = __scan_for_apps__()
  File "/Users/Bobik/Applications/kaas/kaas/keynote_script.py", line 185, in __scan_for_apps__
    candidates = walk_selective("/Applications", [])
  File "/Users/Bobik/Applications/kaas/kaas/keynote_script.py", line 183, in walk_selective
    walk_selective(ff, found)
  File "/Users/Bobik/Applications/kaas/kaas/keynote_script.py", line 183, in walk_selective
    walk_selective(ff, found)
  File "/Users/Bobik/Applications/kaas/kaas/keynote_script.py", line 174, in walk_selective
    files = os.listdir(dir)
OSError: [Errno 13] Permission denied: '/Applications/Hry/Prehistorik 2.boxer'

I repaired permission in this folder and run server again. It wrote this errors (web service is not accessible):

Bobik-MacBook-Pro-2:kaas Bobik$ ./remote_server.py 
Generating export from frontmost keynote slideshow...
/Users/Bobik/Applications/kaas/kaas/slideshow.py:204: RuntimeWarning: tmpnam is a potential security risk to your program
  out_dir = os.tmpnam()
Output:  /var/tmp/tmp.0.t28hkB
Keynote version:  6.5
Generating build previews...
Starting server...
Now serving on: http://192.168.0.15:8000
The PIN number is: 431331
----------------------------------------
Exception happened during processing of request from ('192.168.0.15', 53865)
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 283, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 309, in process_request
    self.finish_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 322, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 617, in __init__
    self.handle()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 329, in handle
    self.handle_one_request()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 323, in handle_one_request
    method()
  File "./remote_server.py", line 68, in do_GET
    if not self.authenticate():
  File "./remote_server.py", line 115, in authenticate
    nonce = self.headers["X-Kaas-Nonce"]
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/rfc822.py", line 388, in __getitem__
    return self.dict[name.lower()]
KeyError: 'x-kaas-nonce'
----------------------------------------
----------------------------------------
Exception happened during processing of request from ('192.168.0.15', 53866)
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 283, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 309, in process_request
    self.finish_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 322, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 617, in __init__
    self.handle()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 329, in handle
    self.handle_one_request()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 323, in handle_one_request
    method()
  File "./remote_server.py", line 68, in do_GET
    if not self.authenticate():
  File "./remote_server.py", line 115, in authenticate
    nonce = self.headers["X-Kaas-Nonce"]
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/rfc822.py", line 388, in __getitem__
    return self.dict[name.lower()]
KeyError: 'x-kaas-nonce'
----------------------------------------
----------------------------------------
Exception happened during processing of request from ('192.168.0.15', 53867)
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 283, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 309, in process_request
    self.finish_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 322, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 617, in __init__
    self.handle()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 329, in handle
    self.handle_one_request()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 323, in handle_one_request
    method()
  File "./remote_server.py", line 68, in do_GET
    if not self.authenticate():
  File "./remote_server.py", line 115, in authenticate
    nonce = self.headers["X-Kaas-Nonce"]
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/rfc822.py", line 388, in __getitem__
    return self.dict[name.lower()]
KeyError: 'x-kaas-nonce'
----------------------------------------
----------------------------------------
Exception happened during processing of request from ('192.168.0.15', 53877)
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 283, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 309, in process_request
    self.finish_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 322, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 617, in __init__
    self.handle()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 329, in handle
    self.handle_one_request()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 323, in handle_one_request
    method()
  File "./remote_server.py", line 68, in do_GET
    if not self.authenticate():
  File "./remote_server.py", line 115, in authenticate
    nonce = self.headers["X-Kaas-Nonce"]
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/rfc822.py", line 388, in __getitem__
    return self.dict[name.lower()]
KeyError: 'x-kaas-nonce'
----------------------------------------
----------------------------------------
Exception happened during processing of request from ('192.168.0.15', 53878)
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 283, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 309, in process_request
    self.finish_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 322, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 617, in __init__
    self.handle()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 329, in handle
    self.handle_one_request()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 323, in handle_one_request
    method()
  File "./remote_server.py", line 68, in do_GET
    if not self.authenticate():
  File "./remote_server.py", line 115, in authenticate
    nonce = self.headers["X-Kaas-Nonce"]
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/rfc822.py", line 388, in __getitem__
    return self.dict[name.lower()]
KeyError: 'x-kaas-nonce'
----------------------------------------
----------------------------------------
Exception happened during processing of request from ('192.168.0.15', 53879)
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 283, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 309, in process_request
    self.finish_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 322, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 617, in __init__
    self.handle()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 329, in handle
    self.handle_one_request()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 323, in handle_one_request
    method()
  File "./remote_server.py", line 68, in do_GET
    if not self.authenticate():
  File "./remote_server.py", line 115, in authenticate
    nonce = self.headers["X-Kaas-Nonce"]
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/rfc822.py", line 388, in __getitem__
    return self.dict[name.lower()]
KeyError: 'x-kaas-nonce'
----------------------------------------
----------------------------------------
Exception happened during processing of request from ('192.168.0.15', 53901)
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 283, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 309, in process_request
    self.finish_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 322, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 617, in __init__
    self.handle()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 329, in handle
    self.handle_one_request()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 323, in handle_one_request
    method()
  File "./remote_server.py", line 68, in do_GET
    if not self.authenticate():
  File "./remote_server.py", line 115, in authenticate
    nonce = self.headers["X-Kaas-Nonce"]
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/rfc822.py", line 388, in __getitem__
    return self.dict[name.lower()]
KeyError: 'x-kaas-nonce'
----------------------------------------
----------------------------------------
Exception happened during processing of request from ('192.168.0.15', 53902)
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 283, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 309, in process_request
    self.finish_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 322, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 617, in __init__
    self.handle()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 329, in handle
    self.handle_one_request()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 323, in handle_one_request
    method()
  File "./remote_server.py", line 68, in do_GET
    if not self.authenticate():
  File "./remote_server.py", line 115, in authenticate
    nonce = self.headers["X-Kaas-Nonce"]
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/rfc822.py", line 388, in __getitem__
    return self.dict[name.lower()]
KeyError: 'x-kaas-nonce'
----------------------------------------
----------------------------------------
Exception happened during processing of request from ('192.168.0.15', 53903)
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 283, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 309, in process_request
    self.finish_request(request, client_address)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 322, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 617, in __init__
    self.handle()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 329, in handle
    self.handle_one_request()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 323, in handle_one_request
    method()
  File "./remote_server.py", line 68, in do_GET
    if not self.authenticate():
  File "./remote_server.py", line 115, in authenticate
    nonce = self.headers["X-Kaas-Nonce"]
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/rfc822.py", line 388, in __getitem__
    return self.dict[name.lower()]
KeyError: 'x-kaas-nonce'
----------------------------------------
@chrisjrn
Copy link
Owner

Part 1's a genuine bug -- we should be catching and ignoring permissions errors like that.

Part 2 -- this is happening because the API is running in authenticated mode, and you haven't authenticated. You can either make authenticate() always return True, or you can make your client code implement the authentication protocol that's in the documentation. This is working as intended.

@iBobik
Copy link
Author

iBobik commented Nov 17, 2014

Part 2:
It did not asked for permission. It should if in need it, or provide understandable messige and instructions what to do, not error understandable only for author :-)

@chrisjrn
Copy link
Owner

I agree it's not great -- as I've mentioned earlier, this is somewhat
under-maintained at the moment while Keynote 6 isn't working properly. So
it's still 0.1-level quality. That said, I've made a bit of effort to
document it here:
https://github.com/chrisjrn/kaas/blob/master/docs/HTTP_DOCS.md

On 18 November 2014 09:00, Jan Pobořil [email protected] wrote:

Part 2:
It did not asked for permission. It should if in need it, or provide
understandable messige and instructions what to do, not error
understandable only for author :-)


Reply to this email directly or view it on GitHub
#11 (comment).

--Christopher Neugebauer

Jabber: [email protected] -- IRC: chrisjrn on irc.freenode.net -- WWW:
http://chris.neugebauer.id.au -- Twitter: @chrisjrn

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants