Skip to content

Commit 0d6364e

Browse files
authored
BREAKING CHANGE: update engine to new solid-specific Comunica version (#79)
* BREAKING CHANGE: update to new solid-specific Comunica version * chore: remove version and platform references in .har files * chore: rebuild package-lock.json * chore: delete and rebuild package-lock
1 parent 1c92bf0 commit 0d6364e

File tree

8 files changed

+12934
-29513
lines changed

8 files changed

+12934
-29513
lines changed

components/context.jsonld

Lines changed: 0 additions & 11 deletions
This file was deleted.

config/config-default.json

Lines changed: 0 additions & 24 deletions
This file was deleted.

config/sets/http-solid.json

Lines changed: 0 additions & 29 deletions
This file was deleted.

package-lock.json

Lines changed: 12910 additions & 29408 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,6 @@
1919
"src",
2020
"lib"
2121
],
22-
"dependencies": {
23-
"@comunica/actor-http-solid-auth-fetch": "^1.2.0",
24-
"@comunica/actor-init-sparql": "^1.22.3"
25-
},
2622
"peerDependencies": {
2723
"ldflex": "^2.0.0"
2824
},
@@ -47,9 +43,7 @@
4743
"setup-polly-jest": "^0.10.0"
4844
},
4945
"scripts": {
50-
"build:engine": "mkdirp lib && comunica-compile-config config/config-default.json > lib/comunica-engine.js",
51-
"build:lib": "babel src --out-dir lib",
52-
"build": "npm run build:lib && npm run build:engine",
46+
"build": "babel src --out-dir lib",
5347
"jest": "jest",
5448
"lint": "eslint src test",
5549
"prepublishOnly": "npm run build",
@@ -73,5 +67,8 @@
7367
},
7468
"publishConfig": {
7569
"access": "public"
70+
},
71+
"dependencies": {
72+
"@comunica/actor-init-sparql-solid": "^1.0.1"
7673
}
7774
}

src/ComunicaEngine.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import DefaultEngine from '../lib/comunica-engine';
1+
import { newEngine } from '@comunica/actor-init-sparql-solid';
22

33
/**
44
* Asynchronous iterator wrapper for the Comunica SPARQL query engine.
@@ -11,7 +11,7 @@ export default class ComunicaEngine {
1111
* or an array with any of these.
1212
*/
1313
constructor(defaultSource, settings = {}) {
14-
this._engine = settings.engine ? settings.engine : DefaultEngine;
14+
this._engine = settings.engine ? settings.engine : newEngine();
1515
// Preload sources but silence errors; they will be thrown during execution
1616
this._sources = this.parseSources(defaultSource);
1717
this._sources.catch(() => null);

test/assets/http/An-ComunicaEngine-instance-without-default-source_3074023134/yields-results-for-a-SELECT-query-with-a-string-URL_1694985870/recording.har

Lines changed: 9 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
},
99
"entries": [
1010
{
11-
"_id": "fca7f7abda98fa89d83c8529bf54bd25",
11+
"_id": "759ad01d75f081487fdc55b34d5027d0",
1212
"_order": 0,
1313
"cache": {},
1414
"request": {
@@ -23,24 +23,19 @@
2323
{
2424
"_fromType": "array",
2525
"name": "user-agent",
26-
"value": "node-fetch/1.0 (+https://github.com/bitinn/node-fetch)"
26+
"value": "Comunica/actor-http-node-fetch"
2727
},
2828
{
2929
"_fromType": "array",
3030
"name": "accept-encoding",
3131
"value": "gzip,deflate"
3232
},
33-
{
34-
"_fromType": "array",
35-
"name": "connection",
36-
"value": "close"
37-
},
3833
{
3934
"name": "host",
4035
"value": "www.w3.org"
4136
}
4237
],
43-
"headersSize": 487,
38+
"headersSize": 470,
4439
"httpVersion": "HTTP/1.1",
4540
"method": "GET",
4641
"queryString": [],
@@ -57,7 +52,7 @@
5752
"headers": [
5853
{
5954
"name": "date",
60-
"value": "Sun, 26 Dec 2021 04:56:50 GMT"
55+
"value": "Sun, 26 Dec 2021 05:13:24 GMT"
6156
},
6257
{
6358
"name": "vary",
@@ -85,7 +80,7 @@
8580
},
8681
{
8782
"name": "expires",
88-
"value": "Sun, 26 Dec 2021 10:56:50 GMT"
83+
"value": "Sun, 26 Dec 2021 11:13:24 GMT"
8984
},
9085
{
9186
"name": "access-control-allow-origin",
@@ -126,28 +121,24 @@
126121
{
127122
"name": "content-security-policy",
128123
"value": "upgrade-insecure-requests"
129-
},
130-
{
131-
"name": "connection",
132-
"value": "close"
133124
}
134125
],
135-
"headersSize": 827,
126+
"headersSize": 808,
136127
"httpVersion": "HTTP/1.1",
137128
"redirectURL": "",
138129
"status": 200,
139130
"statusText": "OK"
140131
},
141-
"startedDateTime": "2021-12-26T04:56:47.609Z",
142-
"time": 3384,
132+
"startedDateTime": "2021-12-26T05:13:21.701Z",
133+
"time": 3749,
143134
"timings": {
144135
"blocked": -1,
145136
"connect": -1,
146137
"dns": -1,
147138
"receive": 0,
148139
"send": 0,
149140
"ssl": -1,
150-
"wait": 3384
141+
"wait": 3749
151142
}
152143
}
153144
],

