how to find the cause of ActiveRecord ROLLBACK

后端 未结 4 1866
小鲜肉
小鲜肉 2020-12-07 22:40

In the logs I\'m seeing a ROLLBACK, but no exception is logged. Is there a way to find out what caused the ROLLBACK?

Here\'s the excerpt of the log:

4条回答
  •  猫巷女王i
    2020-12-07 22:53

    save record with BANG '!' so it will make a run time error and you get know where does it happens

提交回复
热议问题