BentoML: FileNotFoundError: [Errno 2] No such file or directory: '/Users/HenryDashwood/bentoml/node_modules/.bin/serverless': '/Users/HenryDashwood/bentoml/node_modules/.bin/serverless'

When I run !bentoml --verbose deployment create facial-features-detector --bento {bento_tag} --platform aws-lambda --region us-east-1 in this notebook I get the following error:

[2019-10-19 18:30:56,302] DEBUG - Using BentoML with local Yatai server
[2019-10-19 18:30:56,432] DEBUG - Upgrading tables to the latest revision
[2019-10-19 18:30:56,680] DEBUG - Created temporary directory: /private/var/folders/yl/c5z1v7897q3g9ywlj63pm0840000gn/T/bentoml-temp-rcsbrk64
Traceback (most recent call last):
  File "/Users/HenryDashwood/miniconda3/envs/py37/bin/bentoml", line 10, in <module>
    sys.exit(cli())
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/site-packages/click/core.py", line 764, in __call__
    return self.main(*args, **kwargs)
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/site-packages/click/core.py", line 717, in main
    rv = self.invoke(ctx)
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/site-packages/click/core.py", line 1137, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/site-packages/click/core.py", line 1137, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/site-packages/click/core.py", line 956, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/site-packages/click/core.py", line 555, in invoke
    return callback(*args, **kwargs)
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/site-packages/bentoml/cli/deployment.py", line 348, in create
    spec=spec,
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/site-packages/bentoml/yatai/yatai_service_impl.py", line 121, in ApplyDeployment
    response = operator.apply(request.deployment, self, previous_deployment)
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/site-packages/bentoml/deployment/serverless/aws_lambda.py", line 188, in apply
    template,
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/site-packages/bentoml/deployment/serverless/serverless_utils.py", line 133, in init_serverless_project_dir
    ["create", "--template", template_type, "--name", deployment_name], project_dir
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/site-packages/bentoml/deployment/serverless/serverless_utils.py", line 87, in call_serverless_command
    with subprocess.Popen(command, cwd=cwd_path, stdout=PIPE, stderr=PIPE) as proc:
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/subprocess.py", line 775, in __init__
    restore_signals, start_new_session)
  File "/Users/HenryDashwood/miniconda3/envs/py37/lib/python3.7/subprocess.py", line 1522, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: '/Users/HenryDashwood/bentoml/node_modules/.bin/serverless': '/Users/HenryDashwood/bentoml/node_modules/.bin/serverless'

I have node installed but is there another step, possibly involving npm, that I should be performing?

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 16 (16 by maintainers)

Most upvoted comments

@HenryDashwood @yubozhao closing this issue now as it seem to be an issue with AWS serverless and PyTorch - feel free to reopen or open a new issue if you continue running into this.

Note that we are also moving away from serverless framework to AWS sam and native APIs, which should help us avoid the issues with NPM.