test/assets/http/An-ComunicaEngine-instance-without-default-source_3074023134/yields-results-for-a-SELECT-query-with-an-array_2584166593/recording.har

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
},
99
"entries": [
1010
{
11-
"_id": "89fd662a5323ae09d4a1034b0b65f250",
11+
"_id": "c9daeeeb661fdd1f945bc9f762a98a0a",
1212
"_order": 0,
1313
"cache": {},
1414
"request": {
@@ -23,24 +23,19 @@
2323
{
2424
"_fromType": "array",
2525
"name": "user-agent",
26-
"value": "node-fetch/1.0 (+https://github.com/bitinn/node-fetch)"
26+
"value": "Comunica/actor-http-node-fetch"
2727
},
2828
{
2929
"_fromType": "array",
3030
"name": "accept-encoding",
3131
"value": "gzip,deflate"
3232
},
33-
{
34-
"_fromType": "array",
35-
"name": "connection",
36-
"value": "close"
37-
},
3833
{
3934
"name": "host",
4035
"value": "ruben.inrupt.net"
4136
}
4237
],
43-
"headersSize": 488,
38+
"headersSize": 471,
4439
"httpVersion": "HTTP/1.1",
4540
"method": "GET",
4641
"queryString": [],
@@ -97,33 +92,33 @@
9792
},
9893
{
9994
"name": "date",
100-
"value": "Sun, 26 Dec 2021 04:56:54 GMT"
95+
"value": "Sun, 26 Dec 2021 05:13:29 GMT"
10196
},
10297
{
10398
"name": "connection",
104-
"value": "close"
99+
"value": "keep-alive"
105100
},
106101
{
107102
"name": "transfer-encoding",
108103
"value": "chunked"
109104
}
110105
],
111-
"headersSize": 702,
106+
"headersSize": 707,
112107
"httpVersion": "HTTP/1.1",
113108
"redirectURL": "",
114109
"status": 200,
115110
"statusText": "OK"
116111
},
117-
"startedDateTime": "2021-12-26T04:56:53.010Z",
118-
"time": 2399,
112+
"startedDateTime": "2021-12-26T05:13:25.551Z",
113+
"time": 4200,
119114
"timings": {
120115
"blocked": -1,
121116
"connect": -1,
122117
"dns": -1,
123118
"receive": 0,
124119
"send": 0,
125120
"ssl": -1,
126-
"wait": 2399
121+
"wait": 4200
127122
}
128123
}
129124
],

0 commit comments

Comments
 (0)