title: Error :cannot use a string pattern on a bytes-like object
body: <p>Hy am using Python RegEx to show all internet wirless profiles connected to a computer.There is error <code>(TypeError: cannot use a string pattern on a bytes-like object)</code> in my Second last line pls anyone help to identifi my mistake.Thanks</p>
  
  <p><strong>My Program</strong></p>
  
  <pre><code>import subprocess,re
  command = "netsh wlan show profile"
  output = subprocess.check_output(command, shell=True)  
  network_names = re.search("(Profile\s*:\s)(.*)", output)  
  print(network_names.group(0))
  </code></pre>
  
  <p>.....................................................</p>
  
  <p><strong>ERROR</strong></p>
  
  <pre><code>line 8, in &lt;module&gt;
  
  
   return _compile(pattern, flags).search(string)
  
  
  TypeError: cannot use a string pattern on a bytes-like object
  </code></pre>