While it's always a dangerous *pattern* to create an index while a transaction is open & holds an exclusive lock, in practice it's not always a big deal (for example, indexing a table with very few rows can be fast). Accordingly, downgrade to a warning.