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

Issue/140 show version number #153

Merged
merged 2 commits into from Mar 30, 2020

Conversation

mesejo
Copy link
Contributor

@mesejo mesejo commented Mar 28, 2020

  • Show the version number

    The version number was being imported using the following statement:
    from eland._version import *
    This way only loads the non-private names (see this), importing the names implicitly solves the issue.

  • Add ELLIPSIS, to ignore trailing white-spaces in doctest.

Closes #140

@elasticmachine
Copy link

Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually?

@stevedodson
Copy link
Contributor

jenkins test this please

from eland._version import *
from eland._version import (
__title__,
__description__,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking over this change, I actually much prefer it when the imports are listed out like in the lines above instead of just using the asterisk - it makes it easier to find where things are defined (imho). @sethmlarson is it common practice to do asterisk imports in init.py? I guess it saves some typing, but I've always generally had the feel that asterisk imports in general were frowned upon.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah star imports are not optimal, makes it hard for tooling to figure out the true signature of objects being used without searching everywhere. I actually have a flake warning suppressed due to this but I'm saving the fix until we narrow our public API so there's no rework to do. :)

Copy link
Contributor

@sethmlarson sethmlarson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@sethmlarson sethmlarson merged commit 03582b9 into elastic:master Mar 30, 2020
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

Successfully merging this pull request may close these issues.

Call to eland.__version__ should show version number
5 participants