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

version name creation in get_definitions for wows 0.9.10 #12

Open
m-freiberg opened this issue Nov 4, 2020 · 0 comments
Open

version name creation in get_definitions for wows 0.9.10 #12

m-freiberg opened this issue Nov 4, 2020 · 0 comments

Comments

@m-freiberg
Copy link

m-freiberg commented Nov 4, 2020

def _get_definitions(self, version):
try:
return get_definitions('_'.join(version[:4]))
except RuntimeError:
return get_definitions('_'.join(version[:3]))

this join statement here to support longer version lengths (such as 0.9.10 as opposed to 0.9.9) is splitting 0.9.10 into 0_9_1_0 instead of 0_9_10. Not sure if this is what you wanted but it created errors for me when using it as i don't think it was getting the correct definitions from it. In my cloned version I ended up changing it to what i pasted below which is running smoothly! There's probably a better way to do it than I what I did below but I just needed a quick fix.

    def _get_definitions(self, version):
        try:
            iter_version = '_'.join(version[:4])
            iter_version = iter_version[:5] + iter_version[-1]
            return get_definitions(iter_version)
        except RuntimeError:
            return get_definitions('_'.join(version[:3]))

Feel free to use if you'd like.

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