anz-bank/sysl-go

After upgrading to arrai, return error <: Status is not supported.

Closed this issue · 1 comments

uynap commented

Please do not post any internal, closed source snippets on this public issue tracker!

Description

After using Arri, I just realised one of the feature is not supported. This one.https://github.com/anz-bank/sysl-go/blob/master/codegen/testdata/simple/simple.sysl#L38

It's supported in the downstream definition, but it's not supported if you use it in upstream sysl definition(bff.sysl).

For example, if you have something below in your bff.sysl, then the syslw will give you errors.

        /aaa:
            GET:
                return ok <: Aaa
		return error <: Status

        !type Status:
            statusField <: string

The error I got is as below:

ERRO[0000] codegen/model/bff.sysl has syntax errors

The sysl command is:

./syslw pb --mode json codegen/model/bff.sysl --output codegen/model/bff.sysl.json
uynap commented

my mistake. i put

!type Status:
            statusField <: string

in the middle with 2 endpoints definition.