guzzle / guzzle-services

Provides an implementation of the Guzzle Command library that uses Guzzle service descriptions to describe web services, serialize requests, and parse responses into easy to use model structures.
MIT License
253 stars 78 forks source link

combine method in Uri #101

Closed bakura10 closed 7 years ago

bakura10 commented 8 years ago

Hi,

I'm trying the Guzzle 6 branch (but the issue seems to exist on master branch as well). The Serializer is attempting to call "combine" (https://github.com/guzzle/guzzle-services/blob/master/src/Serializer.php#L167) over a GuzzleHttp\Psr7\Uri object, but this method does not exist (so it fails, obviously): https://github.com/guzzle/psr7/blob/master/src/Uri.php

alexdruhet commented 8 years ago

Hi, I'm facing the same issue while trying to update a Symfony 2 app to Symfony 3. I have not find any fix or replacement yet. Any ideas are welcome!

Mgibs commented 8 years ago

I have a workaround for this issue. In the file Serializer.php, line 152, replace $this->description->getBaseUrl()->combine($uri) with $this->description->getBaseUrl().$uri

Mgibs commented 8 years ago

A cleaner way maybe is to replace with this : Uri::resolve($this->description->getBaseUrl(),$uri) Dont forget tu use Uri namespace

guiyomh commented 8 years ago

👍

Konafets commented 8 years ago

@bakura10 Please checkout and test PR #109. Is the issue still valid?

Konafets commented 7 years ago

Just released version 1.0.0 which is compatible with Guzzle 6. I will close the issue, feel free to reopen it, if your problem still exists.