A mistake made against me (or, how do we teach counting and inference)?
(Page of 2)

I was the beneficiary as North, but I'm presenting this hand from West's viewpoint.  Scoring is Matchpoints.

West
1075
K985
J7542
3
South
J982
QJ3
AK109
62
W
N
E
S
1
P
1
P
1NT
P
2NT
P
3NT
P
P
P

Partner leads the T, declarer winning with the J.  Declarer crosses to the A, leads a spade to Q which partner wins with the K.  Partner leads the A.  What do you discard?

West
107
K985
J754
South
J98
QJ3
K109
W
N
E
S
1
P
1
P
1NT
P
2NT
P
3NT
P
P
P

At the table, West discarded an encouraging heart.

That can't be right, for two reasons.

1) Partner is very unlikely to have A; it would need to be almost all of partner's remaining points given North accepted an invitation, and you don't really want a heart lead if declarer has A.  Also, would partner really cash the A if they had another entry?

2) If declarer has 4 hearts to the AT, a heart discard gives him a trick.  You can discard a diamond, which surely can't cost you given dummy. The discouraging diamond communicates just as much information as an encouraging heart, since surely partner will realize declarer is up to something with the spades and won't play you for anything there.

Most of you can probably figure this out much faster and more reliably; you can't count on me to get this one right at the table more than 70% of the time.  However, we've had a few threads on mentoring lately.

This is a hard problem for an advancing intermediate player. They have to keep track of their partner's (or declarer's) potential high card points, they have to visualize the possibility of declarer having 4 hearts to the AT and the consequences of that, and they have to realize their little diamonds are useless given the lack of enough entries to set them up.

At what point in a player's development do we teach this hand or comment on this error as a mentor?

Is getting this right consistently already a stage most players will never get to?

How do we teach this lesson so that the player is not overwhelmed by what they need to keep track of to figure this out?