Merged changes from Pythonista version