-
Notifications
You must be signed in to change notification settings - Fork 15
Tictactoe notifications not displaying in generated app #274
Comments
Related: LDflex/Solid-Playground#8 |
But this request is not being made by the SDK generator; it is made by LDflex, which supports JSON-LD.
This looks like a parser error from N3.js (not entirely sure). Someone is trying to parse the JSON-LD document as Turtle. Could you please produce a stack trace with a source map, so we can find out who that is? |
Or is the server lying and presenting the JSON-LD with |
For what it's worth, the SDK does assume it's a ttl response right now. I suppose it's possible if it's returning json-ld, the SDK code is attempting to use N3.js to parse something (most likely notifications) and hitting an error at that point. It sounds like we need a way to force accept: text/turtle instead of json-ld? |
Yeah but the question is: who issues the request? If LDflex issues the request, then LDflex is responsible for parsing, and it is sending the correct headers. If the SDK is responsible for the request, then the SDK controls the If both are fetching the same document, but the server sends improper |
Could I get all request and response headers please? |
|
The above headers are correct (with the exception of |
So I'd need the source-mapped stack trace. |
The same call against NSS shows the accept headers as |
When you send an |
Just want to add here that the Accept header sent by the client does not / should not depend on the server. The client just states what it supports; regardless of what the server has to offer. |
Yesterday, I configured the server only return turtle and the JS error went away. But the Notifications were still not working. So it looks to be some other issue than the JS error I reported above that is causing this. Today, for some strange reason, I don't see the JS error even though the server is back returning JSON-LD. We are still debugging this here an I will send on any update. @james-martin-jd what do ye do to debug the solid-react-components components? |
@jholleran there's actually a Demo application in the repo, if you clone it and then |
So, after a lot of debugging, I believe this was a bug in the code where we had mismatched PUT vs slug header values. The PUT was to @jholleran is it possible for you to test this against ESS? |
Describe the bug
I have setup two Pods, (User 1) and (User 2). User 1 creates a tictactoe game for User 2. When I log in a User 2 I don't get an notification that the game has been created.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
A notification should be displayed in the top right corner of the screen and when you click it it should display the notifications in a list.
Screenshots
N/A
Desktop (please complete the following information):
Smartphone (please complete the following information):
N/A
Additional context
The requests in the Network tab are all ok (No 404 errors). The only error I see is:
index.js:23236 Uncaught (in promise) Error: Expected entity but got literal on line 1.
at u.value (index.js:23236)
at u.value (index.js:22826)
at u.value (index.js:22854)
at index.js:23321
at Array.every ()
at u.value (index.js:23320)
at index.js:101678
at w (index.js:46479)
at Generator._invoke (index.js:46459)
at Generator.e. [as next] (index.js:46498)
at p (index.js:92343)
at a (index.js:92360)
Also, I noticed that when there is a GET request to the tictactoe inbox the response is JSONLD:
The request header for the GET request has the following:
As you can see it has
application/ld+json
beforetext/turtle
.If the SDK generator does not support JSONLD it should not have this in the Accept header.
The text was updated successfully, but these errors were encountered: