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

fix bug relate to "invalid file path" #14143

Merged

Conversation

triump2020
Copy link
Contributor

@triump2020 triump2020 commented Jan 11, 2024

What type of PR is this?

  • API-change
  • [x ] BUG
  • Improvement
  • Documentation
  • Feature
  • Test and CI
  • Code Refactoring

Which issue(s) this PR fixes:

issue #14114
issue #13788

What this PR does / why we need it:

  1. ref to fix bug relate to invalid file path #14142

@matrix-meow matrix-meow added the size/S Denotes a PR that changes [10,99] lines label Jan 11, 2024
@mergify mergify bot requested a review from sukki37 January 11, 2024 13:33
@matrix-meow
Copy link
Contributor

@triump2020 Thanks for your contributions!

Title: fix bug relate to "invalid file path"

Body: This pull request fixes two issues (#14114 and #13788) related to an "invalid file path" bug. The changes made in this pull request address the bug by adding additional checks to ensure that the correct file path is used.

Changes:

  • In the blocks_iter.go file, the following changes were made:
    • Added the bytes package import.
    • In the GetBockDeltaLoc function, added an additional check to compare the BlockID with the provided bid to ensure they are equal before returning the DeltaLoc and CommitTs.
    • In the BlockPersisted function, added an additional check to compare the ObjectShortName with the blockID to ensure they are equal before returning true.
    • In the GetObject function, added an additional check to compare the ObjectShortName with the provided name to ensure they are equal before returning the ObjectInfo.

Security Issues:
No security issues were identified in this pull request.

Suggestions for Optimization:

  • The changes made in this pull request seem to be necessary to fix the bug. However, there are no specific optimizations that can be suggested at this time. The changes appear to be focused on adding necessary checks to ensure the correct file path is used, which is important for preventing errors and maintaining data integrity.

@mergify mergify bot merged commit 477dd15 into matrixorigin:1.1-dev Jan 11, 2024
18 checks passed
triump2020 added a commit to triump2020/matrixone that referenced this pull request Jan 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size/S Denotes a PR that changes [10,99] lines
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants