tarantool / tarantool/doc

Provide error details through payload fields

Open
#4,126 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

3.1 errors reference
Dominant language
CSS
Stars
15
Forks
49
Avg merge
1d 13h
Merged PRs (30d)
3

Description

Related dev. issue(s): https://github.com/tarantool/tarantool/issues/9108, https://github.com/tarantool/tarantool/issues/6166

Product: Tarantool
Since: 3.1
Root document: https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_error/
SME: @ nshy

Details

Now Tarantool error details are available as payload fields (which
in turn can be accessed as error object fields). For example:

tarantool> e = box.error.new(box.error.SPACE_EXISTS, 'some space')
tarantool> e.message
---
- Space 'some space' already exists
...
tarantool> e.space
---
- some space
...

One can introspect the details using error:unpack():

tarantool> e:unpack()

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open the root box_error documentation and compare its current coverage with the payload-field and error:unpack() examples in this issue. Document access to error details and introspection, then verify that the examples accurately describe the Tarantool 3.1 behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
lua
Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.