superfaceai / spec

The Comlink Specification. Comlink is a new interface description and integration language build self-integrating applications.
https://superface.ai/docs/comlink/specification
MIT License
11 stars 1 forks source link

Profile error can have zero or one occurrence #52

Closed freaz closed 12 months ago

freaz commented 1 year ago

I found out, that the specification allows to have multiple error definitions. From details, I found in internal documents, I never saw even example of multiple errors. So, I am fixing it as a bug in the specification rather not implemented specification.

github-actions[bot] commented 1 year ago

Deploy preview for specification ready!

✅ Preview https://specification-q31k66iu6-superface.vercel.app

Built with commit 926cc64de54fd1cb4dcf60deab70f9cbd08c666c. This pull request is being automatically deployed with vercel-action

freaz commented 1 year ago

Thanks for pointing me to that doc. I was looking in documents talking about profiles only. :/

If multiple errors should be possible, then spec needs to allow error naming.

Error : error ErrorName ModelDefinition

ErrorName : Identifier?
TheEdward162 commented 1 year ago

@zdne Hmm, this does bring up a memory about talking about this at some point I think. I'm just guessing here but didn't we end up saying we'd solve this with type unions instead? It's semantically the same but we already have type unions implemented 🤷‍♀️