The returned Validate has NOT been interrogated; call .interrogate() on it to run the validation. Before running the code, accept() applies the same check as validate_syntax() and raises a ValueError if it fails. It then runs the code with the table bound to your_data and returns the Validate object that the code assigns to validation (or the last Validate object it assigns). Any .interrogate() call in the revised code is removed first.
Warning
accept() runs the revised code with Python’s exec(). Read the code (with to_code() or review()) before accepting an edit, as you would any other code you didn’t write.
Parameters
data:Any=None
The data table to bind to the plan’s your_data placeholder. If omitted, the data= provided to EditValidation is used. One of the two must be present.
The revised plan has both steps, and it ran against small_table because that’s the table passed to accept(). An EditValidation built by from_plans() has no data= of its own, so the table has to be given here. Passing a different table is also how to run the same revised plan on new data.