~tsileo/microblog.pub-devel

Change unvailable json-ld context url to mirror on GitHub v1 SUPERSEDED

Dzshy: 1
 Change unvailable json-ld context url to mirror on GitHub

 1 files changed, 1 insertions(+), 1 deletions(-)
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~tsileo/microblog.pub-devel/patches/38129/mbox | git am -3
Learn more about email & git

[PATCH] Change unvailable json-ld context url to mirror on GitHub Export this patch

I have noticed that nearly all outgoings on my site failed due to the failure 
to fetch https://w3id.org/identity/v1 , which is required for json-ld signing.
https://w3id.org/identity/v1 redirect to 
https://web-payments.org/contexts/identity-v1.jsonld ,but web-payments.org is
down for two days. So I changed to the mirror on github instead and it fixed
the problem for me.

---
 app/ldsig.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/app/ldsig.py b/app/ldsig.py
index 3668516..382ff23 100644
--- a/app/ldsig.py
+++ b/app/ldsig.py
@@ -34,7 +34,7 @@ def _options_hash(doc: ap.RawObject) -> str:
    for k in ["type", "id", "signatureValue"]:
        if k in doc:
            del doc[k]
    doc["@context"] = "https://w3id.org/identity/v1"
    doc["@context"] = "https://raw.githubusercontent.com/web-payments/web-payments.org/master/contexts/identity-v1.jsonld"
    normalized = jsonld.normalize(
        doc, {"algorithm": "URDNA2015", "format": "application/nquads"}
    )
-- 
2.39.0