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

Install Lambda requirements using env.install() #257

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

BelSasha
Copy link
Contributor

No description provided.

@BelSasha BelSasha changed the title Install Lambda requirements using env.install() [WIP] Install Lambda requirements using env.install() Dec 21, 2023
@BelSasha BelSasha changed the title [WIP] Install Lambda requirements using env.install() Install Lambda requirements using env.install() Dec 21, 2023
Copy link
Contributor

@dongreenberg dongreenberg left a comment

Choose a reason for hiding this comment

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

Great work, glad to see you got this working!

runhouse/resources/envs/env.py Show resolved Hide resolved
Comment on lines +314 to +324
if (
"./" in env.reqs
and env.reqs[0] != "./"
and env.reqs[0].split("/")[0].split()[0] != env.reqs[0].split()[0]
):
reqs = env.reqs
path_to_txt = str(
Path(reqs[0].split(":")[1] + "requirements.txt").absolute()
)
paths_to_code.append(path_to_txt)
env.reqs = [path_to_txt] + env.reqs[1:]
Copy link
Contributor

Choose a reason for hiding this comment

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

Not totally clear on what's going on here, but looks pretty specific to one structure/use case. I think it would be a lot more robust if we could just send the packages to the lambda into the home directory, as we do with regular clusters. We can't rsync into a lambda, but can either 1) send the necessary files over the zip interface or 2) zip them ourselves and send them via a call into the lambda as we do with the env. I don't think that should be in this PR but feel it's quite critical.

runhouse/resources/functions/aws_lambda.py Show resolved Hide resolved
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.

None yet

2 participants