steveoh / grunt-esri-slurp

download the esri js api
MIT License
19 stars 7 forks source link

Problem building with JSAPI 3.14 #38

Closed tsamaya closed 9 years ago

tsamaya commented 9 years ago

Trying on both repo tomwayson/esri-slurp-example and esri/dojo-bootstrap-map-js to build with JSAPI 3.14, I got this error:

error(311) Missing dependency. module: esri/dijit/_ObliqueRotationWidget; dependency: dojox/dgauges/CircularGauge
error(311) Missing dependency. module: esri/dijit/_ObliqueRotationWidget; dependency: dojox/dgauges/CircularScale
error(311) Missing dependency. module: esri/dijit/_ObliqueRotationWidget; dependency: dojox/dgauges/CircularRangeIndicator
error(311) Missing dependency. module: esri/dijit/_ObliqueRotationWidget; dependency: dojox/dgauges/CircularValueIndicator
error(311) Missing dependency. module: esri/dijit/_ObliqueRotationWidget; dependency: dojox/dgauges/LinearScaler

looking at dojox/dgauges folder, it is emtpy. then I am think the issue is more on bower dojox component than esrislurp. What do you think ? Arnaud

steveoh commented 9 years ago

Dojox does not have those modules. I would recommend 3.13 until the esri bower package is released. If you need 3.14 then modify those files to remove the dep, mock the dep, or remove those files from the esri api

tsamaya commented 9 years ago

thank for your quick answer ! I will check with @tomwayson what he think about that. I will first keep working without the build system.

tomwayson commented 9 years ago

I wonder if it has anything to do w/ the fact that dgauges is a git submodule of dojox:

https://github.com/dojo/dojox/tree/1.10.4

I don't see a bower.json in that repo, so I don't see how bower could know that it needs to install those submodules as deps. Maybe this should be an issue on dojo/dojox?

I suppose the example repo could list that package as a bower dep, but then you'd have to have a post install script that moves it to the right place under dojox. Alternatively, the example repo could use git submodules :disappointed:.

cc'ing @odoe so that this is on his radar for the bower release.

odoe commented 9 years ago

Yup, hit this issue head on with the bower stuff.

You can remap it like so in your build profile

  map: {
    '*': {
      'dojox/dgauges': 'dgauges'
    }
  },
tomwayson commented 9 years ago

Cool @odoe!

Just to make sure I understand, you're suggesting to explicitly load dgauges as a bower dep, and then use map (instead of a post-install script) to tell the Dojo loader where to find it, right?

Tom

odoe commented 9 years ago

Yeah, because it's a gitsubmodule in dojox and it's a hassle to try and pull in git submodules in your bower folders. From all my testing and I've run so many build scenarios at this point, my face is melting dgauges is the only git submodule in dojox that gets touched. You can ignore app, calendar and whatever else unless you actually use them for some reason.

tomwayson commented 9 years ago

I think we can close this now. I've got builds working w/ @odoe's dgauges map here:

https://github.com/tomwayson/esri-slurp-example/releases/tag/v0.1.4