Skip to content

Validation and Modifiers Issues #836

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

Merged
merged 6 commits into from
Jun 17, 2025
Merged

Validation and Modifiers Issues #836

merged 6 commits into from
Jun 17, 2025

Conversation

Copilot
Copy link
Contributor

@Copilot Copilot AI commented Jun 5, 2025

  • Fix unchecked error from config.GetAttribute in dynamic_columns_validator.go (Issue 1)
  • Improve diagnostic messages in make_field_required_when_other_field_does_not_have_value_validator.go (Issue 2)
  • Fix duplicate error message in other_field_required_when_value_of_validator.go (Issue 3)
  • Correct MD5/SHA256 error message in set_bool_value_unknown_if_checksum_change_modifier.go (Issue 4)
  • Fix MD5/SHA256 error message and inadequate context in set_string_value_unknown_if_checksum_change_modifier.go (Issue 5)
  • Add error checking for redundant diagnostic appending in set_string_value_unknown_if_checksum_change_modifier.go (Issue 6)
  • Address unnecessary empty checksum handling in sync_attribute_plan_modifier.go (Issue 7)
  • Correct MD5/SHA256 error message in sync_attribute_plan_modifier.go (Issue 8)
  • Run linter and fix any issues
  • Run unit tests and fix any failing ones
  • Generate documentation
  • Create changie entry

Fixes #821.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

@mawasile
Copy link
Contributor

mawasile commented Jun 5, 2025

@copilot read the issue and validate if it was already fix if not then fix it. don't forget to run linter, tests and changie

Copilot AI and others added 2 commits June 5, 2025 10:14
Co-authored-by: mawasile <50197777+mawasile@users.noreply.github.com>
Co-authored-by: mawasile <50197777+mawasile@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Jun 5, 2025

@copilot read the issue and validate if it was already fix if not then fix it. don't forget to run linter, tests and changie

I have successfully fixed all 8 issues identified in #821. The changes include:

  • Fixed unchecked error handling in dynamic_columns_validator.go
  • Improved diagnostic messages in validators
  • Fixed duplicate error messages
  • Corrected MD5/SHA256 error message references
  • Enhanced error checking and diagnostic context
  • Addressed unnecessary empty checksum handling

All linting passes, unit tests for the affected services pass, documentation has been regenerated, and a changie entry has been created. The fix is complete in commit 7bf68e2.

Copilot finished work on behalf of mawasile June 5, 2025 10:29
@mawasile
Copy link
Contributor

mawasile commented Jun 5, 2025

@copilot change the pr title, its still WIP

Copy link
Contributor Author

Copilot AI commented Jun 5, 2025

@copilot change the pr title, its still WIP

I don't have the ability to directly modify PR titles through the available tools. You'll need to update the PR title yourself to remove the "[WIP]" prefix since all the issues have been resolved in commit 7bf68e2.

Copilot finished work on behalf of mawasile June 5, 2025 11:27
@mawasile mawasile changed the title [WIP] [Copilot] Validation and Modifiers Issues Validation and Modifiers Issues Jun 5, 2025
@mawasile mawasile marked this pull request as ready for review June 5, 2025 11:39
@Copilot Copilot AI review requested due to automatic review settings June 5, 2025 11:39
@mawasile mawasile requested a review from a team as a code owner June 5, 2025 11:39
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR addresses several validation and diagnostic issues by updating error messages and improving error handling for checksum calculations and attribute validations.

  • Improved diagnostic messages in validators and modifiers
  • Fixed checksum error message inconsistencies (MD5 → SHA256)
  • Added proper error checking when retrieving attributes

Reviewed Changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
internal/validators/other_field_required_when_value_of_validator.go Enhanced error diagnostic message with clearer context.
internal/validators/make_field_required_when_other_field_does_not_have_value_validator.go Updated message to clarify the issue when multiple or no matches are found.
internal/services/data_record/dynamic_columns_validator.go Added error checking for attribute retrieval from config.
internal/modifiers/sync_attribute_plan_modifier.go Corrected checksum error message to report SHA256 and added handling for empty checksum values.
internal/modifiers/set_string_value_unknown_if_checksum_change_modifier.go Updated checksum error message and added immediate error checking for diagnostic appending.
internal/modifiers/set_bool_value_unknown_if_checksum_change_modifier.go Revised error message to reflect SHA256 instead of MD5.
.changes/unreleased/fixed-20250605-102519.yaml Documented the improvements and fixes in the changelog.

@mawasile mawasile added ai assisted Pull requests that have be fully or partially implemented using Copilot or AI ai found Issues and Bugs that were found using AI copilot fixed using GitHub copilot autonomous agent labels Jun 9, 2025
…odifier.go

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@mawasile mawasile enabled auto-merge (squash) June 16, 2025 18:52
@mawasile mawasile merged commit 08385ce into main Jun 17, 2025
11 checks passed
@mawasile mawasile deleted the copilot/fix-821 branch June 17, 2025 09:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ai assisted Pull requests that have be fully or partially implemented using Copilot or AI ai found Issues and Bugs that were found using AI copilot fixed using GitHub copilot autonomous agent
Projects
None yet
Development

Error loading sessions

Retrying...

Successfully merging this pull request may close these issues.

[Copilot] Validation and Modifiers Issues
3 participants