I think, Sage is Python language (although has operator ^ , Python has only **) plus many mathematical libraries.
Python code is possible to debug with PyCharm. Is possible debug Sage code?
How to use Sage with files? I am using only in command mode - paste from text file, but is possible using .sage files and import from my file.