~/talk

Synchronizing Objects to YAML using Black Magic

Talkat PyOhio 2015 · 2015-08-01..08-02· [python, documentation]
slides:none on file

A small Python library called YORM maps object attributes to yaml files and performs automatic bidirectional sync with the filesystem; it serializes to a JSON-compatible YAML subset, coerces types on fetch/store, and sorts keys and expands lists for consistent diffs in version control. Implementation uses magic methods, runtime monkey‑patching and converters, runs on Python 3.3+, installs via pip, and is proven in three use cases: a submodule loader, Dropbox state sync, and game-state persistence that all work as described.

AI-written summary · about

  1. 0:00Synchronizing Objects to YAML using Black Magic
  2. 3:36Configuration vs. Data
  3. 4:02Storage Requirements
  4. 4:30Alternatives Explored
  5. 5:38Code Requirements
  6. 6:34Class Decorator or Function
  7. 7:07Optimized Formatting
  8. 8:07Conversation on Load
  9. 9:01Type Inference
  10. 9:51Metaclass
  11. 10:59Monkey Patching: Method
  12. 11:38Monkey Patching: Class
  13. 12:24Data Model: Setting Attributes
  14. 15:10Subclass Lookup
  15. 16:34Update File from Object
  16. 16:50Update Object from File
  17. 17:21Builtin Types
  18. 17:31Container Types
  19. 17:47Nested Types
  20. 18:14Custom Types
  21. 19:08Loading Configuration
  22. 20:41Synchronizing State
  23. 21:28Persisting Data
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.