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

It break's with some special characteres #12

Open
hugomosh opened this issue May 5, 2014 · 1 comment
Open

It break's with some special characteres #12

hugomosh opened this issue May 5, 2014 · 1 comment

Comments

@hugomosh
Copy link

hugomosh commented May 5, 2014

Excellent work! Thank you.
Just an observations If you feed it with things like:
x
:)
es genial¡¡¡¡¡¡

It throws and error like this:

exception 'RuntimeException' with message 'Invalid or missing outlinks' in C:\Users\personal\GoogleDrive\202_Librerias\LanguageDetector-master\lib\LanguageDetector\Sort\PageRank.php:152
Stack trace:
#0 C:\Users\personal\GoogleDrive\202_Librerias\LanguageDetector-master\lib\LanguageDetector\Detect.php(83): LanguageDetector\Sort\PageRank->sort(Array)
#1 C:\Users\personal\GoogleDrive\202_Librerias\LanguageDetector-master\lib\LanguageDetector\Detect.php(122): LanguageDetector\Detect->detectChunk('!')
#2 C:\Users\personal\GoogleDrive\202_Librerias\LanguageDetector-master\example\detectaIdiomaALista.php(24): LanguageDetector\Detect->detect('!')

Just saying, so it can be more robust 👍

Maybe it could give "ascii art" as language : P

@crodas
Copy link
Owner

crodas commented May 6, 2014

Good idea. If it fails to parse UTF-8 it should treat the input as an stream of bytes.

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