Skip to content

Introduce ignore_column remove_never: true

Dylan Griffith requested to merge ignore-column-remove-never into master

What does this MR do and why?

This MR expands our ignore_columns helper for use cases where we don't want to remove it in the future. This helper was originally introduced for dropping columns. In such cases it was always temporary and would be removed after the column was actually dropped. But we also have started using it in some parts of the application where we have a column that is read-only so we need to hide it from Rails so that it doesn't do strange things like trying to set the value from a default loaded on the model.

Previously we hacked around this by using version 3000 or by calling ignored_columns += directly which is forbidden by a cop.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Dylan Griffith

Merge request reports

Loading