Deploy AIOS web (React glide grid + FastAPI slice)
Browse files- RELEASES.json +1 -1
- VERSION +1 -1
- web/public/AIOS_DEPLOY_RECEIPT +1 -1
- web/src/sheet/formulaEval.ts +10 -3
RELEASES.json
CHANGED
|
@@ -1,4 +1,4 @@
|
|
| 1 |
{
|
| 2 |
-
"current": "
|
| 3 |
"releases": []
|
| 4 |
}
|
|
|
|
| 1 |
{
|
| 2 |
+
"current": "3dfe966",
|
| 3 |
"releases": []
|
| 4 |
}
|
VERSION
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
|
|
|
|
| 1 |
+
3dfe966
|
web/public/AIOS_DEPLOY_RECEIPT
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
|
|
|
|
| 1 |
+
4bddbdac0a66f19f85828e1077bbbc16266db0d5f1e63fa1448e0a2b41a57313
|
web/src/sheet/formulaEval.ts
CHANGED
|
@@ -2407,8 +2407,8 @@ export const evaluateCompiledSheetFormula = (
|
|
| 2407 |
if (node.op === "+" || node.op === "-") {
|
| 2408 |
const dated = isoDayArithmetic(expressionCell(first), expressionCell(second), node.op);
|
| 2409 |
// ⚠ A DAY COUNT IS A PLAIN NUMBER. Left unformatted, `inferredFormat` reads the `DATE()`
|
| 2410 |
-
// operand's date format and a 17 day gap painted as "Jan 1, 1970". `=TODAY()-7`
|
| 2411 |
-
//
|
| 2412 |
if (dated && !("kind" in dated)) {
|
| 2413 |
return { kind: "number", value: dated.n, ...(dated.pending ? { pending: true } : {}),
|
| 2414 |
style: { format: { kind: "general" } } };
|
|
@@ -2456,11 +2456,18 @@ export const evaluateCompiledSheetFormula = (
|
|
| 2456 |
}
|
| 2457 |
if (["NOW", "TODAY", "RAND"].includes(node.name)) {
|
| 2458 |
if (node.args.length) throw new FormulaError(ERROR_VALUE + " This function takes no arguments.");
|
|
|
|
| 2459 |
if (!volatileValues.has(node)) {
|
| 2460 |
-
const epoch = context.dateSystem === "1904" ? Date.UTC(1904, 0, 1) : Date.UTC(1899, 11, 30);
|
| 2461 |
const serial = ((context.now ?? Date.now()) - epoch) / 86400000;
|
| 2462 |
volatileValues.set(node, node.name === "RAND" ? Math.random() : node.name === "TODAY" ? Math.floor(serial) : serial);
|
| 2463 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2464 |
return { n: volatileValues.get(node)!, pending: false };
|
| 2465 |
}
|
| 2466 |
if (node.name === "IF") {
|
|
|
|
| 2407 |
if (node.op === "+" || node.op === "-") {
|
| 2408 |
const dated = isoDayArithmetic(expressionCell(first), expressionCell(second), node.op);
|
| 2409 |
// ⚠ A DAY COUNT IS A PLAIN NUMBER. Left unformatted, `inferredFormat` reads the `DATE()`
|
| 2410 |
+
// operand's date format and a 17 day gap painted as "Jan 1, 1970". `=TODAY()-7` is ISO
|
| 2411 |
+
// text minus days, so it returns ISO text below and keeps its inferred date.
|
| 2412 |
if (dated && !("kind" in dated)) {
|
| 2413 |
return { kind: "number", value: dated.n, ...(dated.pending ? { pending: true } : {}),
|
| 2414 |
style: { format: { kind: "general" } } };
|
|
|
|
| 2456 |
}
|
| 2457 |
if (["NOW", "TODAY", "RAND"].includes(node.name)) {
|
| 2458 |
if (node.args.length) throw new FormulaError(ERROR_VALUE + " This function takes no arguments.");
|
| 2459 |
+
const epoch = context.dateSystem === "1904" ? Date.UTC(1904, 0, 1) : Date.UTC(1899, 11, 30);
|
| 2460 |
if (!volatileValues.has(node)) {
|
|
|
|
| 2461 |
const serial = ((context.now ?? Date.now()) - epoch) / 86400000;
|
| 2462 |
volatileValues.set(node, node.name === "RAND" ? Math.random() : node.name === "TODAY" ? Math.floor(serial) : serial);
|
| 2463 |
}
|
| 2464 |
+
// ⭐⭐ HOTFIX 2026-09-28: TODAY() IS ISO TEXT, as `formula_runtime.py::volatile_value` answers
|
| 2465 |
+
// it. As a serial, Daily Sales R7 (=E14, E12 =TODAY()) fed `YEAR(R7)` a number `functionDate`
|
| 2466 |
+
// cannot read: rows 2, 3 and 5 painted blank and `=(DATE(YEAR(R7),12,31) - R7)/7` painted
|
| 2467 |
+
// #VALUE! over the 13.43 the server stores. The serial stays the pass's one clock.
|
| 2468 |
+
if (node.name === "TODAY") {
|
| 2469 |
+
return { kind: "text", value: new Date(epoch + volatileValues.get(node)! * 86400000).toISOString().slice(0, 10) };
|
| 2470 |
+
}
|
| 2471 |
return { n: volatileValues.get(node)!, pending: false };
|
| 2472 |
}
|
| 2473 |
if (node.name === "IF") {
|