Repository navigation
Add the user-properties property generator - #326
Merged
Merged
Conversation
The generator takes a run's properties from a person's *.properties.json suite (AUTOPROVER_USER_PROPERTIES): each property's id, description, sort and group, and the files the suite imports. It builds a minimal system model with one component per group, and calls no model.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
A run's properties come from the native inference, a recorded
property_set.json, or agenerator in another package. None of them takes properties a person wrote. A recorded set
cannot stand in: it carries the analysed system model, and its components must match the units
rebuilt from that model, which a person's list does not have.
Fix
composer/pipeline/user_properties.pyadds theuser-propertiesgenerator, registered inpyproject.toml.AUTOPROVER_USER_PROPERTIESnames a properties file, relative to the projectroot; the run takes the suite that file defines:
properties: each property'sid(its title),description,sort(defaultsafety_property) and optionalgroup;groups: each group's name and optional description;imports: other properties files, relative to the importing file. A suite holds its ownproperties and those of every file it imports, transitively.
No model is called. The generator builds a minimal system model, the main contract with one
component per group (or
Propertiesfor ungrouped properties), and a property set that matchesit. Loading fails on a cycle of imports, an id two files of the suite define, and a group two
files describe differently.
PROPERTY_FILE_SUFFIX(.properties.json) names the convention for properties files.PROPERTY_GENERATORS.mddocuments the generator and the format.Testing
New
tests/test_user_properties.py:main_instance,lift_unharnessed,EVM.units,match_units);The non-expensive suite passes.