Hmm, I just tried again to double-check (although I did the very same thing before creating this post):
1. Created a review with an initial dummy patch set in a Python file
2. Attempted to submit a second patch set (that contains invalid code) from the command line using git-review triggered the hooks:
[2016-08-16 20:09:00,568] [SyncHook-1972] INFO com.google.gerrit.common.ChangeHookRunner : hook[ref-update] exitValue:1
[2016-08-16 20:09:00,568] [SyncHook-1972] INFO com.google.gerrit.common.ChangeHookRunner : hook[ref-update] output: *** pre-commit check failed for file `__init__.py' at commit: 41ab15e8c1e67b410b7d1247d4e4168da0eb6c93
[2016-08-16 20:09:00,568] [SyncHook-1972] INFO com.google.gerrit.common.ChangeHookRunner : hook[ref-update] output: *** __init__.py:4:2: E201 whitespace after '{'
[2016-08-16 20:09:00,568] [SyncHook-1972] INFO com.google.gerrit.common.ChangeHookRunner : hook[ref-update] output: *** __init__.py:4:17: E202 whitespace before '}'
[2016-08-16 20:09:00,568] [SyncHook-1972] INFO com.google.gerrit.common.ChangeHookRunner : hook[ref-update] output: *** __init__.py:4:16: invalid syntax
[2016-08-16 20:09:00,568] [SyncHook-1972] INFO com.google.gerrit.common.ChangeHookRunner : hook[ref-update] output: *** { invalid python }
[2016-08-16 20:09:00,568] [SyncHook-1972] INFO com.google.gerrit.common.ChangeHookRunner : hook[ref-update] output: ***
3. Submitted the exact same change using the inline edit of the WebUI completed successfully and created the second patch set, although the code is invalid and is rejected by the ref-update hook; nothing in the logs
I don't recall trying this scenario on a previous version of Gerrit so I can't tell if it ever worked or not.