nodeSolidServer / nodeSolidServer/node-solid-server
Blank nodes cause 500 response ("Error translating between RDF formats") when requesting JSON-LD
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- JavaScript
- Star
- 1.8k
- Fork
- 308
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
Issue: When attempting to request a JSON-LD serialisation (via "Accept:application/ld+json" header) of a turtle document which includes one or more blank nodes, a 500 error is generated. An equivalent document where the blank node is replaced with a URI-identified node returns JSON-LD just fine.
Solid Version: Running on Solid 5.2.4 (current version on https://solid.community)
Expected outcome: Valid JSON-LD should be returned whether or not blank nodes are included (serialising any blank nodes as JSON objects without "@id", according to the JSON-LD spec).
Steps to reproduce
# 1: document without bnode, requested as turtle
$ http get https://musicog.solid.community/public/without_bnode.ttl
HTTP/1.1 200 OK
Content-Type: text/turtle
# ...
<http://example.com/testSubject1> <http://example.com/testPredicate><http://example.com/testSubject2> .
<http://example.com/testSubject2> <http://example.com/testPredicate2> "Example" .
# 2: document without bnode, requested as JSON-LD
$ http get https://musicog.solid.community/public/without_bnode.ttl Accept:application/ld+json
HTTP/1.1 200 OK
Content-Type: application/ld+json; charset=utf-8
# ...
[
{
"@id": "http://example.com/testSubject1",
"http://example.com/testPredicate": [
{
"@id": "http://example.com/testSubject2"
}
]
},
{
"@id": "http://example.com/testSubject2",
"http://example.com/testPredicate2": [
{
"@value": "Example"
}
]
}
]
# 3: document with bnode, requested as turtle
$ http get https://musicog.solid.community/public/with-bnode.ttl
HTTP/1.1 200 OK
Content-Type: text/turtle
# ...
<http://example.com/testSubject> <http://example.com/testPredicate> [ <http://example.com/testPredicate2> "Example" ] .
# 4: document with bnode, requested as JSON-LD -> 500 error!
$ http get https://musicog.solid.community/public/with-bnode.ttl Accept:application/ld+json
HTTP/1.1 500 Internal Server Error
Content-Type: text/plain; charset=utf-8
# ...
Error translating between RDF formats
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Tái hiện hai request đối với with-bnode.ttl và without_bnode.ttl bằng Accept:application/ld+json, rồi so sánh các response. Theo dõi đường đi chuyển đổi RDF sang JSON-LD của server bắt đầu từ request bị lỗi. Hoàn tất khi tài liệu có blank node trả về JSON-LD hợp lệ, trong đó các blank node được biểu diễn dưới dạng các object không có @id, thay vì response 500.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- javascript
- Lĩnh vực
- api, backend
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 42/100