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

crash on very long tokens #5

Closed
snarfed opened this issue Feb 1, 2017 · 1 comment
Closed

crash on very long tokens #5

snarfed opened this issue Feb 1, 2017 · 1 comment

Comments

@snarfed
Copy link
Contributor

@snarfed snarfed commented Feb 1, 2017

ran into this while working on snarfed/bridgy#723. not blocking me there, but figured it was worth tracking at least.

>>> brevity.shorten('X' * 141)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File ".../brevity.py", line 231, in shorten
    return ''.join(t.content for t in tokens)
TypeError: sequence item 0: expected string or Unicode, NoneType found

tokens at this point is [None, u'\u2026'].

@kylewm
Copy link
Owner

@kylewm kylewm commented Feb 1, 2017

whoa! weird, thanks

kylewm added a commit that referenced this issue Apr 23, 2017
@kylewm kylewm closed this in #7 Apr 23, 2017
snarfed added a commit to snarfed/granary that referenced this issue Apr 24, 2017
snarfed added a commit to snarfed/bridgy that referenced this issue Apr 26, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

2 participants