Doubts on a proof about graphical models This is the third question I am asking about these notes http://www.stat.cmu.edu/~larry/=sml/DAGs.pdf .This time it is about the proof of a small theorem (page 426), that I report:

Theorem: Let $G$ be a DAG and P a distribution that is faithful to $G.$ If $X_i$ and $X_j$ are adjacent in $G,$ than the conditional independence test $X_i \mathrel{\unicode{x2AEB}} X_j |A$ fails for $A \in V-\{i,j\}$. On the other hand, if $X_i$ and $X_j$ are not adjacent in $G,$ then either
$X_i \mathrel{\unicode{x2AEB}} X_j |\pi(X_j)$ or $X_i \mathrel{\unicode{x2AEB}} X_j |\pi(X_i)$, where $\pi(X_i)$,$\pi(X_j)$ are the parent sets of $X_i$ and $X_j$ in the DAG $G$.


Proof: For the first part, [...]. For the second part we consider two cases. (i) $X_j$ is a descendant of $X_i$ and (ii) $X_j$ is not a descendant of $X_i$. By definition of $d$-separation in the first case we can show that $X_i \mathrel{\unicode{x2AEB}} X_j |\pi(X_j)$ and in the second case that $X_i \mathrel{\unicode{x2AEB}} X_j |\pi(X_i)$.

But I had a few doubts. First of all in the first case (i) I understand that the path from $X_i$ to $X_j$ making $X_j$ a descendant of $X_i$ is blocked when we observe $\pi(X_j)$ but why can't we have other paths that are open?
For (ii), In the DAG below:

$X_j$ is not a descendant of $X_i$ but $X_i$ and $X_j$ are not d-separated given $\pi(X_i)$, because the only collider (in the only path between them) is observed. Isn't it a counterexample to the reasoning or am I applying $d$-separation in a wrong way ?
(note I am not saying that the theorem is wrong, just that I do not understand the proof ;) )

I will try to post a complete solution showing that if $X_i$ and $X_j$ are not adjacent, than $X_i$ and $X_j$ are independent given either $\pi(X_j)$ or $\pi(X_i)$. As Adrian Keister noticed, my counterexample for point (ii) is wrong since I had mistakenly taken a child for a father...
Case when $X_j$ is a descendant of $X_i$.
From the fact that $X_j$ is a descendant of $X_i$ we know that there is a directed path from $X_i$ to $X_j$. This is blocked conditioning on $\pi(X_j)$. Now take an other path $p$: we have to show that it is blocked as well. If the path $p$ reaches $X_j$ pointing outwards than, since we cannot have a directed cycle, we will have a collider along $p$. Take the first collider that one meets going from $X_j$ to $X_i$ and call it $v$. $v$ cannot be a father of $X_j$ (again we would have a directed cycle) and is therefore not conditioned when we condition on $\pi(X_j)$, therefore the path is blocked. If the path $p$ reaches $X_j$ pointing inwards, than we have a father of $X_j $ at the last previous-to-last vertex along the path, which is in a "chain" or "fork" configuration, then conditioning on it the path is blocked also in this configuration.
Case when $X_j$ is not a descendant of $X_i$.
We consider a generic path from $X_i$ to $X_j$ and want to check that it is blocked conditioning on $\pi(X_i)$. If the path starts outwards from $X_i$, since $X_j$ is not a descendant we must have a collider in the path. Take the first one. This one cannot be a father of $X_i$ (because otherwise we would have a directed cycle). Therefore the path is blocked. Instead, if the path starts with an arrow towards $X_i$, the second element of the path counting from $X_i$ is a father of $X_i$ in either a chain or fork configuration, which is therefore blocked after conditioning.
These solutions are much clearer with some drawing :). The hypothesis that $X_i$ and $X_j$ are not ajacent is used implicitly so that each path is at least of length 2. So I guess all doubts solved. Thanks again to Adrian Keister for pointing out my mistake.
