DEPRECATION WARNING: Using `return`, `break` or `throw` to exit a transaction block
Nobody has claimed this yet.
- Dominant language
- Ruby
- Stars
- 10k
- Forks
- 1.2k
- Avg merge
- 14h 38m
- Merged PRs (30d)
- 92
Description
Hi
We hit this problem when upgrade rails to 6.1.4, found the error! function throw it, please help. Thanks
DEPRECATION WARNING: Using return, break or throw to exit a transaction block is
deprecated without replacement. If the throw came from
Timeout.timeout(duration), pass an exception class as a second
argument so it doesn't use throw to abort its block. This results
in the transaction being committed, but in the next release of Rails
it will rollback.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the Rails 6.1.4 deprecation warning described in the report and identify the Grape entry point involved in the transaction block. Confirm the expected transaction outcome and add or update coverage for the reported use of return, break, or throw; the issue does not name a file or test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rails, ruby
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100