mulesoft / api-designer

A web editor for creating and sharing RAML API specifications
Other
1.07k stars 268 forks source link

When extending external api, libraries try to resolve locally. #401

Closed greg-hornby-roam closed 7 years ago

greg-hornby-roam commented 8 years ago

When I try to extend an api from an external location, such as a public portal, using the public root file you can copy the link for, it'll work as long as that external api doesn't use libraries through the uses: property, but if it does use it, it seems to try to resolve those files locally instead of from the external location, and therefore errors.

Example:

local/api.raml

#%RAML 1.0 Extension
extends: https://external_location/api.raml

external_location/api.raml

#%RAML 1.0

uses:
    SomeLib: ./path/to/lib.raml

The local/api.raml when extending that external api tries to resolve the SomeLib path locally.

This is from the anypoint platform api designer

sichvoge commented 8 years ago

That is a very good point. Let me raise that to the parser team. Very good use case.

KonstantinSviridov commented 8 years ago

Hi, @Gregroam

Thanks for a good catch. In fact it's a parser bug: https://github.com/raml-org/raml-js-parser-2/issues/348

greg-hornby-roam commented 8 years ago

Saw that it's been fixed, awesome! When can I expect to see this fix go to the anypoint api manager?

sichvoge commented 8 years ago

As soon as the Mulesoft team does QA testing and include it into their next release. Not sure when that will be.

nmarinel01 commented 7 years ago

Verified in API Designer, develop branch