title: Converting Python List to Bytes Failing
body: <pre><code>    def get_new_bytes(self):
          x = random.randint(1, 10)
          iv = list()
          for y in range(1, 17):
               iv.append(x)
  
          ret = bytes(iv)
          print(type(ret))
          return ret
  </code></pre>
  
  <p>My issue is that the type still shows as a string! I need a byte array! I've tried multiple things including .encode and still not working. I'm using python 2.7.</p>
  
  <p>Thank you!</p>