Skip to content

Instantly share code, notes, and snippets.

@monokrome
Created May 3, 2012 23:46
Show Gist options
  • Save monokrome/2590488 to your computer and use it in GitHub Desktop.
Save monokrome/2590488 to your computer and use it in GitHub Desktop.
Example of when you can't use a relative import
# Just in case you think that this might be related.

Example

Run this and you will get an error related to being unable to relative import:

python example.py
from .sibling import SomeObject
s = SomeObject()
class SomeObject(object):
def __init__(self):
print('Some object worked. wtf?!')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment