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

TypeError from genword() during key creation #2

Open
rkenthudson opened this issue Aug 3, 2023 · 3 comments
Open

TypeError from genword() during key creation #2

rkenthudson opened this issue Aug 3, 2023 · 3 comments

Comments

@rkenthudson
Copy link

Following the instructions in the readme and receiving the following
error:
TypeError: _genword() got multiple values for argument 'length'
after:
my_key = my_key_manager.create('MY_FIRST_KEY')

@jlrodriguezalvarado
Copy link

Same here

@kevinprescottwong-Dev
Copy link

kevinprescottwong-Dev commented Sep 4, 2023

I have a fix!

@jthop can you test it and merge?

@Lulzcritic
Copy link

Thanks for this fix, but I still had an error :

TypeError: secret must be unicode or bytes, not None

I fixed it by replacing :

@property
    def full_key(self):
        """If we have all the pieces, construct the full_key.  Only
        on the fly gives us less chance of compromise.
        """

        prefix = self._cfg['prefix']

        if self.prefix and self.uuid and self._secret:
            full_key = f'{prefix}_{self.uuid}.{self._secret}'
            return full_key
        return None

WIth :

@property
    def full_key(self):
        """If we have all the pieces, construct the full_key.  Only
        on the fly gives us less chance of compromise.
        """

        prefix = self._cfg['prefix']

        if prefix and self.uuid and self._secret:
            full_key = f'{prefix}_{self.uuid}.{self._secret}'
            return full_key
        return None

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

4 participants