I don't think there is a deadline while boarding is still ongoing.
I remember once arriving ar the gate 2 mins before door closed. I don't remember why but I was not on the upgrade list. GA added me and upgrade cleared. First was half full so was economy.
but what has been said above is true. It can be a very busy and hectic time for the GAs and their first answer will most likely be "no, go away".
Solutions:
Request the upgrade earlier.
or
Wait and talk to the GA when she is not busy. It may not happen until 2 mins before closing and you will board last though