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

enum encode error: #22

Open
unisgn opened this issue Jun 12, 2016 · 0 comments
Open

enum encode error: #22

unisgn opened this issue Jun 12, 2016 · 0 comments

Comments

@unisgn
Copy link

unisgn commented Jun 12, 2016

    def encode_enum(self, val, state):
        """Encode a Python Enum value into JSON."""
        eas = self.options.encode_enum_as
        if eas == 'qname':
            self.encode_string( str(obj), state )
        elif eas == 'value':
            self._do_encode( obj.value, state )
        else:  # eas == 'name'
            self.encode_string( obj.name, state )

the param name is in trouble

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

1 participant