Skip to content

Commit

Permalink
Merge pull request #43 from algorand-devrel/dev
Browse files Browse the repository at this point in the history
0.12.1: fix default create bare_call_config
  • Loading branch information
joe-p authored May 20, 2023
2 parents 0e4e96d + 0d46dba commit 7f1f5db
Show file tree
Hide file tree
Showing 11 changed files with 29 additions and 11 deletions.
4 changes: 3 additions & 1 deletion examples/calculator/artifacts/Calculator.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@
}
}
},
"bare_call_config": {},
"bare_call_config": {
"no_op": "CREATE"
},
"schema": {
"local": {
"declared": {},
Expand Down
4 changes: 3 additions & 1 deletion examples/tuple_in_box/tealscript_artifacts/ContactsApp.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@
}
}
},
"bare_call_config": {},
"bare_call_config": {
"no_op": "CREATE"
},
"schema": {
"local": {
"declared": {},
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@algorandfoundation/tealscript",
"version": "0.12.0",
"version": "0.12.1",
"description": "Enables Algorand smart contract development with native TypeScript syntax, tooling, and IDE support",
"homepage": "https://github.com/algorand-devrel/TEALScript",
"bugs": {
Expand Down
2 changes: 1 addition & 1 deletion src/lib/compiler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2902,7 +2902,7 @@ export default class Compiler {
if (oc === 'OptIn') bareCallConfig.opt_in = 'CALL';
});

if (this.bareCreate) bareCallConfig.no_op = 'CREATE';
if (this.bareCreate || !Object.values(this.handledActions).flat().includes('createApplication')) bareCallConfig.no_op = 'CREATE';

return appSpec;
}
Expand Down
4 changes: 3 additions & 1 deletion tests/contracts/AccountTest.json
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,9 @@
}
}
},
"bare_call_config": {},
"bare_call_config": {
"no_op": "CREATE"
},
"schema": {
"local": {
"declared": {},
Expand Down
4 changes: 3 additions & 1 deletion tests/contracts/BinaryTest.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@
}
}
},
"bare_call_config": {},
"bare_call_config": {
"no_op": "CREATE"
},
"schema": {
"local": {
"declared": {},
Expand Down
4 changes: 3 additions & 1 deletion tests/contracts/IfTest.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@
}
}
},
"bare_call_config": {},
"bare_call_config": {
"no_op": "CREATE"
},
"schema": {
"local": {
"declared": {},
Expand Down
4 changes: 3 additions & 1 deletion tests/contracts/ItxnsTest.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@
}
}
},
"bare_call_config": {},
"bare_call_config": {
"no_op": "CREATE"
},
"schema": {
"local": {
"declared": {},
Expand Down
4 changes: 3 additions & 1 deletion tests/contracts/LoopsTest.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
}
}
},
"bare_call_config": {},
"bare_call_config": {
"no_op": "CREATE"
},
"schema": {
"local": {
"declared": {},
Expand Down
4 changes: 3 additions & 1 deletion tests/contracts/MathTest.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,9 @@
}
}
},
"bare_call_config": {},
"bare_call_config": {
"no_op": "CREATE"
},
"schema": {
"local": {
"declared": {},
Expand Down
4 changes: 3 additions & 1 deletion tests/contracts/StorageTest.json
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,9 @@
}
}
},
"bare_call_config": {},
"bare_call_config": {
"no_op": "CREATE"
},
"schema": {
"local": {
"declared": {
Expand Down

0 comments on commit 7f1f5db

Please sign in to comment.