Skip to content

Instantly share code, notes, and snippets.

@ckerr
Last active March 20, 2022 22:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ckerr/00b253626f33400b3ec9864c2322067e to your computer and use it in GitHub Desktop.
Save ckerr/00b253626f33400b3ec9864c2322067e to your computer and use it in GitHub Desktop.
finding source of 'argument not found' error with fmt::format
If fmt is throwing an exception, the breakpoint to set is:
`fmt::v8::detail::throw_format_error`
Finding the current parameters:
```sh
rg --no-filename 'fmt::arg' libtransmission gtk daemon utils | sed "s/^.*fmt::arg(\(.*\)\,.*$/\1/" | cut -f2 -d'"' | sort | uniq
```
Getting the fmt-arg strings:
```sh
rg "^msgid" transmission.pot | rg "\{" | sort
```
Where `transmission.pot` is generated by https://gist.github.com/ckerr/7528b92401d4aa2b65ae83fd0c07f1c4
@ckerr
Copy link
Author

ckerr commented Mar 20, 2022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment