Search code examples
openwhisk

What is an OpenWhisk 'collection'?


What causes an action to give an error "Resource by this name exists but is not in this collection?"

From this question, there is a specific case of name collisions between triggers, rules, and actions. But for me, there is nothing except a single action that I can not modify.

$ wsk -i rule list
rules
$ wsk -i trigger list
triggers
$ wsk -i action list
actions
/guest/getgoods/getgoods                                               private rust:1.34
$ wsk -i action delete getgoods
error: Unable to delete action 'getgoods': Resource by this name exists but is not in this collection. (code tv2u2w09oog8Z5y2ONGuGvLCvBErctga)
Run 'wsk --help' for usage.

For added info, I got an action into this state by using wskdeploy with a Rust action. I am able to deploy the same action (under a different name) with a wsk action create command just fine.


Solution

  • This error also comes while accessing action as a package, the name of your package and action is the same. Try this

    wsk -i action delete getgoods/getgoods