title: How to get duration of active storage video attachment?
body: <p>In my Rails application, I have a model with a video as an attachment. I would like to display how long the video is (duration), but can't seem to figure out what method or what attributes to call on the blob to get that information.</p>
  
  <p>Ideally, it would be something like this:</p>
  
  <pre><code>Lecture.video.blob.duration
  </code></pre>
  
  <p>But that doesn't exist. I can't seem to find it in the documentation; perhaps I'm just looking in the wrong places.</p>
  
  <p>I appreciate any help, thank you.</p>