@eagleoutice/flowr 2.4.3 → 2.4.4
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/README.md
CHANGED
|
@@ -24,7 +24,7 @@ It offers a wide variety of features, for example:
|
|
|
24
24
|
|
|
25
25
|
```shell
|
|
26
26
|
$ docker run -it --rm eagleoutice/flowr # or npm run flowr
|
|
27
|
-
flowR repl using flowR v2.4.
|
|
27
|
+
flowR repl using flowR v2.4.3, R v4.5.0 (r-shell engine)
|
|
28
28
|
R> :query @linter "read.csv(\"/root/x.txt\")"
|
|
29
29
|
```
|
|
30
30
|
|
|
@@ -39,24 +39,24 @@ It offers a wide variety of features, for example:
|
|
|
39
39
|
╰ **File Path Validity** (file-path-validity):
|
|
40
40
|
╰ certain:
|
|
41
41
|
╰ Path `/root/x.txt` at 1.1-23
|
|
42
|
-
╰ _Metadata_: <code>{"totalReads":1,"totalUnknown":0,"totalWritesBeforeAlways":0,"totalValid":0,"searchTimeMs":
|
|
42
|
+
╰ _Metadata_: <code>{"totalReads":1,"totalUnknown":0,"totalWritesBeforeAlways":0,"totalValid":0,"searchTimeMs":1,"processTimeMs":0}</code>
|
|
43
43
|
╰ **Seeded Randomness** (seeded-randomness):
|
|
44
44
|
╰ _Metadata_: <code>{"consumerCalls":0,"callsWithFunctionProducers":0,"callsWithAssignmentProducers":0,"callsWithNonConstantProducers":0,"searchTimeMs":0,"processTimeMs":0}</code>
|
|
45
45
|
╰ **Absolute Paths** (absolute-file-paths):
|
|
46
46
|
╰ certain:
|
|
47
47
|
╰ Path `/root/x.txt` at 1.1-23
|
|
48
|
-
╰ _Metadata_: <code>{"totalConsidered":1,"totalUnknown":0,"searchTimeMs":
|
|
48
|
+
╰ _Metadata_: <code>{"totalConsidered":1,"totalUnknown":0,"searchTimeMs":1,"processTimeMs":0}</code>
|
|
49
49
|
╰ **Unused Definitions** (unused-definitions):
|
|
50
50
|
╰ _Metadata_: <code>{"totalConsidered":0,"searchTimeMs":0,"processTimeMs":0}</code>
|
|
51
51
|
╰ **Naming Convention** (naming-convention):
|
|
52
52
|
╰ _Metadata_: <code>{"numMatches":0,"numBreak":0,"searchTimeMs":0,"processTimeMs":0}</code>
|
|
53
53
|
╰ **Dataframe Access Validation** (dataframe-access-validation):
|
|
54
|
-
╰ _Metadata_: <code>{"numOperations":0,"numAccesses":0,"totalAccessed":0,"searchTimeMs":0,"processTimeMs":
|
|
54
|
+
╰ _Metadata_: <code>{"numOperations":0,"numAccesses":0,"totalAccessed":0,"searchTimeMs":0,"processTimeMs":0}</code>
|
|
55
55
|
╰ **Dead Code** (dead-code):
|
|
56
56
|
╰ _Metadata_: <code>{"consideredNodes":5,"searchTimeMs":0,"processTimeMs":0}</code>
|
|
57
57
|
╰ **Useless Loops** (useless-loop):
|
|
58
58
|
╰ _Metadata_: <code>{"numOfUselessLoops":0,"searchTimeMs":0,"processTimeMs":0}</code>
|
|
59
|
-
[;3mAll queries together required ≈2 ms (1ms accuracy, total
|
|
59
|
+
[;3mAll queries together required ≈2 ms (1ms accuracy, total 7 ms)[0m[0m
|
|
60
60
|
```
|
|
61
61
|
|
|
62
62
|
|
|
@@ -80,17 +80,17 @@ It offers a wide variety of features, for example:
|
|
|
80
80
|
|
|
81
81
|
Query: **linter** (14 ms)\
|
|
82
82
|
╰ **Deprecated Functions** (deprecated-functions):\
|
|
83
|
-
╰ _Metadata_: <code>{"totalDeprecatedCalls":0,"totalDeprecatedFunctionDefinitions":0,"searchTimeMs":
|
|
83
|
+
╰ _Metadata_: <code>{"totalDeprecatedCalls":0,"totalDeprecatedFunctionDefinitions":0,"searchTimeMs":1,"processTimeMs":0}</code>\
|
|
84
84
|
╰ **File Path Validity** (file-path-validity):\
|
|
85
85
|
╰ certain:\
|
|
86
86
|
╰ Path `/root/x.txt` at 1.1-23\
|
|
87
|
-
╰ _Metadata_: <code>{"totalReads":1,"totalUnknown":0,"totalWritesBeforeAlways":0,"totalValid":0,"searchTimeMs":
|
|
87
|
+
╰ _Metadata_: <code>{"totalReads":1,"totalUnknown":0,"totalWritesBeforeAlways":0,"totalValid":0,"searchTimeMs":5,"processTimeMs":0}</code>\
|
|
88
88
|
╰ **Seeded Randomness** (seeded-randomness):\
|
|
89
|
-
╰ _Metadata_: <code>{"consumerCalls":0,"callsWithFunctionProducers":0,"callsWithAssignmentProducers":0,"callsWithNonConstantProducers":0,"searchTimeMs":
|
|
89
|
+
╰ _Metadata_: <code>{"consumerCalls":0,"callsWithFunctionProducers":0,"callsWithAssignmentProducers":0,"callsWithNonConstantProducers":0,"searchTimeMs":1,"processTimeMs":0}</code>\
|
|
90
90
|
╰ **Absolute Paths** (absolute-file-paths):\
|
|
91
91
|
╰ certain:\
|
|
92
92
|
╰ Path `/root/x.txt` at 1.1-23\
|
|
93
|
-
╰ _Metadata_: <code>{"totalConsidered":1,"totalUnknown":0,"searchTimeMs":
|
|
93
|
+
╰ _Metadata_: <code>{"totalConsidered":1,"totalUnknown":0,"searchTimeMs":1,"processTimeMs":1}</code>\
|
|
94
94
|
╰ **Unused Definitions** (unused-definitions):\
|
|
95
95
|
╰ _Metadata_: <code>{"totalConsidered":0,"searchTimeMs":0,"processTimeMs":0}</code>\
|
|
96
96
|
╰ **Naming Convention** (naming-convention):\
|
|
@@ -98,14 +98,14 @@ It offers a wide variety of features, for example:
|
|
|
98
98
|
╰ **Dataframe Access Validation** (dataframe-access-validation):\
|
|
99
99
|
╰ _Metadata_: <code>{"numOperations":0,"numAccesses":0,"totalAccessed":0,"searchTimeMs":0,"processTimeMs":3}</code>\
|
|
100
100
|
╰ **Dead Code** (dead-code):\
|
|
101
|
-
╰ _Metadata_: <code>{"consideredNodes":5,"searchTimeMs":
|
|
101
|
+
╰ _Metadata_: <code>{"consideredNodes":5,"searchTimeMs":0,"processTimeMs":0}</code>\
|
|
102
102
|
╰ **Useless Loops** (useless-loop):\
|
|
103
|
-
╰ _Metadata_: <code>{"numOfUselessLoops":0,"searchTimeMs":
|
|
104
|
-
_All queries together required ≈14 ms (1ms accuracy, total
|
|
103
|
+
╰ _Metadata_: <code>{"numOfUselessLoops":0,"searchTimeMs":1,"processTimeMs":0}</code>\
|
|
104
|
+
_All queries together required ≈14 ms (1ms accuracy, total 208 ms)_
|
|
105
105
|
|
|
106
106
|
<details> <summary style="color:gray">Show Detailed Results as Json</summary>
|
|
107
107
|
|
|
108
|
-
The analysis required _208.
|
|
108
|
+
The analysis required _208.4 ms_ (including parsing and normalization and the query) within the generation environment.
|
|
109
109
|
|
|
110
110
|
In general, the JSON contains the Ids of the nodes in question as they are present in the normalized AST or the dataflow graph of flowR.
|
|
111
111
|
Please consult the [Interface](https://github.com/flowr-analysis/flowr/wiki/Interface) wiki page for more information on how to get those.
|
|
@@ -122,7 +122,7 @@ It offers a wide variety of features, for example:
|
|
|
122
122
|
".meta": {
|
|
123
123
|
"totalDeprecatedCalls": 0,
|
|
124
124
|
"totalDeprecatedFunctionDefinitions": 0,
|
|
125
|
-
"searchTimeMs":
|
|
125
|
+
"searchTimeMs": 1,
|
|
126
126
|
"processTimeMs": 0
|
|
127
127
|
}
|
|
128
128
|
},
|
|
@@ -144,8 +144,8 @@ It offers a wide variety of features, for example:
|
|
|
144
144
|
"totalUnknown": 0,
|
|
145
145
|
"totalWritesBeforeAlways": 0,
|
|
146
146
|
"totalValid": 0,
|
|
147
|
-
"searchTimeMs":
|
|
148
|
-
"processTimeMs":
|
|
147
|
+
"searchTimeMs": 5,
|
|
148
|
+
"processTimeMs": 0
|
|
149
149
|
}
|
|
150
150
|
},
|
|
151
151
|
"seeded-randomness": {
|
|
@@ -155,8 +155,8 @@ It offers a wide variety of features, for example:
|
|
|
155
155
|
"callsWithFunctionProducers": 0,
|
|
156
156
|
"callsWithAssignmentProducers": 0,
|
|
157
157
|
"callsWithNonConstantProducers": 0,
|
|
158
|
-
"searchTimeMs":
|
|
159
|
-
"processTimeMs":
|
|
158
|
+
"searchTimeMs": 1,
|
|
159
|
+
"processTimeMs": 0
|
|
160
160
|
}
|
|
161
161
|
},
|
|
162
162
|
"absolute-file-paths": {
|
|
@@ -175,8 +175,8 @@ It offers a wide variety of features, for example:
|
|
|
175
175
|
".meta": {
|
|
176
176
|
"totalConsidered": 1,
|
|
177
177
|
"totalUnknown": 0,
|
|
178
|
-
"searchTimeMs":
|
|
179
|
-
"processTimeMs":
|
|
178
|
+
"searchTimeMs": 1,
|
|
179
|
+
"processTimeMs": 1
|
|
180
180
|
}
|
|
181
181
|
},
|
|
182
182
|
"unused-definitions": {
|
|
@@ -210,7 +210,7 @@ It offers a wide variety of features, for example:
|
|
|
210
210
|
"results": [],
|
|
211
211
|
".meta": {
|
|
212
212
|
"consideredNodes": 5,
|
|
213
|
-
"searchTimeMs":
|
|
213
|
+
"searchTimeMs": 0,
|
|
214
214
|
"processTimeMs": 0
|
|
215
215
|
}
|
|
216
216
|
},
|
|
@@ -218,7 +218,7 @@ It offers a wide variety of features, for example:
|
|
|
218
218
|
"results": [],
|
|
219
219
|
".meta": {
|
|
220
220
|
"numOfUselessLoops": 0,
|
|
221
|
-
"searchTimeMs":
|
|
221
|
+
"searchTimeMs": 1,
|
|
222
222
|
"processTimeMs": 0
|
|
223
223
|
}
|
|
224
224
|
}
|
|
@@ -295,7 +295,7 @@ It offers a wide variety of features, for example:
|
|
|
295
295
|
|
|
296
296
|
```shell
|
|
297
297
|
$ docker run -it --rm eagleoutice/flowr # or npm run flowr
|
|
298
|
-
flowR repl using flowR v2.4.
|
|
298
|
+
flowR repl using flowR v2.4.3, R v4.5.0 (r-shell engine)
|
|
299
299
|
R> :slicer test/testfiles/example.R --criterion "11@sum"
|
|
300
300
|
```
|
|
301
301
|
|
|
@@ -342,7 +342,7 @@ It offers a wide variety of features, for example:
|
|
|
342
342
|
|
|
343
343
|
|
|
344
344
|
* 🚀 **fast data- and control-flow graphs**\
|
|
345
|
-
Within just <i><span title="This measurement is automatically fetched from the latest benchmark!">
|
|
345
|
+
Within just <i><span title="This measurement is automatically fetched from the latest benchmark!">136.1 ms</span></i> (as of Aug 20, 2025),
|
|
346
346
|
_flowR_ can analyze the data- and control-flow of the average real-world R script. See the [benchmarks](https://flowr-analysis.github.io/flowr/wiki/stats/benchmark) for more information,
|
|
347
347
|
and consult the [wiki pages](https://github.com/flowr-analysis/flowr/wiki/Dataflow-Graph) for more details on the dataflow graph.
|
|
348
348
|
|
|
@@ -378,7 +378,7 @@ It offers a wide variety of features, for example:
|
|
|
378
378
|
|
|
379
379
|
```shell
|
|
380
380
|
$ docker run -it --rm eagleoutice/flowr # or npm run flowr
|
|
381
|
-
flowR repl using flowR v2.4.
|
|
381
|
+
flowR repl using flowR v2.4.3, R v4.5.0 (r-shell engine)
|
|
382
382
|
R> :dataflow* test/testfiles/example.R
|
|
383
383
|
```
|
|
384
384
|
|
|
@@ -679,7 +679,7 @@ It offers a wide variety of features, for example:
|
|
|
679
679
|
```
|
|
680
680
|
|
|
681
681
|
|
|
682
|
-
(The analysis required _14.
|
|
682
|
+
(The analysis required _14.0 ms_ (including parse and normalize, using the [r-shell](https://github.com/flowr-analysis/flowr/wiki/Engines) engine) within the generation environment.)
|
|
683
683
|
|
|
684
684
|
|
|
685
685
|
|
|
@@ -52,7 +52,8 @@ const PathFunctions = {
|
|
|
52
52
|
'file.path': (df, vtx, config) => {
|
|
53
53
|
const fsep = (0, resolve_argument_1.getArgumentStringValue)(config.solver.variables, df, vtx, undefined, 'fsep', true);
|
|
54
54
|
// in the future we can access `.Platform$file.sep` here
|
|
55
|
-
const
|
|
55
|
+
const v = fsep?.values();
|
|
56
|
+
const sepValues = v ? [...v].flatMap(s => [...s].filter(assert_1.isNotUndefined)) : [path_1.default.sep];
|
|
56
57
|
if (sepValues.some(s => s === dependencies_query_format_1.Unknown || (0, assert_1.isUndefined)(s))) {
|
|
57
58
|
// if we have no fsep, we cannot construct a path
|
|
58
59
|
return undefined;
|
|
@@ -44,7 +44,7 @@ exports.DATA_FRAME_ACCESS_VALIDATION = {
|
|
|
44
44
|
}
|
|
45
45
|
accesses.push(access);
|
|
46
46
|
}
|
|
47
|
-
const operations = accessOperations.entries().flatMap(([, operations]) => operations)
|
|
47
|
+
const operations = [...accessOperations.entries()].flatMap(([, operations]) => operations);
|
|
48
48
|
const metadata = {
|
|
49
49
|
numOperations: accessOperations.size,
|
|
50
50
|
numAccesses: operations.length,
|
package/package.json
CHANGED
|
@@ -136,7 +136,7 @@ function getResults(data, results, kind, functions, makeInfo) {
|
|
|
136
136
|
const margs = info.additionalArgs?.mode;
|
|
137
137
|
(0, assert_1.guard)(margs, 'Need additional argument mode when checking for mode');
|
|
138
138
|
const modeArgs = (0, resolve_argument_1.getArgumentStringValue)(data.config.solver.variables, data.dataflow.graph, vertex, margs.argIdx, margs.argName, margs.resolveValue);
|
|
139
|
-
const modeValues = modeArgs?.values().flatMap(v => [...v]) ?? [];
|
|
139
|
+
const modeValues = [...modeArgs?.values() ?? []].flatMap(v => [...v]) ?? [];
|
|
140
140
|
if (info.ignoreIf === 'mode-only-read' && modeValues.every(m => m && readOnlyModes.has(m))) {
|
|
141
141
|
// all modes are read-only, so we can ignore this
|
|
142
142
|
return [];
|
package/queries/query.js
CHANGED
|
@@ -103,7 +103,9 @@ function executeQueries(data, queries) {
|
|
|
103
103
|
};
|
|
104
104
|
return r;
|
|
105
105
|
}
|
|
106
|
-
return Promise.all(results.map(([type, result]) => Promise.resolve(result).then(resolvedResult => [type, resolvedResult])
|
|
106
|
+
return Promise.all(results.map(([type, result]) => Promise.resolve(result).then(resolvedResult => [type, resolvedResult]).catch(() => {
|
|
107
|
+
return [type, undefined];
|
|
108
|
+
}))).then(resultsArray => {
|
|
107
109
|
const results = Object.fromEntries(resultsArray);
|
|
108
110
|
results['.meta'] = {
|
|
109
111
|
timing: Date.now() - now
|
package/util/version.js
CHANGED
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.flowrVersion = flowrVersion;
|
|
4
4
|
const semver_1 = require("semver");
|
|
5
5
|
// this is automatically replaced with the current version by release-it
|
|
6
|
-
const version = '2.4.
|
|
6
|
+
const version = '2.4.4';
|
|
7
7
|
function flowrVersion() {
|
|
8
8
|
return new semver_1.SemVer(version);
|
|
9
9
|
}
|