aws / aws/aws-toolkit-vscode

SAM: Specifying build directory causes ENOENT error

Open
#7,608 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
TypeScript
Stars
2k
Forks
807
Avg merge
10h 12m
Merged PRs (30d)
7

Description

## Problem

## Steps to reproduce the issue

1. Create a Python SAM application with a Lambda
2. Create a launch.json for the Lambda
3. Add --build-profile xbuild (or other directory) to config
4. Debug
5. Get error: [error] SamLaunchRequestError: Failed to run launch configuration
-> EntryNotFound (FileSystemError): Error: ENOENT: no such file or directory, unlink 'e:\VSCode Portable\data\tmp\aws-toolkit-vscode\vsctk86fcd334\output\template.yaml' [FileNotFound]

## Expected behavior

Debugging should start using the template.yaml found in the build profile folder

## System details (run `AWS: About` and/or `Amazon Q: About`)

- OS: Windows 10
- Visual Studio Code version: 1.95.0
- AWS Toolkit version: 3.67.0
- Amazon Q version: N/A

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the Windows 10 case with a Python SAM application, a Lambda launch.json, and --build-profile xbuild. Trace the SAM launch flow around the reported ENOENT unlink of output/template.yaml; done means debugging starts using the template.yaml in the build-profile folder without the FileNotFound error.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, typescript, vscode
Domain
cloud, devtools
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.