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

Fetch api compatibility #133

Closed
adamschoenemann opened this issue Feb 18, 2015 · 12 comments · Fixed by #159
Closed

Fetch api compatibility #133

adamschoenemann opened this issue Feb 18, 2015 · 12 comments · Fixed by #159

Comments

@adamschoenemann
Copy link

Fetch does not work as expected in Chrome Canary, where fetch is a native implementation. My main issue was with the http source, in the getHeader function, there is a use of headers.map which appears to be non-standard, or at least not implemented in Chrome Canary nor original fetch polyfill (as far as I can see). Using the Headers.get() method instead should fix this issue

@jhollingworth
Copy link
Contributor

hey, thanks for pointing this out. I will get a fix out asap

@adamschoenemann
Copy link
Author

Thanks! 👍

@jhollingworth jhollingworth mentioned this issue Feb 21, 2015
50 tasks
@jhollingworth
Copy link
Contributor

This is fixed in v0.9 which should be out soon

@vid
Copy link

vid commented Mar 2, 2015

I'm finding essential code which worked prior to the latest Canary now doesn't work. The problem seems to be it is consuming the body (bodyUsed: true) yet the value (res.json()) is still a promise after then() completes.

return this.post({ url: '/login', body: credentials }).then(function(res) {
  var v = res.json();
  console.log('P', res, 'v', v, res.body);
  // P {…bodyUsed: true } v Promise… undefined
  return LoginActions.loginResult(credentials, v);
});

Just wondering if you'll be releasing v0.9 very soon or if I should try to find a workaround. thanks!

@jhollingworth
Copy link
Contributor

I can do a hotfix on the v0.8 branch if this is an issue

@vid
Copy link

vid commented Mar 2, 2015

If this is a known problem then that would be really helpful. My code only broke since updating Chrome.

@jhollingworth
Copy link
Contributor

Hey, Marty v0.8.13 is out which has the fix for this bug.

@vid
Copy link

vid commented Mar 3, 2015

thanks for that. I haven't been able to fully test it due to another issue but on first glance it fixes the problem. one little issue is I had to manually install babel from the marty directory.

@jhollingworth
Copy link
Contributor

Hmm, that shouldn't be needed. I think babelify leaked in from the v0.9 release. I will switch that back now.

Thanks

On 3 Mar 2015, at 7:18 pm, David H. Mason notifications@github.com wrote:

thanks for that. I haven't been able to fully test it due to another issue but on first glance it fixes the problem. one little issue is I had to manually install babel from the marty directory.


Reply to this email directly or view it on GitHub.

@jhollingworth
Copy link
Contributor

This is fixed in v0.8.14

Thanks

@vid
Copy link

vid commented Mar 5, 2015

I had to manually install reactify as well. (=

@jhollingworth
Copy link
Contributor

should be fixed now. Sorry about this

On 5 March 2015 at 17:20, David H. Mason notifications@github.com wrote:

I had to manually install reactify as well. (=


Reply to this email directly or view it on GitHub
#133 (comment).

http://twitter.com/jhollingworth | http://github.com/jhollingworth |
http://linkedin.com/in/jhollingworth | +44 7866 843 864

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

Successfully merging a pull request may close this issue.

3 participants