clavarium 0.2.227-next.1 → 0.2.228-next.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/npm-shrinkwrap.json +2 -2
- package/package.json +1 -1
- package/server/conversations.mjs +2 -1
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "clavarium",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.228-next.1",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "clavarium",
|
|
9
|
-
"version": "0.2.
|
|
9
|
+
"version": "0.2.228-next.1",
|
|
10
10
|
"license": "MIT",
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@xterm/addon-fit": "^0.11.0",
|
package/package.json
CHANGED
package/server/conversations.mjs
CHANGED
|
@@ -393,7 +393,8 @@ export class Conversations {
|
|
|
393
393
|
if (!tool) throw new Refusal(400, 'The tool of this conversation is no longer offered.');
|
|
394
394
|
const state = await this.#vms.state(name, { fresh: true });
|
|
395
395
|
if (state !== undefined && c.phase !== 'failed' && !reset) throw new Refusal(409, 'This conversation has its machine: there is nothing to build again.');
|
|
396
|
-
|
|
396
|
+
/* A reset replaces its own machine: the room it takes is given back first. */
|
|
397
|
+
if (!(reset && state !== undefined)) await this.room({ kind: 'create', name, memoryMb: c.memoryMb });
|
|
397
398
|
this.#cancelStop(name);
|
|
398
399
|
this.drop(name);
|
|
399
400
|
/* Marked first: two requests cannot both start a build. */
|