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

bug: Fix install from source will lose version information #1024

Merged
merged 7 commits into from Oct 14, 2022

Conversation

VoVAllen
Copy link
Member

Signed-off-by: Jinjing.Zhou allenzhou@tensorchord.ai

Signed-off-by: Jinjing.Zhou <allenzhou@tensorchord.ai>
Signed-off-by: Jinjing.Zhou <allenzhou@tensorchord.ai>
Signed-off-by: Jinjing.Zhou <allenzhou@tensorchord.ai>
@@ -26,7 +26,15 @@
def build_envd_if_not_found():
if not os.path.exists("bin/envd"):
logging.info("envd not found. Build from scratch")
errno = subprocess.call(["make", "build-release"])
try:
with open(".GIT_TAG_INFO") as f:
Copy link
Member

Choose a reason for hiding this comment

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

Where do we write the file? Is it maintained by us?

Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Contributor

Choose a reason for hiding this comment

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

However, I didn't get the whole logic. Can you explain the design and execution order? Thanks! @VoVAllen

Copy link
Member Author

Choose a reason for hiding this comment

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

On macos arm, it built from source without git info. But the whole logic related to version depends on git tag. Missing git tag results in the bug. Thus here we manually save git tag info here

Copy link
Contributor

@dragonly dragonly Oct 14, 2022

Choose a reason for hiding this comment

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

nit: It's better to add comments here to explain the necessity of the code block. If one day macOS pre-built binary is released, this can be removed by consulting the comment here.

setup.py Outdated Show resolved Hide resolved
Makefile Show resolved Hide resolved
setup.py Outdated Show resolved Hide resolved
Signed-off-by: Jinjing.Zhou <allenzhou@tensorchord.ai>
Signed-off-by: Jinjing.Zhou <allenzhou@tensorchord.ai>
Signed-off-by: Jinjing.Zhou <allenzhou@tensorchord.ai>
Signed-off-by: Jinjing.Zhou <allenzhou@tensorchord.ai>
@VoVAllen
Copy link
Member Author

Tested on my macos, now envd binary from source has a proper version

Copy link
Contributor

@dragonly dragonly left a comment

Choose a reason for hiding this comment

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

LGTM. Goot Job!

@muniu-bot
Copy link

muniu-bot bot commented Oct 14, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dragonly, kemingy, VoVAllen

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@VoVAllen VoVAllen merged commit bcd8029 into tensorchord:main Oct 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
No open projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

4 participants