title: Go Error Handling Techniques
body: <p>I'm just getting started with Go. My code is starting to have a lot of this:</p>
  
  <pre><code>   if err != nil {
        //handle err
     }
  </code></pre>
  
  <p>or this</p>
  
  <pre><code>  if err := rows.Scan(&amp;some_column); err != nil {
        //handle err
    }
  </code></pre>
  
  <p>Are there some good idioms/strategies/best-practices for checking and handling errors in Go?</p>
  
  <p>EDIT to clarify: I'm not bellyaching or suggesting that the Go team come up with something better. I'm asking if I'm doing it right or have I missed some technique that the community came up with. Thanks all.</p>