Git Product home page Git Product logo

kaas's People

Contributors

chrisjrn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

kaas's Issues

Not work on current OS X Yosemite

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'
----------------------------------------

Keynote 6.2: Client-Server synchronisation does not work

Keynote 6 removes AppleScript support for determining which slide is currently visible in the slide show. This means the server is unable to present the current slide via the API.

This needs a short-term workaround (use KAAS as the source of truth instead of Keynote for now?); and a long-term fix from Apple.

PIN lock on server

Use HMAC authentication to guarantee that all requests originate from an authorised device.

Support Keynote 6

Keynote 6 now has an AppleScript API. It is largely similar to Keynote 5's; exports seems to have some minor syntactic changes.

Version of a given app can be found by using applescript

tell application "foo" to version

This returns the version code of foo. A path to a specific app bundle can be provided where foo is.

K6 installation puts K5.x into a separate location on the filesystem.

Behaviour should be:

  • If K6 is installed, default to K6 unless overridden.
  • If K5 is requested, or K5 is not installed, find and use K5.
  • API should only offer an option if K5 and K6 are installed.

Server error with Keynote 6.3

I got a execution error with the following traceback:

123:130: execution error: The variable Classic is not defined. (-2753)
Traceback (most recent call last):
  File "remote_server.py", line 215, in <module>
    main()
  File "remote_server.py", line 199, in main
    set_show()
  File "remote_server.py", line 161, in set_show
    STATE.show = slideshow.generate()
  File "/Users/nikriek/Downloads/kaas-master/kaas/slideshow.py", line 199, in generate
    return Slideshow(keynote_script.APPLICATION_VERSION, path, out_dir)
  File "/Users/nikriek/Downloads/kaas-master/kaas/slideshow.py", line 35, in __init__
    self.__kpf__ = kpfutil_v6.KpfV6(kpfdir)
  File "/Users/nikriek/Downloads/kaas-master/kaas/kpfutil_v6.py", line 63, in __init__
    self.generate_notes()
  File "/Users/nikriek/Downloads/kaas-master/kaas/kpfutil_v6.py", line 109, in generate_notes
    keynote_script.export_classic(f)
  File "/Users/nikriek/Downloads/kaas-master/kaas/keynote_script.py", line 95, in export_classic
    return __execute__(command)
  File "/Users/nikriek/Downloads/kaas-master/kaas/keynote_script.py", line 125, in __execute__
    return __execute_with_app__(INSTALLED_VERSIONS[APPLICATION_VERSION], command)
  File "/Users/nikriek/Downloads/kaas-master/kaas/keynote_script.py", line 131, in __execute_with_app__
    return check_output(["osascript", "-e", to_run]).strip()
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 575, in check_output
    raise CalledProcessError(retcode, cmd, output=output)
subprocess.CalledProcessError: Command '['osascript', '-e', 'tell application "/Applications/Keynote.app" to export front document to POSIX file "/var/tmp/tmp.0.guJaCa/classic.key" as Classic']' returned non-zero exit status 1

Any ideas why? I'm not that python-experienced to fix it myself… Maybe it has something to do with recent API changes in Keynote?!

Merge forks

There are tho other forks. I think it will be better to collaborate on maintaining of just one project. Don't you think?

@BobertForever @lgleasain

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.