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
getting width and height of an asciinema #234
Comments
The JSON files without width/height are produced by old (< 1.0.0) version of the player. asciinema.org still supports these clients but I plan to drop the support soon (these clients are 2-3 years old now). You can do the following. Check what's the first character in the file. If it's If it's |
thanks! i opted with not supporting it for now. and filed jbenet/asciinema-selfhost#4 |
in https://github.com/jbenet/asciinema-selfhost/ i used to get the size with: https://github.com/jbenet/asciinema-selfhost/blob/f2f2bd8fed21b42ee59d5e7b46b5fd09f0285b1e/index.js#L60-L61 which was pretty terrible but seemed to work always.
I'm updating it. Now, using the new
.json
url (eg https://asciinema.org/a/91304.json) some asciinema json files have thewidth/height
attributes, and some do not (eg https://asciinema.org/a/103367.json) (these were grabbed as examples randomly from public listing). Maybe all old versions of files need to be updated? Or if not, is there a better (robust) way to get the width/height always? Thanks!The text was updated successfully, but these errors were encountered: