It has to do with commas and semicolons. But should be preceded by the former, while however should be preceded by the latter. Therefore, your #2 is mistyped or misrepresented; at the moment, but can be used there, but however cannot.
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.