CodeGenieApp / CodeGenieApp/serverless-express
NestJS example does not work with root paths
- 主要言語
- JavaScript
- スター
- 5.3k
- フォーク
- 676
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
The [starter example for Nest JS](https://github.com/vendia/serverless-express/tree/mainline/examples/basic-starter-nestjs) does not work with root paths.
## Steps to reproduce
```shell
git clone https://github.com/vendia/serverless-express.git
cd serverless-express/examples/basic-starter-nestjs
npm ci
```
Remove the path from the [demo controller's handler](https://github.com/vendia/serverless-express/blob/mainline/examples/basic-starter-nestjs/src/app.controller.ts#L8) so it [defaults to the root path for the controller](https://docs.nestjs.com/controllers#routing).
```shell
npm run sls:offline
```
Make a request to `http://localhost:3000/dev`.
The server responds with a `404` error of `Cannot GET null`.
---
I have confirmed that this does not occur when using Nest JS without Serverless:
```shell
nest new nest-test
cd nest-test
npm run start
```
Make a request to `http://localhost:3000`.
The server responds with the expected response.
コントリビューションガイド
調査の方向性
examples/basic-starter-nestjs/src/app.controller.ts から始め、npm ci、npm run sls:offline、および http://localhost:3000/dev へのリクエストで問題を再現します。root controller のパスがどのように処理されるかを追跡し、リクエストが 404 Cannot GET null レスポンスを返さなくなったことを確認します。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- aws, javascript, node.js
- 領域
- api, backend
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- 明確に書かれている
- 初心者へのやさしさ
- 45/100