Skip to content

[Bug]: Unique Values symbology fails with "field is required" for layers without numeric fields #768

Closed

Description

@deniial00

Before you start

  • I searched the existing issues and did not find a duplicate.
  • This is a bug report, not a usage question.

What happened?

When switching a WFS layer from Single Symbol to Unique Values or Graduated Colors, RustGIS displays field is required.

The layer contains attributes (e.g. g_id: 61259, g_name: Liezen), visible when identifying a feature.

In crates/ui-egui/src/panes.rs, the Symbology UI invokes layer.symbology without a field parameter. The engine (crates/engine/src/cmd/layer.rs) then tries to select a numeric field automatically and returns field is required if none is available. This affects Unique Values too, although it supports text fields.

Steps to reproduce

  1. Add a WFS layer whose attributes are stored as strings.
  2. Select the layer and open Style → Symbology.
  3. Switch from Single Symbol to Unique Values.
  4. Observe the field is required error.

Expected behavior

  • Unique Values should select an available field, including string fields.
  • Graduated Colors should select a numeric field if one exists, or give a useful explanation if not.
  • The UI should allow field selection without requiring a successful initial renderer switch.

How are you running RustGIS?

Desktop app (built from source)

Version

Current main

Operating system, browser and graphics

Windows 11 26H2 (graphics not specified)

Sample data

Observed with a WFS layer containing:

g_id: 61259
g_name: Liezen

Screenshots or logs

field is required

Relevant code: crates/ui-egui/src/panes.rs and crates/engine/src/cmd/layer.rs.

Activity

  1. added
    unconfirmed possible issue
    on Oct 23, 2026
  2. self-assigned this
    on Oct 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

unconfirmed possible issue

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions