onaio / gisida

JavaScript library that converts MapSpec layers to beautiful, interactive maps using Mapbox GL
http://gisida.onalabs.org/
Apache License 2.0
11 stars 3 forks source link

Fix gisida-react staging build process #441

Closed kahummer closed 4 years ago

kahummer commented 4 years ago

When creating an optimized production build on staging we get this error: Screenshot from 2020-03-13 14-40-58

kahummer commented 4 years ago

@ciremusyoka @kelvin-muchiri Please update the issue once you get a fix to this I'm still researching on the same

ciremusyoka commented 4 years ago

@kahummer @kelvin-muchiri This bug is caused by the way we reference gatekeeper module.

  1. import { ... } from '@onaio/gatekeeper'; produces the error.
  2. import { ... } from '@onaio/gatekeeper/dist/components/login'; does not.

Can't figure out why option 1 which is the right way is causing the error.

ciremusyoka commented 4 years ago

@kahummer @kelvin-muchiri This bug is caused by the way we reference gatekeeper module.

  1. import { ... } from '@onaio/gatekeeper'; produces the error.
  2. import { ... } from '@onaio/gatekeeper/dist/components/login'; does not.

Can't figure out why option 1 which is the right way is causing the error.

@moshthepitt what is your thought on this?

moshthepitt commented 4 years ago

@ciremusyoka what is the specific thing that is being imported in this case? It may be such that this thing is not exported from the index file at '@onaio/gatekeeper' - in which case we can update gatekeeper to export it.

ciremusyoka commented 4 years ago

@moshthepitt useOAuthLogin and AuthorizationGrantType which i believe they are at the index file of '@onaio/gatekeeper'

kelvin-muchiri commented 4 years ago

@ciremusyoka @moshthepitt @kahummer Yea, I remember discussing this with @p-netm he was supposed to create an issue for it. But I remember I used @onaio/gatekeeper/dist/components/login

Or is the issue being raised by import { AuthorizationGrantType } from '@onaio/gatekeeper';?

ciremusyoka commented 4 years ago

@kelvin-muchiri yes this import { AuthorizationGrantType } from '@onaio/gatekeeper'; is what raised the issue.

cKellyDesign commented 4 years ago

Are we using the right version of gatekeeper?

cKellyDesign commented 4 years ago

@kahummer @ciremusyoka @kelvin-muchiri what's the status of this fix?