aws / aws/chalice

support for gathering local pip packages on deploy.

Open
#1,700 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
11.1k
Forks
1k
Avg merge
1d 22h
Merged PRs (30d)
2

Description

I have a local python package installed via pip on my machine. `chalice deploy` does not work after doing a `pip freeze > requirements.txt`. Reading the documentation, the chalicelibs/ and vendor/ folders are my only options. The problem comes from building multiple chalice projects. I want a way to share code between projects without having to manually drag and drop everything into chalicelib/ or vendor/ for each deploy.

`chalice local` works without issue after configuring my package locally via pip.

My req.txt that doesnt work.
```txt
pymongo
-e git+https://github.com/company/somesharedlib.git@d0fcd1e0cb0b43ac4cbf1d587cd7e62814245549#egg=somesharedlib
```

```python
from chalice import Chalice
from chalicelib.models import SomeModel
# I would like to do this instead
from somesharedlib.models import SomeModel

app = Chalice(app_name='temp-svc')

@app.route('/')
def index():
log = PresenceStatusLog('test')
return {'hello': 'world'}
```

It would be great to have a simple feature that allows for say pointing the chalicelib/ directory at some other directory on your local machine at the very least so people could share code between projects. Currently writing a bash script to copy the contents of that directory each time i deploy.

Contributor guide

Open the contributing guide

Research direction

Start by reviewing how `chalice deploy` handles `requirements.txt`, `chalicelib/`, and `vendor/`; compare this with the working `chalice local` behavior and the shown editable Git dependency. The issue names no source files or tests. Done means a repeatable deployment path for sharing local pip packages across multiple Chalice projects.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
build-system, cloud
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.