Skip to content
This repository has been archived by the owner on Feb 19, 2022. It is now read-only.

TypeError: frameIterator.patch is not a function #65

Closed
clifton opened this issue Mar 16, 2017 · 3 comments
Closed

TypeError: frameIterator.patch is not a function #65

clifton opened this issue Mar 16, 2017 · 3 comments
Labels

Comments

@clifton
Copy link

clifton commented Mar 16, 2017

When using setCacheStrategy on a memcached-backed store that returns promises I'm getting the following error:

node_modules/rapscallion/lib/sequence/sequence.js:49
      delegate();
      ^
TypeError: frameIterator.patch is not a function

config:

setCacheStrategy({
  get: (key) => cacheStore.get(key),
  set: (key, val) => cacheStore.set(key, val)
});

Adapter source is here but it is relatively simple (get/set returns promises and gets are batched).

@bmathews
Copy link
Contributor

This is due to the instanceof Promise check we're doing, where Promise in our scope is Bluebird rather than a native Promise. We should probably just check if it is thenable.

@clifton
Copy link
Author

clifton commented Mar 16, 2017

ah, I'll use Bluebird for the time being. Thanks for the quick response!

@divmain divmain added the bug label Mar 17, 2017
@divmain
Copy link
Contributor

divmain commented Mar 17, 2017

Yeah, we'll change this to check for thenables. Thanks for opening the issue @clifton!

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

No branches or pull requests

3 participants