NetLogo / NetLogo/NetLogo

choosers should (probably) accept any value when set from code

Open
#551 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Scala
Stars
1.2k
Forks
272
PR merge metrics
No merged PRs in 30d

Description

Esther (a long time ago):

hey - do we want choosers to accept values that are not part of the choices when set from code? before when I was reviewing stuff I only checked for things that changed values silently. this throws an error but I was thinking maybe that wasn't right

me:

hmm. yeah, I think they should accept any value when set from code. of course then we need to figure out what to display in that case

the argument is that sliders now accept any (numeric) value when set from the code, so choosers should too (without the numeric constraints, since choosers aren't constrained by type). the idea is that the min/max/step values determine what user interface is presented, but it ought to be possible to override that from code.

for example a chooser might present "1, 10, 100, 1000" as choices, but 10000 ought to work if you do it from code, e.g. in the command center.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Search the chooser implementation and the slider handling to compare how values set from code are validated. Reproduce the command-center example with a value outside the displayed choices, then determine how that value should appear in the chooser. Done means code-set values are accepted without the chooser's choice constraints and their display behavior is defined.

Written by the indexing model from the issue text.

Assessment

Tech stack
scala
Domain
frontend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.