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

Perplexing Request/Thenable/then Behavior #2775

Open
CNSKnight opened this issue Oct 27, 2016 · 1 comment
Open

Perplexing Request/Thenable/then Behavior #2775

CNSKnight opened this issue Oct 27, 2016 · 1 comment

Comments

@CNSKnight
Copy link

CNSKnight commented Oct 27, 2016

v1.5.2
Two issues:
I intermittently get a thenable back from Request w/no .then method?

r = new Request.JSON({url: 'https://someplace.net/api/'})
Object {$chain: Array[0], $events: F, options: Object, $caller: null, $family: null…}
r.then
undefined

When it accepts the .then, neither callback applied ever gets called?

r = new Request({url: ..., onFailure: ...);
r.then(success, failure); // neither gets called even on a 200 response
--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/38800465-perplexing-request-thenable-then-behavior?utm_campaign=plugin&utm_content=tracker%2F22067&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F22067&utm_medium=issues&utm_source=github).
@timwienk
Copy link
Member

v1.5.2

I think there is a mixup somewhere, Class.Thenable was introduced in 1.6.0. So if you're using 1.5.2, the Request.JSON classes won't inherit from the Class.Thenable mixin since it doesn't exist yet.

Could you check again? Could it be that multiple versions are loaded and a race condition makes for the inconsistent behaviour?

In case it helps:

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

No branches or pull requests

2 participants