Open yogeshshejwadkar opened 3 weeks ago
It's really hard to tell based on your description what is wrong. I don't understand where a 404 would come from.
All I can say is usually the "null" errors in GeoMoose are from an error in parsing the mapbook. I wish we had better error reporting there. My guess is something is misspelled or an ID doesn't match between the catalog and map-source sections.
Below is the code Mapbook
<?xml version="1.0"?>
Map File
MAP INCLUDE '../../map_globals.map' CONFIG "MS_ERRORFILE" "/var/www/html/broadway/public/maps/logs/ms_error.txt" DEBUG 1
WEB
METADATA
'ows_title' 'Pune District Data'
INCLUDE '../../common_metadata.map'
'wfs_getfeature_formatlist' 'gml,geojson'
END
END
LAYER
NAME pune_district
DUMP TRUE
METADATA
'ows_title' 'Pune'
'ows_include_items' 'all'
'gml_include_items' 'all'
END
TYPE POLYGON
DATA './pune.shp'
#FILTER ([PARC_CODE] == 1)
PROJECTION
'init=epsg:32643'
END
#OPACITY 50
#LABELITEM 'TALUKA_NAM'
#LABELCACHE ON
#LABELMAXSCALE 80000
#LABELMINSCALE 3000
CLASS
STYLE
SIZE 1
WIDTH 2
OUTLINECOLOR 55 87 153
#MAXSCALEDENOM 15000
COLOR 175 196 237
END
LABEL
TYPE TRUETYPE
FONT vera_sans
SIZE 8
#ANTIALIAS TRUE
COLOR 0 0 0
OUTLINECOLOR 254 254 200
#BUFFER 4
#MINFEATURESIZE auto
#PARTIALS FALSE
#POSITION cc
END
END
TEMPLATE 'dummy'
END
END ## end Map
and attached are the errors I am getting
hi @yogeshshejwadkar I think the correction you need to make is in the Catalog section at the bottom of the mapbook.xml.
the reference to the layer source needs to be updated from:
<layer src="pune_district" ...
to:
<layer src="pune_district/pune_district" ...
Hi @tchaddad
This I tried before, but as per your suggestion tried again and same error
From the error, It looks like the path to your mapfile in the map source is also possibly missing a folder.
<map-source name="pune_district" type="mapserver" up="true" down="true" title="Pune District">
<file>data/pune/pune.map</file>
<layer name="pune_district/pune_district" status="on" />
</map-source>
I have added one layer in mapbook and also added the shape file with map file to the data folder. In mapbook I mentioned the correct path of that map file, but still 404 error is showing.
When I open that path from my browser, it is showing the map file correctly.
Please let me know where I am doing mistake.
Also showing another error below Uncaught TypeError: Cannot read properties of null (reading 'favorite') at isFavorite (layer-favorite.js:38:31) at LayerFavorite.render (layer-favorite.js:45:24) at finishClassComponent (react-dom.development.js:18470:31) at updateClassComponent (react-dom.development.js:18423:24) at beginWork$1 (react-dom.development.js:20186:16) at HTMLUnknownElement.callCallback (react-dom.development.js:336:14) at Object.invokeGuardedCallbackDev (react-dom.development.js:385:16) at invokeGuardedCallback (react-dom.development.js:440:31) at beginWork$$1 (react-dom.development.js:25780:7) at performUnitOfWork (react-dom.development.js:24695:12)
The above error occurred in the component:
in LayerFavorite (created by Connect(LayerFavorite))
in Connect(LayerFavorite) (created by CatalogLayer)
in div (created by CatalogLayer)
in div (created by CatalogLayer)
in CatalogLayer (created by Connect(CatalogLayer))
in Connect(CatalogLayer) (created by Catalog)
in div (created by CatalogGroup)
in div (created by CatalogGroup)
in CatalogGroup (created by Catalog)
in div (created by CatalogGroup)
in div (created by CatalogGroup)
in CatalogGroup (created by Catalog)
in div (created by Catalog)
in Provider (created by Catalog)
in Catalog (created by Connect(Catalog))
in Connect(Catalog)
Consider adding an error boundary to your tree to customize error handling behavior. Visit https://fb.me/react-error-boundaries to learn more about error boundaries.