Double-check the value in your Authorization header for invalid characters:
This also happened to me when I tried to add an Authorization header to my fetch calls, due to an invalid character in the Authorization key.
In my case it was caused by a newline (\n) character in the header string, i.e. Bearer:\nsomelong-token. Changing the new line to a space solved the problem.
Note, that most special characters are typically not valid for authorization tokens.