# Failed to run custom action error

**URL:** <https://forum.rasa.com/t/failed-to-run-custom-action-error/4740>\
**Category:** Rasa Open Source\
**Created:** [January 29, 2019, 11:40am UTC](https://forum.rasa.com/t/failed-to-run-custom-action-error/4740 "2019-01-29T11:40:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Arghya\_Ganguly](https://avatars.discourse-cdn.com/v4/letter/a/8797f3/32.png) [@Arghya\_Ganguly](https://forum.rasa.com/u/Arghya_Ganguly)\
**Post date:** [January 29, 2019, 11:40am UTC](https://forum.rasa.com/t/failed-to-run-custom-action-error/4740/1 "2019-01-29T11:40:00Z")

</div>

I am using a Jupyter notebook to train both nlu(intent/entity classifier) and rasa core(Dialog management). I have a set of custom actions which are stored in a separate actions.py file.

content of endpoints.yml :- action\_endpoint: url: “[http://action:5055/webhook](http://action:5055/webhook)”

I start the action server and it looks good :- python -m rasa\_core\_sdk.endpoint --actions actions

Output:- INFO: **main** :Starting action endpoint server… DEBUG:pykwalify.compat:Using yaml library: /home/arghya/anaconda3/envs/myenv/lib/python3.6/site-packages/ruamel/yaml/ **init**.py INFO:rasa\_core\_sdk.executor:Registered function for ‘action\_save\_city\_name’. INFO:rasa\_core\_sdk.executor:Registered function for ‘action\_save\_model\_name’. INFO:rasa\_core\_sdk.executor:Registered function for ‘action\_slot\_reset’. INFO:rasa\_core\_sdk.executor:Registered function for ‘action\_get\_service\_centre\_location’. INFO:rasa\_core\_sdk.executor:Registered function for ‘action\_get\_shop\_location’. INFO:rasa\_core\_sdk.executor:Registered function for ‘action\_get\_model\_price’. INFO:rasa\_core\_sdk.executor:Registered function for ‘action\_get\_model\_config’. INFO: **main** :Action endpoint is up and running. on (‘0.0.0.0’, 5055)

after which i am starting the rasa core dialog engine in a different terminal :- python -m rasa\_core.run -d models/dialogue -u models/nlu/default/current --endpoints endpoints.yml

Output :- The dialog engine starts but gives “failed to run custom action” error when it is about to run a custom action.

ERROR rasa\_core.actions.action - Failed to run custom action ‘action\_save\_city\_name’. Couldn’t connect to the server at ‘[http://action:5055/webhook](http://action:5055/webhook)’. Is the server running? Error: HTTPConnectionPool(host=‘action’, port=5055): Max retries exceeded with url: /webhook (Caused by NewConnectionError(’\<urllib3.connection.HTTPConnection object at 0x7fd5c568d470\>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution’,)) 2019-01-29 16:57:45 ERROR rasa\_core.processor - Encountered an exception while running action ‘action\_save\_city\_name’. Bot will continue, but the actions events are lost. Make sure to fix the exception in your custom code.

What am I doing wrong?

---

<div class="post-metadata">

**Author:** ![ness](https://avatars.discourse-cdn.com/v4/letter/n/b5a626/32.png) [@ness](https://forum.rasa.com/u/ness)\
**Post date:** [January 30, 2019, 2:10pm UTC](https://forum.rasa.com/t/failed-to-run-custom-action-error/4740/2 "2019-01-30T14:10:47Z")

</div>

why action:5055 should be like this:

action\_endpoint: url:[http://localhost:5055/webhook](http://localhost:5055/webhook)

and did u run: python -m rasa\_core\_sdk.endpoint --actions actions
