postgresql automatically truncates too-long index names (for the limit see "SELECT max_identifier_length - 1 FROM pg_control_init()") but alembic does not truncate index names in this manner.
That means that if an index name is too long then alembic will always generate a spurious migration where it tries to create the index with the long name and drop the index with the short name.
The bug is not that bad because for cases where the sqlalchemy naming convention generates index names that are too long you can just override it in the model by specifying a non-autogenerated index name ("name=...").
But in the long run it would be nice if alembic would also auto-truncate index names like postgres does.
It is apparently not possible to disable autotruncation in postgresql 9.6.1, so it might be a bit difficult to find these cases.