Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

block-notify seems not working #9253

Open
SnAFKe opened this issue Mar 15, 2024 · 1 comment
Open

block-notify seems not working #9253

SnAFKe opened this issue Mar 15, 2024 · 1 comment

Comments

@SnAFKe
Copy link

SnAFKe commented Mar 15, 2024

I'm using command line to start monero with --block-notify '/bin/bash /home/user/block_notify.sh'

I want to switch to monero config file but with block-notify seems not working

block-notify='/bin/bash /home/user/notify.sh'

When i start monero in the logs show this.

ffff858c4010	WARNING	notify	src/common/notify.cpp:55	A notification spec contains a quote or backslash: note that these are handled verbatim, which may not be the intent
ffff858c4010	ERROR	notify	src/common/notify.cpp:57	File not found: '/bin/bash
ffff858c4010	ERROR	cn	src/cryptonote_core/cryptonote_core.cpp:651	Failed to parse block notify spec: File not found: '/bin/bash

Edit: Seems error is gone if i remove quote (not sure if will work). Now is not necessary to add quote or i miss something.

What can I do to run a script when block found via config file ?

Thanks

@moneromooo-monero
Copy link
Collaborator

This file is boost format.
https://www.boost.org/doc/libs/1_84_0/doc/html/program_options/overview.html#id-1.3.30.5.10
Unfortunately, the documentation doesn't specify how quoting is handled, but https://github.com/boostorg/program_options/blob/develop/src/config_file.cpp, lines 103-119, suggests that no quoting is done (unless there is a post process step somewhere).
Monero could perform some interpretation, but that opens the usual can of worms. So removing the quote should work.

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

No branches or pull requests

3 participants