Open ozo360 opened 2 years ago
@ozo360
Thank you for a great ticket! 👍
I'll investigate in a few days.
Hello! I have a similar error. Let me share my experience. Thank you!
When I convert a style.json into yaml files, some layers have ">-" and line change (attached image) in the list. I could not see any differences among layers ' expression in the source file.
start charites in docker, then run
charites convert test.json test/style.yml
{"version":8,"sprite":"../sprites/sprite_S","glyphs":"../fonts/{fontstack}/{range}.pbf","sources":{"esri":{"type":"vector","url":"../../"}},
"layers": [{
"id": "background",
"type": "background",
"paint": {
"background-color": {
"stops": [[7, "#FFFCF7"], [10, "#FAF9F6"]]
}
}
}, {
"id": "Landuse(slash)LND_Natural_M(slash)Farmland(slash)fill",
"type": "fill",
"source": "esri",
"source-layer": "LND_Natural_M",
"filter": ["==", "_symbol", 2],
"minzoom": 8,
"layout": {},
"paint": {
"fill-opacity": {
"stops": [[8, 0], [9, 1]]
},
"fill-color": "#F2F2DC"
}
}, {
"id": "Landuse(slash)LND_Natural_M(slash)Farmland(slash)pattern",
"type": "fill",
"source": "esri",
"source-layer": "LND_Natural_M",
"filter": ["==", "_symbol", 2],
"minzoom": 12,
"layout": {},
"paint": {
"fill-pattern": "LND_Farmland"
}
}, {
"id": "Hydrography(slash)HYD_Waterways_L(slash)Stream(slash)halo",
"type": "line",
"source": "esri",
"source-layer": "HYD_Waterways_L",
"filter": ["==", "_symbol", 1],
"minzoom": 11,
"layout": {
"line-cap": "round",
"line-join": "round"
},
"paint": {
"line-color": "rgba(250,249,246,0.5)",
"line-blur": 1,
"line-width": {
"stops": [[11.53, 3], [18.17, 6]]
}
}
}],
"_ssl": true
}
version: 8
sprite: ../sprites/sprite_S
glyphs: ../fonts/{fontstack}/{range}.pbf
sources:
esri:
type: vector
url: ../../
layers:
- !!inc/file layers/background.yml
- !!inc/file layers/Landuse(slash)LND_Natural_M(slash)Farmland(slash)fill.yml
- >-
!!inc/file
layers/Landuse(slash)LND_Natural_M(slash)Farmland(slash)pattern.yml
- >-
!!inc/file
layers/Hydrography(slash)HYD_Waterways_L(slash)Stream(slash)halo.yml
_ssl: true
layer list does not have two lines.
Windows 10. Docker Desktop (for windows) Charites run on unvt/nanban
This page may help us to understand what happens during the conversion. Thank you!
Describe the bug If you run convert in a Windows environment, you will get unwanted single quotes in the layers section. This will cause the build to fail.
To Reproduce Steps to reproduce the behavior:
curl https://gsi-cyberjapan.github.io/gsivectortile-mapbox-gl-js/std.json | charites convert - style.yml
charites build style.yml style.json
Expected behavior Make the output the same as when you convert in a Linux environment. Remove the single quotes and it works fine.
Screenshots
convert style.yml
Charites Version:
Desktop (please complete the following information):