Skip to content

modify year from 2025 to 2026(v3.0.4-hotfix) - #23443

Merged
1 commit merged into
matrixorigin:v3.0.4-hotfixfrom
Ariznawlll:3.0.4_modify_year
Jan 5, 2026
Merged

1 commit merged into
matrixorigin:v3.0.4-hotfixfrom
Ariznawlll:3.0.4_modify_year

Conversation

@Ariznawlll

@Ariznawlll Ariznawlll commented Jan 5, 2026 •

Copy link
Copy Markdown
Collaborator

User description

What type of PR is this?

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

Which issue(s) this PR fixes:

modify year from 2025 to 2026

issue ##23442

What this PR does / why we need it:

modify year from 2025 to 2026


PR Type

Tests


Description

  • Update test result expectations from 2025 to 2026

  • Modify UTC timestamp function test outputs

  • Align test cases with current year expectations


Diagram Walkthrough

flowchart LR
  A["Test Result File"] -- "Update year values" --> B["2025 → 2026"]
  B -- "UTC timestamp tests" --> C["Updated Expectations"]
Loading

File Walkthrough

Relevant files
Tests
func_datetime_utc_timestamp.result
Update UTC timestamp test year expectations                           

test/distributed/cases/function/func_datetime_utc_timestamp.result

  • Updated year extraction results from 2025 to 2026 in UTC timestamp
    test cases
  • Modified 4 test result lines: 1 single year value and 3 repeated year
    values
  • Maintains test structure and logic while updating expected output
    values
+4/-4     

@Ariznawlll
Ariznawlll requested a review from a user January 5, 2026 07:15
@CLAassistant

CLAassistant commented Jan 5, 2026 •

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@qodo-code-review

Copy link
Copy Markdown

PR Compliance Guide 🔍

Below is a summary of compliance checks for this PR:

Security Compliance
🟢
No security concerns identified No security vulnerabilities detected by AI analysis. Human verification advised for critical code.
Ticket Compliance
🟡
🎫 #23442
🟢 Ensure the UTC timestamp / year-related test expectations align with the correct
current-year output so the workflow no longer fails on this mismatch.
⚪ Fix the BVT failure caused by an incorrect year value in results (as observed in the
referenced regression run).
Codebase Duplication Compliance
⚪
Codebase context is not defined

Follow the guide to enable codebase context checks.

Custom Compliance
🟢
Generic: Comprehensive Audit Trails

Objective: To create a detailed and reliable record of critical system actions for security analysis
and compliance.

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Meaningful Naming and Self-Documenting Code

Objective: Ensure all identifiers clearly express their purpose and intent, making code
self-documenting

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Robust Error Handling and Edge Case Management

Objective: Ensure comprehensive error handling that provides meaningful context and graceful
degradation

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Secure Error Handling

Objective: To prevent the leakage of sensitive system information through error messages while
providing sufficient detail for internal debugging.

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Secure Logging Practices

Objective: To ensure logs are useful for debugging and auditing without exposing sensitive
information like PII, PHI, or cardholder data.

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Security-First Input Validation and Data Handling

Objective: Ensure all data inputs are validated, sanitized, and handled securely to prevent
vulnerabilities

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Compliance status legend 🟢 - Fully Compliant
🟡 - Partial Compliant
🔴 - Not Compliant
⚪ - Requires Further Human Verification
🏷️ - Compliance label

@qodo-code-review

Copy link
Copy Markdown

PR Code Suggestions ✨

Explore these optional code suggestions:

CategorySuggestion                                                                                                                                    Impact
General
Make test deterministic using fixed timestamps

To make the test deterministic and avoid annual failures, replace
utc_timestamp() with a fixed timestamp in the corresponding test source file.

test/distributed/cases/function/func_datetime_utc_timestamp.result [35-48]

 select a,b,c,year(d) from t1;
 a    b    c    year(d)
-1    1    1    2026
+1    1    1    2024
 2    0    0    null
 DROP TABLE t1;
 CREATE TABLE t1 (a TIMESTAMP);
-INSERT INTO t1 select (utc_timestamp());
-INSERT INTO t1 select (utc_timestamp());
-INSERT INTO t1 select (utc_timestamp());
+INSERT INTO t1 select ('2024-05-20 10:00:00');
+INSERT INTO t1 select ('2024-05-20 10:00:01');
+INSERT INTO t1 select ('2024-05-20 10:00:02');
 SELECT year(a) FROM t1 WHERE a > '2008-01-01';
 year(a)
-2026
-2026
-2026
+2024
+2024
+2024
  • Apply / Chat
Suggestion importance[1-10]: 7

__

Why: The suggestion correctly identifies a brittle test that requires yearly manual updates and proposes a robust solution by using a fixed timestamp. This significantly improves test maintainability by addressing the root cause of the issue, rather than just patching the symptom as the PR does.

Medium
  • More

@mergify mergify Bot added the kind/bug Something isn't working label Jan 5, 2026
@ghost
ghost merged commit 61090b0 into matrixorigin:v3.0.4-hotfix Jan 5, 2026
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/bug Something isn't working Review effort 1/5

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants