Re-running a dash app from another jupyter notebook

Hi,

I have a jupyter notebook that launches a dash app on a specified port number. In other words it looks like this:

#500 lines of data prep, layout, callbacks#
app.run_server(debug = False, port = 6116, host='0.0.0.0')

This app updates a data source in those upfront lines of code. To keep the app up to date, I need to go in, interrupt the kernel and run the whole app. Also i have several such apps.

What i’d like to do is create a master notebook where i can call this app and run it.
So, in that other notebook i would have a cell (for each app) that says
%run app1.ipynb
As it stands now, because the app is still running, i get

OSError: [Errno 98] Address already in use

Question is - is there a way to either stop the app before running it or add an option somehow to the run_server command to ‘overwrite’ or ‘push aside’ any running processes?

Thanks!