You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have installed the latest version of the Amplify CLI (see above), and confirmed that the issue still persists.
I have searched for duplicate or closed issues.
I have read the guide for submitting bug reports.
I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
How did you install the Amplify CLI?
npm
If applicable, what version of Node.js are you using?
No response
Amplify CLI Version
4.46.1
What operating system are you using?
Ubuntu
Amplify Categories
auth, api
Amplify Commands
push
Describe the bug
When I run amplify push a virtual environment is created using Python 3.8 and then an exception is thrown trying to access site-packages within a python3.9 folder.
rupe@JRUSSO-831:/c/Temp/Innovative/amplify/pushtest$ amplify push
✔ Successfully pulled backend environment dev from the cloud.
Current Environment: dev
| Category | Resource name | Operation | Provider plugin |
| -------- | ---------------- | --------- | ----------------- |
| Auth | pushteste8db442e | Create | awscloudformation |
| Function | TestFunction | Create | awscloudformation |
| Api | API | Create | awscloudformation |
? Are you sure you want to continue? Yes
Creating a virtualenv for this project...
Pipfile: /c/Temp/Innovative/amplify/pushtest/amplify/backend/function/TestFunction/Pipfile
Using /usr/bin/python3.8 (3.8.5) to create virtualenv...
⠸ Creating virtual environment...created virtual environment CPython3.8.5.final.0-64 in 6983ms
creator CPython3Posix(dest=/home/rupe/.local/share/virtualenvs/TestFunction-lTrPbPtN, clear=False, global=False)
seeder FromAppData(download=False, pip=bundle, setuptools=bundle, wheel=bundle, via=copy, app_data_dir=/home/rupe/.local/share/virtualenv)
added seed packages: pip==21.0.1, setuptools==50.3.2, wheel==0.36.2
activators BashActivator,CShellActivator,FishActivator,PowerShellActivator,PythonActivator,XonshActivator
✔ Successfully created virtual environment!
Virtualenv location: /home/rupe/.local/share/virtualenvs/TestFunction-lTrPbPtN
Pipfile.lock not found, creating...
Locking [dev-packages] dependencies...
Locking [packages] dependencies...
Building requirements...
Resolving dependencies...
✔ Success!
Updated Pipfile.lock (e02f68)!
Installing dependencies from Pipfile.lock (e02f68)...
🐍 ▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉ 1/1 — 00:00:04
To activate this project's virtualenv, run pipenv shell.
Alternatively, run a command inside the virtualenv with pipenv run.
2021-04-07T19:10:07.356Z - error: uncaughtException: Could not find a pipenv site-packages directory at /home/rupe/.local/share/virtualenvs/TestFunction-lTrPbPtN/lib/python3.9/site-packages date=Wed Apr 07 2021 15:10:07 GMT-0400 (Eastern Daylight Time), pid=3617, uid=1000, gid=1000, cwd=/c/Temp/Innovative/amplify/pushtest, execPath=/usr/bin/node, version=v10.19.0, argv=[/usr/bin/node, /usr/local/bin/amplify, push], rss=399671296, heapTotal=301740032, heapUsed=270938000, external=1356295, loadavg=[2.09033203125, 1.40673828125, 0.93408203125], uptime=65876, trace=[column=9, file=/usr/local/lib/node_modules/@aws-amplify/cli/node_modules/amplify-python-function-runtime-provider/src/util/pyUtils.ts, function=Object.getPipenvDir, line=24, method=getPipenvDir, native=false, column=7, file=internal/process/next_tick.js, function=process._tickCallback, line=68, method=_tickCallback, native=false], stack=[Error: Could not find a pipenv site-packages directory at /home/rupe/.local/share/virtualenvs/TestFunction-lTrPbPtN/lib/python3.9/site-packages, at Object.getPipenvDir (/usr/local/lib/node_modules/@aws-amplify/cli/node_modules/amplify-python-function-runtime-provider/src/util/pyUtils.ts:24:9), at process._tickCallback (internal/process/next_tick.js:68:7)]
Thanks @jhockett, I actually got around it by updating the Pipfile and recreating the virtual environment manually to explicitly use 3.9. For some reason just updating the Pipfile still tried to create a 3.8 virtual environment. Anyway, I have it working now. Thanks for the quick response
Before opening, please confirm:
I have installed the latest version of the Amplify CLI (see above), and confirmed that the issue still persists.
I have searched for duplicate or closed issues.
I have read the guide for submitting bug reports.
I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
How did you install the Amplify CLI?
npm
If applicable, what version of Node.js are you using?
No response
Amplify CLI Version
4.46.1
What operating system are you using?
Ubuntu
Amplify Categories
auth, api
Amplify Commands
push
Describe the bug
When I run
amplify push
a virtual environment is created using Python 3.8 and then an exception is thrown trying to access site-packages within a python3.9 folder.Expected behavior
A successful push
Reproduction steps
GraphQL schema(s)
# Put schemas below this line
Log output
The text was updated successfully, but these errors were encountered: