[Tutor] Class errors
Patrick Thunstrom
pathunstrom at gmail.com
Thu Jan 22 17:18:52 CET 2015
If the code I'm seeing is correct, the problem is the class is Jobs,
and you instantiated a Job, which doesn't exit.
Replace one with the other in either case should fix it.
On Thu, Jan 22, 2015 at 11:11 AM, jarod_v6 at libero.it <jarod_v6 at libero.it> wrote:
> Dear All,
>
> I created a class that invoke from another file another class
> I get an error that I do not understand: gobal name Job is not defined
> However If I see the class imported I found the class Job.
> Any suggestion or example on class invoke another class
>
> #job,py
> class Jobs:
> .....
>
> #trial.py
>
> from core.job import *
> class Second:
> def __initi__:
> tp = open("/tmp/file.txt")
>
> def gus(self):
> tr = Job()
>
> thanks so much!1
>
> _______________________________________________
> Tutor maillist - Tutor at python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
More information about the Tutor
mailing list