title: RequestPermissions isn't giving a prompt Android Studio API 32
body: <p>I'm working on Android Studio chipmunk using java language.
  I'm trying to request permission for Nearby devices. So far I have already tried the AppCompat and regular requestpermissions method but none seems to work.
  The app is not prompting the user to allow the device to access any of the required permissions including Bluetooth, location, and nearby devices.</p>
  <p>I am using Pixel 3 device to run my code with Android 12.</p>
  <pre><code>public void getpermissions(){
       
              if ((ActivityCompat.checkSelfPermission(this, Manifest.permission.BLUETOOTH) !=
                      PackageManager.PERMISSION_GRANTED) || (ActivityCompat.checkSelfPermission(this,
                      Manifest.permission.BLUETOOTH_ADMIN) != PackageManager.PERMISSION_GRANTED) || (
                      ActivityCompat.checkSelfPermission(this, Manifest.permission.BLUETOOTH_SCAN) !=
                              PackageManager.PERMISSION_GRANTED) || (ActivityCompat.checkSelfPermission(this,
                      Manifest.permission.BLUETOOTH_ADVERTISE) != PackageManager.PERMISSION_GRANTED) ||
                      (ActivityCompat.checkSelfPermission(this, Manifest.permission.BLUETOOTH_CONNECT) !=
                              PackageManager.PERMISSION_GRANTED) || (ActivityCompat.checkSelfPermission(this,
                      Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED) ||
                      (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_COARSE_LOCATION) !=
                              PackageManager.PERMISSION_GRANTED)||
                      (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_BACKGROUND_LOCATION) !=
                              PackageManager.PERMISSION_GRANTED)||
                      (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACTIVITY_RECOGNITION) !=
                              PackageManager.PERMISSION_GRANTED)||
                      (ActivityCompat.checkSelfPermission(this, Manifest.permission_group.NEARBY_DEVICES) !=
                              PackageManager.PERMISSION_GRANTED))  {
                  requestPermissions(new String[]{Manifest.permission.BLUETOOTH, Manifest.permission.BLUETOOTH_ADMIN
                          , Manifest.permission.BLUETOOTH_ADVERTISE, Manifest.permission.BLUETOOTH_CONNECT, Manifest.permission.BLUETOOTH_CONNECT,Manifest.permission.ACTIVITY_RECOGNITION,
                          Manifest.permission.BLUETOOTH_SCAN, Manifest.permission.ACCESS_FINE_LOCATION, Manifest.permission.ACCESS_BACKGROUND_LOCATION,
                          Manifest.permission.ACCESS_COARSE_LOCATION,Manifest.permission_group.NEARBY_DEVICES}, 1);
                  //requestPermissions(new String[]{Manifest.permission_group.NEARBY_DEVICES}, 1);
                  return;
              }
        
      }
  </code></pre>
  <p>This is my manifest file:</p>
  <pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;
  &lt;manifest xmlns:android=&quot;http://schemas.android.com/apk/res/android&quot;
      xmlns:tools=&quot;http://schemas.android.com/tools&quot;
      package=&quot;com.example.navigation&quot; &gt;
  
      &lt;uses-permission android:name=&quot;android.permission.BLUETOOTH&quot; /&gt;
      &lt;uses-permission android:name=&quot;android.permission.BLUETOOTH_ADMIN&quot; /&gt;
      &lt;uses-permission android:name=&quot;android.permission.BLUETOOTH_SCAN&quot; /&gt;
      &lt;uses-permission android:name=&quot;android.permission.BLUETOOTH_ADVERTISE&quot; /&gt;
      &lt;uses-permission android:name=&quot;android.permission.BLUETOOTH_CONNECT&quot; /&gt;
      &lt;uses-permission android:name=&quot;android.permission.ACCESS_BACKGROUND_LOCATION&quot; /&gt;
      &lt;uses-permission android:name=&quot;android.permission.ACTIVITY_RECOGNITION&quot; /&gt;
      &lt;uses-permission android:name=&quot;android.permission.ACCESS_FINE_LOCATION&quot; /&gt;
      &lt;uses-permission android:name=&quot;android.permission.ACCESS_COARSE_LOCATION&quot; /&gt;
      &lt;uses-permission android:name=&quot;android.permission-group.NEARBY_DEVICES&quot; /&gt;
      &quot;android.permission-group.NEARBY_DEVICES&quot;
  
      &lt;uses-feature
          android:name=&quot;android.hardware.bluetooth&quot;
          android:required=&quot;false&quot; /&gt;
      &lt;uses-feature
          android:name=&quot;android.hardware.bluetooth_le&quot;
          android:required=&quot;false&quot; /&gt;
  
      &lt;application
          android:allowBackup=&quot;true&quot;
          android:dataExtractionRules=&quot;@xml/data_extraction_rules&quot;
          android:fullBackupContent=&quot;@xml/backup_rules&quot;
          android:icon=&quot;@mipmap/ic_launcher&quot;
          android:label=&quot;@string/app_name&quot;
          android:roundIcon=&quot;@mipmap/ic_launcher_round&quot;
          android:supportsRtl=&quot;true&quot;
          android:theme=&quot;@style/Theme.Navigation&quot;
          tools:targetApi=&quot;32&quot; &gt;
          &lt;activity
              android:name=&quot;.DeviceScanActivity&quot;
              android:exported=&quot;false&quot; /&gt;
          &lt;activity
              android:name=&quot;.MainActivity&quot;
              android:exported=&quot;true&quot;
              android:launchMode=&quot;singleTop&quot; &gt;
              &gt;
              &lt;intent-filter&gt;
                  &lt;action android:name=&quot;android.intent.action.MAIN&quot; /&gt;
  
                  &lt;category android:name=&quot;android.intent.category.LAUNCHER&quot; /&gt;
              &lt;/intent-filter&gt;
          &lt;/activity&gt;
      &lt;/application&gt;
  
  &lt;/manifest&gt;
  </code></pre>