The sentence :
Je suis aussi allé acheter une nouvelle bibliothèque que j’ai passé plus de deux heures à monter.
The hint given was ‘la bibliothèque’.
I took this to mean that passé should agree with bibliothèque and wrote passée.
I was using the rule for the ‘case of subordinate clauses with que’. Why am I wrong here?