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

Running castro on OSX #4

Open
jasonm opened this issue Nov 19, 2013 · 2 comments
Open

Running castro on OSX #4

jasonm opened this issue Nov 19, 2013 · 2 comments

Comments

@jasonm
Copy link

jasonm commented Nov 19, 2013

I feel like I'm getting close, but the generated SWF is only 70 bytes. Any ideas about the Socket errors / Broken pipe?

# get pygame something like http://juliaelman.com/blog/2013/04/02/installing-pygame-on-osx-mountain-lion/
brew install sdl sdl_ttf sdl_image sdl_mixer hg
pip install hg+http://bitbucket.org/pygame/pygame

# get castro
pip install castro

# Turn on VNC
* System Preferences > Sharing
* Enable Screen Sharing
* Allow access for all users
* Computer Settings > Enabled "VNC viewers may control screen with password" and set a password

# write an encrypted ~/.vnc/passwd file with your vnc password
mkdir ~/.vnc
cd /tmp
git clone https://github.com/trinitronx/vncpasswd.py.git
cd vncpasswd.py/
./vncpasswd.py -f ~/.vnc/passwd your-vnc-password

# encrypted password there seems legit
cat ~/.vnc/passwd  | base64
29g8/XJ6FFg=

# try it out
cd /tmp
python -c "import castro; castro.test()"

Recording a 10 second video...

10 Connected: localhost:5900, protocol_version=3.3, preferred_encoding=(0, -232, -239)
9 VNC Screen: size=5440x2340, name='Jason\xe2\x80\x99s MacBook Pro'
Output movie size: 5440x2340
Creating movie: '/var/folders/qz/4yw7g_b560j9ns1hqk86tyrr0000gn/T/castro-video.swf': version=5, size=5440x2340, framerate=12, compression=None
Socket error: [Errno 32] Broken pipe
8 Connected: localhost:5900, protocol_version=3.3, preferred_encoding=(0, -232, -239)
VNC Screen: size=5440x2340, name='Jason\xe2\x80\x99s MacBook Pro'
RFB error: Connection closed unexpectedly.
7 Connected: localhost:5900, protocol_version=3.3, preferred_encoding=(0, -232, -239)
6 VNC Screen: size=5440x2340, name='Jason\xe2\x80\x99s MacBook Pro'
RFB error: Connection closed unexpectedly.
5 Connected: localhost:5900, protocol_version=3.3, preferred_encoding=(0, -232, -239)
VNC Screen: size=5440x2340, name='Jason\xe2\x80\x99s MacBook Pro'
RFB error: Connection closed unexpectedly.
Writing: /var/folders/qz/4yw7g_b560j9ns1hqk86tyrr0000gn/T/castro-video.html...

ls -lah /var/folders/qz/4yw7g_b560j9ns1hqk86tyrr0000gn/T/castro-video.swf
-rw-r--r--  1 jason  staff    70B Nov 19 15:29 /var/folders/qz/4yw7g_b560j9ns1hqk86tyrr0000gn/T/castro-video.swf
@avlin-woods
Copy link

Hi Jasonm, I got the same error. Can you post an answer if you resolved already?

Thanks

@jasonm
Copy link
Author

jasonm commented Apr 17, 2014

@avlin-woods I never did. I was trying to record video on a CI server, and ended up using xvfb + avconv on ubuntu. Still curious how to do this on OSX, though.

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