augur icon indicating copy to clipboard operation
augur copied to clipboard

truncate release_id values to 256 characters

Open paras-chinchalkar opened this issue 1 week ago • 2 comments

Added truncation logic to ensure release_id values fit within the database constraint: Truncate release_id to 256 characters - Before inserting release data, truncate the release_id to exactly 256 characters to match the database constraint Add warning logging - When truncation occurs, log a warning message with details about the original length and the release name/tag being processed Handle both release types - Applied truncation logic to both regular GitHub releases and tag-only releases Backward compatible - Added optional logger parameter to maintain backward compatibility Changes Made Modified augur/tasks/github/releases/core.py: Updated get_release_inf() function signature to accept optional logger parameter Added truncation logic for release_id in both regular and tag-only release paths Added warning logging when truncation occurs Updated insert_release() to pass logger to get_release_inf()

paras-chinchalkar avatar Dec 12 '25 15:12 paras-chinchalkar

Thanks for your contribution! In order to properly prioritize and review this, please make sure you are submitting your contributions with descriptive titles that explain what the fix is. While you can mention the issue that you are fixing in the title, a better way would be to include text like "fixes#" in the body of your PR message so that github can link the issue being solved automatically.

It would also be helpful to learn a little more about why you believe these changes are a good solution to the problem, or what led you to these solutions in the first place. It's okay to summarize your code changes in the PR description, but without context, its hard for other maintainers to see why this solution is better than other options that may be available.

MoralCode avatar Dec 12 '25 18:12 MoralCode

I also notice that this PR also contains the changes from https://github.com/chaoss/augur/pull/3463. If multiple sets of changes are included in a pull request, it makes the code a lot harder to review as the maintainers need to distinguish between which code is related to what changes and are less able to consider each change independently.

MoralCode avatar Dec 12 '25 18:12 MoralCode

Augur is a data storage/collection tool. I think intentionally losing data, such as by adding truncation logic to the app, especially when we could just as easily increase the character limit for release names, is not the correct path.

Closing this issue

MoralCode avatar Dec 16 '25 14:12 MoralCode