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
used the search to make sure that a similar issue hasn't already been submit
Expected Behavior
When generating two differents apis, with differentiate docs, where the base paths are "api/v1" and "api/v2".TSOA should allow to generates two sames routes with two different base path. Example:
POST /api/v1/usersPOST /api/v2/usersThose two routes should work
Current Behavior
The generation of the routes does not work when the route are identical but not the base path.Error :
Generate routes error.GenerateMetadataError: Duplicate method signature @post(suppliers) found in controllers: SupplierController#bulkImport, SupplierController#bulkImportat MetadataGenerator.checkForMethodSignatureDuplicates (/Users/paulinegangloff/Documents/offspend/node_modules/@tsoa/cli/dist/metadataGeneration/metadataGenerator.js:41:23)at MetadataGenerator.Generate (/Users/paulinegangloff/Documents/offspend/node_modules/@tsoa/cli/dist/metadataGeneration/metadataGenerator.js:138:14)at generateRoutes (/Users/paulinegangloff/Documents/offspend/node_modules/@tsoa/cli/dist/module/generate-routes.js:14:177)at routeGenerator (/Users/paulinegangloff/Documents/offspend/node_modules/@tsoa/cli/dist/cli.js:261:52
Possible Solution
This line should take into account also the base path
@pauline-greenly tsoa can not recognize controller's base path by its folder name, thus the Generator can not process as you wish.
Once you execute the tsoa routes command, tsoa would take whole folder(including v1 and v2 folrder) to generate routes.
@WoH:
I think this is not a bug, since the issue author's usecase is slightly different to the usual way using tsoa.
We should provide some sort of decorator to mark controller's base path to do such things.
Sorting
I'm submitting a ...
I confirm that I
Expected Behavior
Current Behavior
Possible Solution
This line should take into account also the base path
Steps to Reproduce
Context (Environment)
Version of the library:
Version of NodeJS:
Detailed Description
Breaking change?
The text was updated successfully, but these errors were encountered: