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

PHP 8.0: Class MongoDB\Driver\Cursor must implement interface Traversable as part of either Iterator or IteratorAggregate #715

Closed
cytopia opened this issue Aug 9, 2020 · 4 comments
Assignees
Labels

Comments

@cytopia
Copy link
Owner

cytopia commented Aug 9, 2020

ISSUE TYPE

  • Question

SUMMARY

When trying to compile MongoDB for PHP 8.0 it seems to work somehow. However, when then running PHP I get the following startup error:

PHP Fatal error:  Class MongoDB\Driver\Cursor must implement interface Traversable as part of either Iterator or IteratorAggregate in Unknown on line 0

Does anyone know how to fix this for PHP 8.0?

Goal

Re-enable mongodb extension for PHP 8.0 without errors.

Update

Upstream issue: mongodb/mongo-php-driver#1161

@vulcangz
Copy link

vulcangz commented Aug 9, 2020

Refer to this issue, maybe it is caused by adminer??
Query Result Object should implement Countable Interface #742

@cytopia
Copy link
Owner Author

cytopia commented Aug 9, 2020

@vulcangz thanks for the link. Unfortunately this is not it. It is only present in PHP 8.0 and during startup. For instance if I do a php -v on the command the fatal will already be thrown.

@cytopia
Copy link
Owner Author

cytopia commented Sep 13, 2020

Upstream issue is being tracked here: mongodb/mongo-php-driver#1161

@cytopia cytopia self-assigned this Sep 13, 2020
This was referenced Nov 7, 2020
@cytopia
Copy link
Owner Author

cytopia commented Nov 9, 2020

#743

@cytopia cytopia closed this as completed Nov 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants