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

Logging logs wrong file and line due to "lazy" function #7954

Closed
8 of 18 tasks
RobQuistNL opened this issue Jan 14, 2022 · 2 comments · Fixed by #8422
Closed
8 of 18 tasks

Logging logs wrong file and line due to "lazy" function #7954

RobQuistNL opened this issue Jan 14, 2022 · 2 comments · Fixed by #8422
Labels
area/chain Area: Chain dif/easy An existing lotus user should be able to pick this up effort/hours Effort: Hours kind/bug Kind: Bug P2 P2: Should be resolved

Comments

@RobQuistNL
Copy link
Contributor

RobQuistNL commented Jan 14, 2022

Checklist

  • This is not a security-related bug/issue. If it is, please follow please follow the security policy.
  • This is not a question or a support request. If you have any lotus related questions, please ask in the lotus forum.
  • This is not a new feature request. If it is, please file a feature request instead.
  • This is not an enhancement request. If it is, please file a improvement suggestion instead.
  • I have searched on the issue tracker and the lotus forum, and there is no existing related issue or discussion.
  • I am running the Latest release, or the most recent RC(release canadiate) for the upcoming release or the dev branch(master), or have an issue updating to any of these.
  • I did not make any code changes to lotus.

Lotus component

  • lotus daemon - chain sync
  • lotus miner - mining and block production
  • lotus miner/worker - sealing
  • lotus miner - proving(WindowPoSt)
  • lotus miner/market - storage deal
  • lotus miner/market - retrieval deal
  • lotus miner/market - data transfer
  • lotus client
  • lotus JSON-RPC API
  • lotus message management (mpool)
  • Other

Lotus Version

1.14.0-rc1

Describe the Bug

This bit of code: https://github.com/filecoin-project/lotus/blob/v1.14.0-rc1/chain/vm/runtime.go#L637-L648 causes any logs to be written as if they were coming from that line.

Example:

2022-01-14T03:41:14.567+0100    INFO    actors  vm/runtime.go:633       RepayDebtsOrAbort was called and succeeded
2022-01-14T03:41:14.567+0100    INFO    actors  vm/runtime.go:633       RepayDebtsOrAbort was called and succeeded
2022-01-14T03:41:14.567+0100    INFO    actors  vm/runtime.go:633       RepayDebtsOrAbort was called and succeeded
2022-01-14T03:41:14.568+0100    INFO    actors  vm/runtime.go:633       RepayDebtsOrAbort was called and succeeded

The line vm/runtime.go:633 reflects this line, not the original line it was called - this entire function should either be removed or it should be reflecting the originating calls' line & file.

@Reiers Reiers added area/chain Area: Chain and removed need/triage labels Jan 16, 2022
@jennijuju jennijuju added LotusY-2 dif/easy An existing lotus user should be able to pick this up effort/hours Effort: Hours labels Jan 17, 2022
@jennijuju jennijuju added the P2 P2: Should be resolved label Jan 17, 2022
@jennijuju jennijuju added this to LotusY Jan 17, 2022
@jennijuju jennijuju moved this to Ready To Work in LotusY Jan 17, 2022
@arajasek
Copy link
Contributor

arajasek commented Feb 8, 2022

I've been annoyed by this myself, it makes it hard to debug stuff in actors. Unfortunately, I'm not sure how possible this is -- this is the logger that is provided to actors code, and I don't know of a way for it to log the LoC in actors that triggers it.

Maybe someone else knows?

@jennijuju jennijuju removed the LotusY-2 label Feb 8, 2022
@jennijuju jennijuju removed the status in LotusY Feb 8, 2022
@jennijuju jennijuju removed this from LotusY Feb 8, 2022
@arajasek
Copy link
Contributor

arajasek commented Feb 8, 2022

@Stebalien offers this, thanks steb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/chain Area: Chain dif/easy An existing lotus user should be able to pick this up effort/hours Effort: Hours kind/bug Kind: Bug P2 P2: Should be resolved
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants