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

Use env for revision id if not passed in as param; use git describe as backup #16227

Merged
merged 9 commits into from
Jan 19, 2024

Conversation

samnoyes
Copy link
Contributor

No description provided.

@dosubot dosubot bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Jan 18, 2024
Copy link

vercel bot commented Jan 18, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
langchain ⬜️ Ignored (Inspect) Visit Preview Jan 19, 2024 0:10am

@dosubot dosubot bot added the 🤖:improvement Medium size change to existing code to handle new use-cases label Jan 18, 2024
@samnoyes samnoyes changed the title Use env for revision id if not passed in as param; use git describeas backup Use env for revision id if not passed in as param; use git describe as backup Jan 18, 2024
@@ -1330,6 +1335,24 @@ def run_on_dataset(
return container.finish(batch_results, verbose=verbose)


def _get_default_revision_id() -> Optional[str]:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Could you add a description of what LANGCHAIN_REVISION_ID is? And which git repo is this for?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Do we need to memoize the result if git describe --tags --dirty fails? e.g., no git installed or no .git found?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Ya - he's implementing in the SDK also! we memoize there

@dosubot dosubot bot added size:XS This PR changes 0-9 lines, ignoring generated files. and removed size:S This PR changes 10-29 lines, ignoring generated files. labels Jan 18, 2024
Copy link
Collaborator

@eyurtsev eyurtsev left a comment

Choose a reason for hiding this comment

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

This works

@dosubot dosubot bot added the lgtm PR looks good. Use to confirm that a PR is ready for merging. label Jan 18, 2024
@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. and removed size:XS This PR changes 0-9 lines, ignoring generated files. labels Jan 18, 2024
@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. and removed size:S This PR changes 10-29 lines, ignoring generated files. labels Jan 18, 2024
@samnoyes samnoyes merged commit f175bf7 into master Jan 19, 2024
76 checks passed
@samnoyes samnoyes deleted the sam/use-env-for-revision-id branch January 19, 2024 00:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🤖:improvement Medium size change to existing code to handle new use-cases lgtm PR looks good. Use to confirm that a PR is ready for merging. size:M This PR changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants