The US government is not compelling speech, it's compelling PyPI to accurately reveal to the US government the contents of past speech that PyPI has access to. Compelling disclosure of certain kinds of data, when it's known, is a normal part of legal actions in the US and probably elsewhere.
You seem to be describing what these subpoenas have requested. This thread is about canaries, and whether the government could compel a company to keep one updated against their will.