I don't really understand this PR as GitHub is an American company that is forbidden to do business with Iranians. It seems weird to me to use the website but not take a PR. That said I am sympathetic to the package maintainer and I hope to never live in a place so repressive. It's scary as it is.
The long and short of it is that he's more afraid of his government than the US government.
I don't think GitHub would be any help here, as I imagine the author is worried about personal retribution from the Iranian government, not the US govt. He is probably right to be concerned. I'm afraid there's probably not much we can do here.
FWIW, as a Palestinian, I think this law is idiotic. FOSS does not discriminate on geographical origins, particularly when any submitted code can be freely audited.