Is K=1 a valid random integer in ElGamal signature? In the ElGamal signature scheme, in addition to the public/private keypair, a random integer $K$ such that $\operatorname{gcd}(K,p-1)=1$ is chosen in the range $[1,p-1]$.

This clearly excludes $K=p-1$, because $\operatorname{gcd}(x,x)=1$ for any $x$, but not $K=1$.

However, if $K=1$, the first part of the signature is $S_1 \equiv g^1 \bmod p\equiv g \bmod p\equiv g$, and the attacker knows it. Even worse, the attacker can use $S_2$ to obtain the private key.

Why is $K=1$ a valid choice? No source that I know of mentions this. Is it something considered so trivial that is not worth mentioning, or did I miss some mistake in my reasoning?

I understand that the probability to choose $K=1$, for a large prime, is vanishingly small, but in my opinion one shouldn't leave these things to chance.
Why $K=1$ is not excluded? You can also ask why $K=2$ is not excluded. It always possible to calculate $g^2$ and by keeping $(g^2,2)$ in a lookup table, you can also recover the secret key if you see $S_1 = g^2$, in which case $K$ happen to be 2. So as $K =3$, $K= 4$ and so on so forth. As you can see, 1 is not that special. 

The reason why they are not excluded is because that $K$ is chosen at uniformly random from the range. For an adversary who has only limited computational capacity, it can only guess polynomial number of $K$ and does the computation, but if the signer picks his $K$ at uniformly random, the probability of the adversary guessing the right $K$ is negligible. So as long as the signer does his job properly, we don't need to worry about $K$ being a specific value.