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

Prefix trinity version with eth if trinity not installed #1071

Conversation

pipermerriam
Copy link
Member

What was wrong?

When trinity is not installed we fall back to the py-evm version for the version number. We don't want to have any confusion when viewing this number

How was it fixed?

When this happens, prefix the version string with eth-

Cute Animal Picture

smiling-gorilla

Copy link
Contributor

@carver carver left a comment

Choose a reason for hiding this comment

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

👍 because any change is better than what's there currently :)

@@ -5,7 +5,9 @@
try:
__version__ = pkg_resources.get_distribution("trinity").version
except pkg_resources.DistributionNotFound:
__version__ = pkg_resources.get_distribution("py-evm").version
__version__ = "eth-{0}".format(
Copy link
Contributor

Choose a reason for hiding this comment

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

Since this is inside the trinity module, should we just let it crash?

If the concern is confusion from user-reported versions, I still think we might run into problems. If the display on their screen is eth-v1.2.3 and we ask them the version, it seems totally plausible that they just say "v1.2.3".

Copy link
Member Author

Choose a reason for hiding this comment

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

Merging as-is and punting on a better change which pulls the local git commit and/or reads the version string from setup_trinity.py

@pipermerriam pipermerriam merged commit b581cdc into master Jul 23, 2018
@pipermerriam pipermerriam deleted the piper/prefix-trinity-version-with-eth-if-trinity-not-installed branch July 23, 2018 19:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants