Skip to content

Instantly share code, notes, and snippets.

@dword4
Created September 4, 2020 21:34
Show Gist options
  • Save dword4/aa31928b175a7f5b114364f759bf2fbf to your computer and use it in GitHub Desktop.
Save dword4/aa31928b175a7f5b114364f759bf2fbf to your computer and use it in GitHub Desktop.
class Alpha(Cosmos):
def __init__(self):
self.name = "Alpha.class"

python version:

Python 3.6.8 (default, Nov 21 2019, 19:31:34)

output

Traceback (most recent call last):
  File "./test.py", line 3, in <module>
    from alpha import *
  File "/home/dhynes/testing/alpha.py", line 1, in <module>
    class Alpha(Cosmos):
NameError: name 'Cosmos' is not defined
#!/usr/bin/env python3
from alpha import *
class Cosmos(object):
def __init__(self):
self.name = "Cosmos.class"
c = Cosmos()
print(c)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment