Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Type change protection breaks use of "None" #14

Closed
henriklynggaard opened this issue May 21, 2012 · 1 comment
Closed

Type change protection breaks use of "None" #14

henriklynggaard opened this issue May 21, 2012 · 1 comment

Comments

@henriklynggaard
Copy link
Contributor

In a common pattern we use

class Domain(ConfigItem):
    def __init__(self, name, base_port, java_home, domain_user_override=None, **kwargs):
        super(Domain, self).__init__(name=name, base_port=base_port, java_home=java_home, domain_user_override=domain_user_override, **kwargs)


@property 
def user(self):
  if self.domain_user_override
    return self.domain_user_override
  return calculated_user

However when I attempt to use the override as such

with Domain(name='eui', base_port=9000, java_home='/opt/java/jdk1.6.0_17',file_encoding="UTF-8") as eui_domain:
            eui_domain.domain_user_override(devLocal="myname") 

I get the following error:

ConfigError: Found different types of property 'domain_user_override' for different envs: <type 'str'> previously found types: [<type 'NoneType'>]
@lhupfeldt
Copy link
Owner

Fixed in 10c5b46

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants