moodymudskipper / debugverse

Brainstorming ideas for debugging workflow and tools, not a package (yet ?)
1 stars 0 forks source link

{wat} package for R puzzles #45

Open moodymudskipper opened 8 months ago

moodymudskipper commented 8 months ago

Debugging exercises

Would work well on top of {pkg}, especially for extensibility.

I think for each exercise we create a new project, like what {saperlipopette} does for git. Whenever possible we hide data in .Rdata files in the R folder, so users can't cheat (esp as it is not clear in debugging what is cheating or not). For things that can't be done through .RData like active bindings , messing with namespaces, attaching... We call wat::some_function() in .onload or in a local RProfile, {wat} functions have printing methods that say "no cheating!". Then if users want to cheat they can, using unclass(), body() or whatever, but at least they know they're cheating. there might sometimes be some things in the .onLoad() or the Rprofile that are not cheating.