The reason that the session may be stuck in a pending state could be that your login nodes aren’t able to see connection.yml generated on the compute nodes when starting a session.
Start with checking if your file system writes from your compute nodes are syncing quick enough to your login nodes.