Is it possible to change a (just a snippet of all the code):
Class Setup(object):
def __init__(self, localm = 'http://127.0.0.1:1414', remotem = 'https://10.0.0.160:1414',
license = "blah\n"
"blah blah\n"
"blah blah blah\n"
):
logging.basicConfig(level=logging.ERROR)
self.lm = localm
self.rm = remotem
self.lic = license
default mutable value after it is imported or after initialization of a class using ipython? For example:
cpaste
Class Setup(object):
def __init__(self, localm = 'http://127.0.0.1:1414', remotem = 'https://10.0.0.160:1414',
license = "blah\n"
"blah blah\n"
"blah blah blah\n"
):
logging.basicConfig(level=logging.ERROR)
self.lm = localm
self.rm = remotem
self.lic = license
whos
Setup type <class '__main__.Setup'>
logging module <module 'logging' from '/<...>.7/logging/__init__.pyc'>
pasted_block str __init__stuff
Setup.__init__.__defaults__("remotem = 'https://10.0.0.162:1414'")
TypeError Traceback (most recent call last)
<ipython-input-11-e07587c9ad62> in <module>()
----> 1 Setup.__init__.__defaults__("remotem = 'https://10.0.0.160:1414'")
TypeError: 'tuple' object is not callable
or after the class initialization? What I want to achieve in the above example is to change the ip address without having to modify my code that is in Eclipse.