Electrum personal server rescan-script.py
Make sure that the wallet is enabled in Bitcoin Core. Electrum Personal Server relies on the wallet. Check that you are not starting Bitcoin Core with -disablewallet or that disablewallet=1 is not in your bitcoin.conf file.