digital-asset / lib-message-integration

Apache License 2.0
2 stars 1 forks source link

Swagger converter fails in windows due to back-slashes #6

Open lucianojoublanc-da opened 4 years ago

lucianojoublanc-da commented 4 years ago

This is likely because we are using FilePath to handle JSON paths, which should have the same syntax in Windows/Unix.

lucianojoublanc-da commented 4 years ago

Compiler output from reporter

PS C:\Users\Prajay\Documents\GitHub\DAML\src\lib-message-integration\tool-metagen> cabal run -- metagen swagger -s "C:\Users\Prajay\Documents\GitHub\DAML\src\stripe-openapi\openapi\spec2.json" -o "C:\Users\Prajay\Documents\GitHub\DAML\src\stripe-openapi" -p . -j foo
Up to date
[Info] Wrote 'C:\Users\Prajay\Documents\GitHub\DAML\src\stripe-openapi\daml\StripeAPI.daml'.

PS C:\Users\Prajay\Documents\GitHub\DAML\src\stripe-openapi> daml build                                                 
DAML SDK 1.1.1 has been released!
See https://github.com/digital-asset/daml/releases/tag/v1.1.1 for details.

Compiling stripe-openapi to a DAR.
File:     daml\StripeAPI.daml
Hidden:   no
Range:    20:42-20:43
Source:   parser
Severity: DsError
Message:  daml\StripeAPI.daml:20:43: error: parse error on input ‘\’
ERROR: Creation of DAR file failed.