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

Unused assignment in Nebula Code #3630

Closed
FloridSleeves opened this issue Jan 5, 2022 · 1 comment
Closed

Unused assignment in Nebula Code #3630

FloridSleeves opened this issue Jan 5, 2022 · 1 comment
Assignees
Labels
community Source: who proposed the issue type/bug Type: something is unexpected wontfix Solution: this will not be worked on recently
Milestone

Comments

@FloridSleeves
Copy link

FloridSleeves commented Jan 5, 2022

Please check the FAQ documentation before raising an issue

Describe the bug (required)
There are some unused assignment in Nebula code, which may indicate bugs. Some are unlogged exceptions, some are unchecked return value.

Your Environments (required)

  • OS: Linux 5.11.0-40-generic Ubuntu 20.04.2
  • Compiler: clang version 10.0.0-4ubuntu1
  • CPU: Intel(R) Core(TM) i5-9500 CPU @ 3.00GHz

How To Reproduce(required)

There are some unused assignment in Nebula code, which may indicate bugs:

File Line Variable Explanation
src/kvstore/NebulaStore.cpp 161 e Exception may need to be also logged by e.what()
src/storage/query/ScanEdgeProcessor.cpp 66 ret return value of handleEdgeProps() need check whether is nebula::cpp2::ErrorCode::SUCCEEDED
src/storage/query/ScanVertexProcessor.cpp 69 ret return value of handleVertexProps() need check whether is nebula::cpp2::ErrorCode::SUCCEEDED
src/codec/RowReaderV1.cpp 454 ex Exception may need to be also logged by ex.what()
src/kvstore/wal/FileBasedWal.cpp 100 ex Exception may need to be also logged by ex.what()
src/codec/RowReaderV1.cpp 454 ex Exception may need to be also logged by ex.what()

The unchecked return value may cause wrong assumption on completeness of previous task and result in data corruption. And the unlogged exception may impede diagnosis of program failure.

Could you please help to confirm whether they are bugs?

Expected behavior

The assigned value is used or checked.

Additional context

@FloridSleeves FloridSleeves added the type/bug Type: something is unexpected label Jan 5, 2022
@Sophie-Xie Sophie-Xie added this to the v3.0.0 milestone Jan 5, 2022
@critical27 critical27 modified the milestones: v3.0.0, v3.1.0 Jan 11, 2022
@FloridSleeves
Copy link
Author

Hi! Thanks for adding them to v3.1.0 milestone! Can I make a pull request to fix them?

@Sophie-Xie Sophie-Xie added the wontfix Solution: this will not be worked on recently label Mar 15, 2022
@Sophie-Xie Sophie-Xie added the community Source: who proposed the issue label Apr 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community Source: who proposed the issue type/bug Type: something is unexpected wontfix Solution: this will not be worked on recently
Projects
None yet
Development

No branches or pull requests

3 participants