doctype cache is never used
- Dominant language
- Python
- Stars
- 66
- Forks
- 23
- PR merge metrics
- No merged PRs in 30d
Description
https://github.com/frappe/frappe/blob/ba311a3ec83807f8a07f55e4beac6a09a7108b77/frappe/desk/form/load.py#L73-L74
comparing DateTime with string will always be false.
Also, this whole caching implementation is weird. If request is made and all the cost is paid then what's the point of not sending data back? Few KBs of network i/o saved at max.
NOTE: don't just fix it. Since this never really worked, the implementation is also flaky. Sometimes dependent doc meta is not cached which results in broken forms.
IMO lets just remove this entirely and redo cache implementation.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start in frappe/desk/form/load.py around lines 73-74 and trace the doctype cache path, including dependent document metadata. Reproduce the broken-form behavior and verify when cached metadata is absent. Done means the flaky implementation is removed and a replacement cache design is defined and validated.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend, performance
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100