How can we select all the rows in different matching groups based on a column condition

**Data:**

```
**A B   C   D** 

101 1   1   FALSE

101 1   2   FALSE

101 1   3   FALSE

101 2   1   FALSE

101 2   2   FALSE

101 2   3   FALSE

101 2   4   TRUE

102 1   1   FALSE

102 1   2   FALSE

102 1   3   FALSE

102 2   1   FALSE

102 2   2   FALSE

102 2   3   TRUE

```

**Expected Output:**

```
**A B   C   D**

101 2   1   FALSE

101 2   2   FALSE

101 2   3   FALSE

101 2   4   TRUE

102 2   1   FALSE

102 2   2   FALSE

102 2   3   TRUE

```

I need all the rows where B = (B when D = True)

```
df.loc[df.groupby(["A"])[df_rvtlt['D'] == True]]

```