Name is required.
Email address is required.
Invalid email address
Answer is required.
Exceeding max length of 5KB

Python Editor

Hi does anyone edit their python code in anything other than the Python compononent.
Are there any clever ways to debug the python script.
Also a suggestion for the development team - it would be useful if you were prompted to save changes on exiting the python component. I've lost work a few times because of this.
Thanks,
David.

6 Community Answers

Matillion Agent  

Ian Funnell —

Hi David,

If you prefer you can edit code externally (in any editor), get it working, and then finally paste into the Matillion code editor.

Regarding the save changes prompt, do you mean when you press Cancel?

Best regards,
Ian


David Brown —

Thanks Ian. The issue with cancel was if you press escape, you just leave the editor with no prompt that you are going to lose your work..


David Brown —

I suppose the one question i have remaining is does anyone have a code snippet that allows me to connect to our redshift environment, in place of what Matillion does behind the scenes.


Matillion Agent  

Kalyan Arangam —

Hi David,

I have raised a change request to EMD-6623 to prompt for Save on hitting ESC.

On your other query – I’ve seen these requests in the past when someone needed to work with Redshift from Python2 or Python3. In this case, you may install psycopg2 and connect to redshift.

Are there specific requirements besides the above usecase?

Best
Kalyan


David Brown —

Thanks Kalyan.
I will investigate the psycopg2.
Another glitch with the python editor is how it handles indentation. Sometimes it uses spaces and sometimes tabs. Now I am familiar with it, I just correct them by habit, but it maybe something else to improve..


Matillion Agent  

Kalyan Arangam —

I will add that suggestion to the same ticket.
Thanks for the feedback.

Kalyan

Post Your Community Answer

To add an answer please login