I find this edict technically correct but for simple textual reason that the District of Columbia Constitutionally has no legal government separate from that of Congress and the President.
Thus D.C.’s Gun law are technically Congress’s gun law which is of course explicitly forbidden by the 2nd amendment of the Federal Constitution.
I’ve been interested in this topic since I had a near miss in DC in 2011.
You are quite right that Congress has the power (and the responsibility) to legislate for the District “in all cases whatsoever”. This phrase had a very specific meaning to the authors of Article I.
As such, the DC “government” is a sham. The only powers they exercise are powers derived from the authority of Congress (and the President). They absolutely cannot do anything that Congress could not do.
The denial of permits to non-residents by DC, NJ, MD, NY, and Illinois is clearly unconstitutional. Hopefully, this decision will be sustained on appeal.