Do you mean the error code of ls here? "output" is the return code, which should be 0 here but if there were an error that's where it'd end up. Could you describe what you're trying to do in more details?
Also, in the future, even if it's just 3 lines, please put all code in code tags.
Due to the reasons discussed here
we will be moving to python-forum.io
on October 1, 2016.
This forum will be locked down and no one will be able to post/edit/create threads, etc. here from thereafter. Please create an account at the new site to continue discussion.