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

can only throw objects #109

Closed
dbu opened this issue Sep 23, 2018 · 12 comments · Fixed by #111
Closed

can only throw objects #109

dbu opened this issue Sep 23, 2018 · 12 comments · Fixed by #111

Comments

@dbu
Copy link
Contributor

dbu commented Sep 23, 2018

Q A
Bug? yes
New Feature? no
Version 1.8.0

Actual Behavior

Error: Can only throw objects
/home/travis/build/php-http/HttplugBundle/vendor/php-http/client-common/src/Deferred.php:129
/home/travis/build/php-http/HttplugBundle/vendor/php-http/client-common/src/PluginClient.php:87
/home/travis/build/php-http/HttplugBundle/Tests/Functional/ProfilingTest.php:96

@Nyholm
Copy link
Member

Nyholm commented Sep 23, 2018

Ping @joelwurtz

@Nyholm
Copy link
Member

Nyholm commented Sep 23, 2018

I think, the issue is that $this->state is not updated after we execute the callback.
https://github.com/php-http/client-common/blob/1.8.0/src/Deferred.php#L118

@joelwurtz
Copy link
Member

I think it comes from the underlying promise that do not call onResolve / onFullfill callback no ?

@mxr576
Copy link
Contributor

mxr576 commented Sep 25, 2018

@joelwurtz @Nyholm any ETA for a fix for this? If someone installs our module with the latest version of the php-http/client-common lots of things gets broken and I do not want to create a new release just to blacklist php-http/client-common:>=1.8.0. Couldn't you rollback the related changes in a new 1.8.1 release until you can figure out how to address this problem properly?

Btw wasn't this change a BC breaking change so it should have been introduced in 2.x.y?

@joelwurtz
Copy link
Member

There is a fix in #110 if you have time to test it would be nice (but it fixes this bug on my end)

@mxr576
Copy link
Contributor

mxr576 commented Sep 25, 2018

@joelwurtz Please see my comment in #110.

@Jean85
Copy link
Contributor

Jean85 commented Sep 26, 2018

This is currently breaking the build in the incoming 2.0 release of the Sentry client: https://travis-ci.org/getsentry/sentry-php/jobs/433720358

#110 does not currently fix the issue. I'll have to add a conflict to ^1.8.0 until this is fixed.

@pascal-hofmann
Copy link

I ran into this issue too. Is there a reason for not pulling back the 1.8 release? I guess this will cause harm for more people…

mxr576 added a commit to mxr576/apigee-client-php that referenced this issue Oct 3, 2018
@mxr576
Copy link
Contributor

mxr576 commented Oct 8, 2018

Seriously guys, just rollback these changes... since two weeks all depending libs/projects are that uses the retry plugin with a synchronous client are broken. If you do not have time to find the proper fix for this is fine, this is open source, rolling back the problematic changes since 1.7.0 should not be that complicated/time consuming.

@Jean85
Copy link
Contributor

Jean85 commented Oct 8, 2018

#111 reverts everything but it's still pending...

@dbu dbu closed this as completed in #111 Oct 9, 2018
@dbu
Copy link
Contributor Author

dbu commented Oct 9, 2018

i released 1.8.1 with the revert now.

@dbu
Copy link
Contributor Author

dbu commented Oct 9, 2018

created #112 to document the problem but i don't plan to work on this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
6 participants