Skip to content

Unsupported non-integer value as ColorMap keys #187

@cath222ou

Description

@cath222ou

When we create a color-map with a non-integer value, we get an exception message.

Color-map example:
"ndvi": {
-1.0: 0x1947B0FF,
-0.7: 0x3961B7FF,
-0.5: 0x5A7BBFFF,
-0.4: 0x7B95C6FF,
-0.3: 0x9CB0CEFF,
-0.2: 0xBDCAD5FF,
-0.1: 0xDEE4DDFF,
0: 0xFFFFE5FF,
0.1: 0xDAE4CAFF,
0.2: 0xB6C9AFFF,
0.3: 0x91AF94FF,
0.4: 0x6D9479FF,
0.5: 0x487A5EFF,
0.7: 0x245F43FF,
1.0: 0x004529FF
}

Exception message:

Exception in thread "main" pureconfig.error.ConfigReaderException: Cannot convert configuration to a geotrellis.server.ogc.conf.Conf. Failures are:
at 'layers.2014-ndvi.styles.0.colors.0':
- (file:/opt/datacube/applications/application.conf:732) Expected type STRING. Found OBJECT instead.
at 'layers.2014-ndvi.styles.0.colors.1':
- (file:/opt/datacube/applications/application.conf:740) Expected type STRING. Found OBJECT instead.
at 'layers.2014-ndvi.styles.0.colors.2':
- (file:/opt/datacube/applications/application.conf:746) Expected type STRING. Found OBJECT instead.
at 'layers.2015-ndvi.styles.0.colors.0':
- (file:/opt/datacube/applications/application.conf:732) Expected type STRING. Found OBJECT instead.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions