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

Is filter = "info,ckb-script=debug" enabled in offckb by default? #207

Open
tea2x opened this issue Jan 19, 2025 · 4 comments
Open

Is filter = "info,ckb-script=debug" enabled in offckb by default? #207

tea2x opened this issue Jan 19, 2025 · 4 comments

Comments

@tea2x
Copy link

tea2x commented Jan 19, 2025

Hi everyone!

I'm running offckb node and using ckb-cli to interact with it.
When i debug script, i notice my debug code isn't in the offckb log (on terminal).
To be sure i'd like to have a confirmation whether or not this use is valid, Or is filter = "info,ckb-script=debug" enabled by default in offckb?

Or is there a way to set it up like when starting a node with ./ckb?

Thank you everyone!

@RetricSu
Copy link
Collaborator

RetricSu commented Jan 20, 2025

If you just want to see the script debug log, i would recommand to use offckb debug https://github.com/ckb-devrel/offckb?tab=readme-ov-file#debug-a-transaction this will be easier. You need to use ckb-cli to connect to the offckb proxy rpc localhost:9000 to send your transaction, and then offckb debug --tx-hash <txHash> to debug the script

the offckb node start the ckb binary without special Rust log setting https://github.com/ckb-devrel/offckb/blob/master/src/cmd/node.ts#L23 For how to set up the debug log for script in ckb binary, @doitian can you give some advice here?

@tea2x
Copy link
Author

tea2x commented Jan 20, 2025

If you just want to see the script debug log, i would recommand to use offckb debug

unfortunately because I want to see the log when my transaction is reverted. It never got accepted as a transaction sooffckb debug doesn't help in this case.
@RetricSu

@RetricSu
Copy link
Collaborator

If you just want to see the script debug log, i would recommand to use offckb debug

unfortunately because I want to see the log when my transaction is reverted. It never got accepted as a transaction sooffckb debug doesn't help in this case. @RetricSu

failed transaction should be recorded too in the offckb proxy rpc server, is there any problem you encounter?

@tea2x
Copy link
Author

tea2x commented Jan 20, 2025

failed transaction should be recorded too in the offckb proxy rpc server

oh really? sorry for jumping to conclusions.
Let me check!

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

No branches or pull requests

2 participants