20 Matching Annotations
  1. Nov 2023
    1. BTW to improve the reliability of that test I believe you would need a sleep (smaller, e.g. of 0.1) between the Thread.new and assert M.works?, otherwise it's likely the M.works? runs first and then the other thread will see the constant is autoloading and wait, and anyway that thread does not check what is defined on M. For the test to fail it needs to be the Thread.new running first and defining the constant but not yet the method, before the main thread keeps running and call the method.
  2. Mar 2023
    1. ‘‘I think it lets us be more thoughtful and more deliberate about safety issues,’’ Altman says. ‘‘Part of our strategy is: Gradual change in the world is better than sudden change.’’

      What are the long term effects of fast breaking changes and gradual changes for evolved entities?

  3. Nov 2022
    1. def with_something prepare yield on_success end any return, break or throw would skip the on_success code. Skipping over the on_success code also seems quite reasonable when the block calls break and throw. It may not seem like the obvious behaviour for return, but perhaps it is a safe assumption to make in general to think of return as aborting the method yielding to the block. It might be desirable to discourage the use of return in this way for transactions to keep the code clearer, but that would also affect the use of break which seems like a reasonable way to abort a transaction from within the transaction block.
  4. Mar 2022
    1. The danger of working at "internet time" is that hasty decisions may be poor, and rapid changes may cause troubling turbulence for many users.

      In 1998, Ben Shneiderman wrote "The danger of working at "internet time" is that hasty decisions may be poor, and rapid changes may cause troubling turbulence for many users." He's essentially admonishing against the dangerous and anti-social idea of what Mark Zuckerberg would later encourage at Facebook when he said "move fast and break things."

    1. Recent research reported in the journal Cognition offers evidence that brief distractions from a focal task may improve concentration over the longer run: “We propose that deactivating and reactivating your goals allows you to stay focused,” the study’s authors said. “From a practical standpoint, our research suggests that, when faced with long tasks (such as studying before a final exam or doing your taxes), it is best to impose brief breaks on your-self. Brief mental breaks will actually help you stay focused on your task!”28

      Kleine Pausen machen wenn man ein großes, ein longterm Ziel hat. De- und reaktivieren der intendierten Ziele soll den Forschungsergebnissen zufolge helfen, sich auf ebenjene länger und schließlich erfolgreicher zu konzentrieren.

  5. Jan 2022
  6. Oct 2021
  7. Sep 2021
  8. May 2021
  9. Apr 2021
  10. Feb 2021
    1. Also, this code will fail if $$ is not the process group leader, such as when the script is run under strace. Since a call to setsid(2) is probably tricky from a shell script, one approach might be to ps and obtain the process group ID from that.
    2. you really need #!/bin/sh -m for correct behavior of nested subshells. fg, bg, and wait wont work correctly otherwise
  11. Jan 2021
    1. How to wrap long word (text without spaces) in html table’s cell? This is very, very easy! We must add only a CSS proprty to table cell “td” tag – “word-break: break-all;” then all column’s widths become as intended. 
  12. Nov 2020
  13. Oct 2020
  14. Sep 2020
    1. I’ve seen some version of this conversation happen more times than I can remember. And someone will always say ‘it’s because you’re too used to thinking in the old way, you just need to start thinking in hooks’.

      But after seeing a lot of really bad hooks code, I’m starting to think it’s not that simple — that there’s something deeper going on.