Re: [Tutor] subprocess.getstatusoutput : UnicodeDecodeError

2017-09-21 Thread Evuraan
> > getstatusoutput is a "legacy" function. It still exists for code that > has already been using it, but it is not recommended for new code. > > https://docs.python.org/3.5/library/subprocess.html#using-the-subprocess-module > > Since you're using Python 3.5, let's try using the brand new `run` >

Re: [Tutor] subprocess.getstatusoutput : UnicodeDecodeError

2017-09-21 Thread Steven D'Aprano
On Thu, Sep 21, 2017 at 03:46:29PM -0700, Evuraan wrote: > How can I work around this issue where subprocess.getstatusoutput gives > up, on Python 3.5.2: getstatusoutput is a "legacy" function. It still exists for code that has already been using it, but it is not recommended for new code. htt

Re: [Tutor] subprocess.getstatusoutput : UnicodeDecodeError

2017-09-21 Thread Evuraan
> > But: do you really want to "tail" what's probably not really a plaintext > file? Just guessing, but the .db as well as the error msgs are a hint. although the filename ends with a ".db", it is just a text file. not tailing a SQLite or a binary file, just happened to name it so. I work around

Re: [Tutor] subprocess.getstatusoutput : UnicodeDecodeError

2017-09-21 Thread Mats Wichmann
On 09/21/2017 04:46 PM, Evuraan wrote: > Greetings! > > My search-fu failed me, so thought of finally asking this question here. > > > How can I work around this issue where subprocess.getstatusoutput gives > up, on Python 3.5.2: You picked a fun one! First off, subprocess.getstatusoutput is

[Tutor] subprocess.getstatusoutput : UnicodeDecodeError

2017-09-21 Thread Evuraan
Greetings! My search-fu failed me, so thought of finally asking this question here. How can I work around this issue where subprocess.getstatusoutput gives up, on Python 3.5.2: >>> subprocess.getstatusoutput("tail -3 /tmp/pmaster.db",) Traceback (most recent call last): File "", line 1, in

Re: [Tutor] running or calling a module from the desktop

2017-09-21 Thread Alan Gauld via Tutor
On 20/09/17 22:06, orpha.pen...@outlook.com wrote: > I would like to import, run or set path to desktop. OK, On Windows go to Windows Exploder and type in the address %HOMEPATH%\Desktop Go there and you should be able to see/figure out the full path to your personal desktop folder. Then add t

[Tutor] running or calling a module from the desktop

2017-09-21 Thread orpha.pen...@outlook.com
Mmkay. I know that you know how to do this and I would appreciate it if you would tell me. Please. I would like to import, run or set path to desktop. So that I can use things there were I usually work on new items, I know how the rest of you are different from that. (I'm going to stop jok