Double class name ListItem


I’m a newbie to Contentful trying the php SDK. I created a test space in the contentful app with a bookstore model as suggested in your example.

I followed the SDK readme but when I run my index file I start with this error in the very beginning:

Fatal error: Cannot use Contentful\RichText\Node\ListItem as ListItem because the name is already in use in /Users/vpruefert/work/contentful/contentful.php/vendor/contentful/rich-text/src/NodeMapper/OrderedList.php on line 15

So it seems these two class names collide.

I did not used any rich text fields nor list items in my model, my index looks like this:


require_once 'vendor/autoload.php';

$client = new \Contentful\Delivery\Client(

As I said I’m totally new to this, maybe I’m missing a basic concept here.

Please help!

It works with PHP 7.3.4 (used PHP 7.0.8 before)