Add bulk update mechanism for List/Tree data sources
- Dominant language
- Python
- Stars
- 5.4k
- Forks
- 827
- Avg merge
- 15h 39m
- Merged PRs (30d)
- 40
Description
### Discussed in https://github.com/beeware/toga/discussions/2746
Toga's ListSource and TreeSource APIs have list-like APIs - but they currently only provide `insert()` and `append()`, inserting single rows. There are no "bulk update" APIs, like `extend()`.
Although you can superficially implement `extend(N rows)` with a series of N `append()` calls, there is a potential internal optimisation in only emitting a single notification, rather than N individual notifications.
Toga's list-like Source APIs should allow for "bulk update" in the form of `extend()`, with an optimized notification that can respond to a bulk update.
Contributor guide
Research direction
Start by locating the ListSource and TreeSource APIs and reading how insert() and append() notify observers. Add an extend() operation for bulk rows, with completion shown by a single bulk-update notification rather than one notification per row.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api, desktop
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100