Hacker News new | past | comments | ask | show | jobs | submit login

> You should be squeamish about running the code without reading it first, given that you're pair-programming with a bot.

It's funny, the first version of this project[0] let you do exactly that, e.g.,

  def main(path: str):
      #<<filenames = a list of filenames under path>>
  
      for fn in filenames:
          #<<size = size of fn in bytes>>
  
          print(fn, size)
  
  #<<use argparse and call main>>
and then run that program like any other Python script (using import magic):

  $ python -m examples.file_sizes /etc
  …
  /etc/wgetrc 4942
  /etc/nsswitch.conf 542
  /etc/adduser.conf 3028
  /etc/ethertypes 1816
But yeah, it never felt exactly practical. :)

[0] https://github.com/bsilverthorn/maccarone/tree/v0.1.3




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: