yooper / php-text-analysis

PHP Text Analysis is a library for performing Information Retrieval (IR) and Natural Language Processing (NLP) tasks using the PHP language
https://github.com/yooper/php-text-analysis/wiki
MIT License
527 stars 87 forks source link

PHP 7.4 compatability #66

Closed tabennett closed 3 years ago

tabennett commented 4 years ago

Is there any way that this package could be updated to require wamania/php-stemmer ~2 (instead of ~1) for php 7.4 compatibility? I can PR this if you'd like.

yooper commented 4 years ago

Hello, yes, I would definitely appreciate the contribution. Please make sure the unit tests pass before submitting a PR.

Thanks,

tabennett commented 3 years ago

Sorry I'm late on this; I mean to get started on this earlier but the past few months since I opened this issue have been pretty crazy. I've forked this Repo now and would like to help get this compatible with php 7.4 and 8.x if you still want the help. I see you're already working on some 7.4 stuff and I don't wanna step on your toes before I PR this.

I've installed composer dependencies and ran the test suite but there were failure from missing directories. Looked around a bit and it seems like I need to install some pta data packages using the textconsole. So I've got those installing now. Is there anything else I'll need to run these? I already have java installed too (saw that on the wiki).

yooper commented 3 years ago

@tabennett , you can skip the tests the have a dependency by setting the SKIP_TEST=1

for example

SKIP_TEST=1 ./vendor/bin/phpunit

Any help supporting PHP 8 would be great.

yooper commented 3 years ago

@tabennett , I am going to close this ticket since the library does support php 7.4. We can create a separate issue to support PHP 8 at a later time.