.py question

Gene Heskett gheskett at shentel.net
Tue Apr 23 15:40:16 UTC 2019


On Tuesday 23 April 2019 10:53:27 Colin Watson wrote:

> On Tue, Apr 23, 2019 at 10:37:20AM -0400, Gene Heskett wrote:
> > I think the one we're calling, calls others from it. And the
> > instructions say to unpack the zip, but don't say where.
>
> When that happens it usually means that you can make a directory of
> your choice and do stuff there, as long as you're consistent in doing
> everything relative to that directory.
>
> > On Tuesday 23 April 2019 09:04:16 Colin Watson wrote:
> > > Try just running the program without any of that first, though. 
> > > If any modules are unavailable then it will tell you.
> >
> > the error when I type in an ssh session:
> > python3 vna.pyRETURN
> > "can't find vna.py"
> > So obviously its not in the python3 version of $PATH, and I'm lost.
> > Hence this thread
>
> The Python equivalent of $PATH (sys.path) shouldn't be relevant.  When
> you give a file name on the command line like that, it's resolved
> using the perfectly normal rules for opening a relative path in any
> program - that is, it's resolved relative to the current working
> directory.
>
> Does "cat vna.py" in the very same context work?

No clue Colin, and its been rebooted a couple times since. They've broken 
the security rules by having root as username and pw for an ssh login.  
But thats a clue by itself, so perhaps I should put it in /root? 
Shudder...

I'll try that this afternoon. I'm also caretaker for the missus, who's 
dying of copd and its about lunch time now. Thanks Colin
>
> (That said, I would normally expect the following output when the
> given file name is missing: "python3: can't open file 'vna.py': [Errno
> 2] No such file or directory".  But maybe you're paraphrasing rather
> than copying and pasting error messages, or maybe this device has a
> weird Python installation.)
>
> --
> Colin Watson                                      
> [cjwatson at ubuntu.com]


Cheers, Gene Heskett
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>





More information about the ubuntu-users mailing list