-
Notifications
You must be signed in to change notification settings - Fork 166
Open
accordproject/ergo
#817Labels
Description
Is your feature request related to a problem? Please describe.
Currently:
- templates without logic or formulas support
parseanddraftbut no other command (e.g.,initializeortrigger) - templates with logic support all commands
- templates without logic but with formulas are handled like contracts with logic
This can be a bit surprising, especially cicero initialize sometimes works when there is no logic (e.g., when a formula is in the template grammar).
Also this means testing logicless templates is somewhat cumbersome / different from other templates.
This can also mean some API calls will throw lower-level exceptions for logicless templates in some cases.
Describe the solution you'd like
More uniform handling of templates with or without logic. For instance:
- Contracts without logic are treated as having empty contract logic (i.e., a contract with a single default
initializeclause)
Additional context
Example with the signature block template from https://templates.accordproject.org/signature-block-title-name-date@0.19.0.html
bash-3.2$ cicero --version
0.21.9
bash-3.2$ cicero parse
2:49:18 PM - info: Using current directory as template folder
2:49:18 PM - info: Loading a default text/sample.md file.
2:49:19 PM - info:
{
"$class": "org.accordproject.signature.tnd.TitleNameDateSignatureBlock",
"title": "Title",
"signature": "--------",
"fullName": "Full Name",
"dateSigned": "Date Signed",
"signatory": "resource:org.accordproject.cicero.contract.AccordParty#buyer@example.com",
"clauseId": "ddb2dcef-97ba-4aa4-ab70-7cc1002d0a52"
}
bash-3.2$ cicero initialize
2:49:22 PM - info: Using current directory as template folder
2:49:22 PM - info: Loading a default text/sample.md file.
2:49:23 PM - error: Did not find any compiled JavaScript logic
Reactions are currently unavailable