From db4b0a6fd6f053931272d0a3bc78efaa930fafe2 Mon Sep 17 00:00:00 2001 From: Alan Orth Date: Thu, 12 Jan 2023 23:11:42 +0300 Subject: [PATCH] Add notes for 2023-01-12 --- content/posts/2023-01.md | 33 ++++++++++++++++++ docs/2023-01/index.html | 46 +++++++++++++++++++++++-- docs/categories/index.html | 2 +- docs/categories/notes/index.html | 2 +- docs/categories/notes/page/2/index.html | 2 +- docs/categories/notes/page/3/index.html | 2 +- docs/categories/notes/page/4/index.html | 2 +- docs/categories/notes/page/5/index.html | 2 +- docs/categories/notes/page/6/index.html | 2 +- docs/categories/notes/page/7/index.html | 2 +- docs/index.html | 2 +- docs/page/2/index.html | 2 +- docs/page/3/index.html | 2 +- docs/page/4/index.html | 2 +- docs/page/5/index.html | 2 +- docs/page/6/index.html | 2 +- docs/page/7/index.html | 2 +- docs/page/8/index.html | 2 +- docs/page/9/index.html | 2 +- docs/posts/index.html | 2 +- docs/posts/page/2/index.html | 2 +- docs/posts/page/3/index.html | 2 +- docs/posts/page/4/index.html | 2 +- docs/posts/page/5/index.html | 2 +- docs/posts/page/6/index.html | 2 +- docs/posts/page/7/index.html | 2 +- docs/posts/page/8/index.html | 2 +- docs/posts/page/9/index.html | 2 +- docs/sitemap.xml | 10 +++--- 29 files changed, 107 insertions(+), 34 deletions(-) diff --git a/content/posts/2023-01.md b/content/posts/2023-01.md index 5bf7c4c3f..f5513c95e 100644 --- a/content/posts/2023-01.md +++ b/content/posts/2023-01.md @@ -103,4 +103,37 @@ $ csvcut -c 'cg.contributor.affiliation[en_US]' ~/Downloads/2023-01-09-initiativ - Export the CGSpace Initiatives collection to check for missing regions and collection mappings +## 2023-01-11 + +- I'm trying the DSpace 7 REST API again + - While following onathe [DSpace 7 REST API authentication docs](https://github.com/DSpace/RestContract/blob/main/authentication.md) I still cannot log in via curl on the command line because I get a `Access is denied. Invalid CSRF token.` message + - Logging in via the HAL Browser works... + - Someone on the DSpace Slack mentioned that the [authentication documentation is out of date](https://github.com/DSpace/RestContract/issues/209) and we need to specify the cookie too + - I tried it and finally got it to work: + +```console +$ curl --head https://dspace7test.ilri.org/server/api +... +set-cookie: DSPACE-XSRF-COOKIE=42c78c56-613d-464f-89ea-79142fc5b519; Path=/server; Secure; HttpOnly; SameSite=None +dspace-xsrf-token: 42c78c56-613d-464f-89ea-79142fc5b519 +$ curl -v -X POST https://dspace7test.ilri.org/server/api/authn/login --data "user=alantest%40cgiar.org&password=dspace" -H "X-XSRF-TOKEN: 42c78c56-613d-464f-89ea-79142fc5b519" -b "DSPACE-XSRF-COOKIE=42c78c56-613d-464f-89ea-79142fc5b519" +... +authorization: Bearer eyJh...9-0 +$ curl -v "https://dspace7test.ilri.org/api/core/items" -H "Authorization: Bearer eyJh...9-0" +``` + +- I created [a pull request](https://github.com/DSpace/RestContract/pull/213) to fix the docs +- I did quite a lot of cleanup and updates on the IFPRI batch items for the Gender Equality batch upload + - Then I uploaded them to CGSpace +- I added about twenty more ORCID identifiers to my list and tagged them on CGSpace + +## 2023-01-12 + +- I exported the entire CGSpace and did some cleanups on all metadata in OpenRefine + - I was primarily interested in normalizing the DOIs, but I also normalized a bunch of publishing places + - After this imports I will export it again to do the Initiative and region mappings + - I ran the `fix-initiative-mappings.py` script and got forty-nine new mappings... +- I added several dozen new ORCID identifiers to my list and tagged ~500 on CGSpace +- Start a harvest on AReS + diff --git a/docs/2023-01/index.html b/docs/2023-01/index.html index 14a879520..d52319d1b 100644 --- a/docs/2023-01/index.html +++ b/docs/2023-01/index.html @@ -19,7 +19,7 @@ I see we have some new ones that aren’t in our list if I combine with this - + @@ -44,9 +44,9 @@ I see we have some new ones that aren’t in our list if I combine with this "@type": "BlogPosting", "headline": "January, 2023", "url": "https://alanorth.github.io/cgspace-notes/2023-01/", - "wordCount": "768", + "wordCount": "1011", "datePublished": "2023-01-01T08:44:36+03:00", - "dateModified": "2023-01-04T17:08:14+03:00", + "dateModified": "2023-01-10T22:22:03+03:00", "author": { "@type": "Person", "name": "Alan Orth" @@ -241,6 +241,46 @@ I see we have some new ones that aren’t in our list if I combine with this +

2023-01-11

+ +
$ curl --head https://dspace7test.ilri.org/server/api
+...
+set-cookie: DSPACE-XSRF-COOKIE=42c78c56-613d-464f-89ea-79142fc5b519; Path=/server; Secure; HttpOnly; SameSite=None
+dspace-xsrf-token: 42c78c56-613d-464f-89ea-79142fc5b519
+$ curl -v -X POST https://dspace7test.ilri.org/server/api/authn/login --data "user=alantest%40cgiar.org&password=dspace" -H "X-XSRF-TOKEN: 42c78c56-613d-464f-89ea-79142fc5b519" -b "DSPACE-XSRF-COOKIE=42c78c56-613d-464f-89ea-79142fc5b519"
+...
+authorization: Bearer eyJh...9-0
+$ curl -v "https://dspace7test.ilri.org/api/core/items" -H "Authorization: Bearer eyJh...9-0"
+
+

2023-01-12

+ diff --git a/docs/categories/index.html b/docs/categories/index.html index 67982c3d5..043534f92 100644 --- a/docs/categories/index.html +++ b/docs/categories/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/categories/notes/index.html b/docs/categories/notes/index.html index 88ad3e1df..c72e4f8ef 100644 --- a/docs/categories/notes/index.html +++ b/docs/categories/notes/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/categories/notes/page/2/index.html b/docs/categories/notes/page/2/index.html index c50300972..fde055414 100644 --- a/docs/categories/notes/page/2/index.html +++ b/docs/categories/notes/page/2/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/categories/notes/page/3/index.html b/docs/categories/notes/page/3/index.html index 43c5c98a3..05d0c2a8f 100644 --- a/docs/categories/notes/page/3/index.html +++ b/docs/categories/notes/page/3/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/categories/notes/page/4/index.html b/docs/categories/notes/page/4/index.html index a4f5d5e3a..ab03e663f 100644 --- a/docs/categories/notes/page/4/index.html +++ b/docs/categories/notes/page/4/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/categories/notes/page/5/index.html b/docs/categories/notes/page/5/index.html index ffa503e14..d4dd9e306 100644 --- a/docs/categories/notes/page/5/index.html +++ b/docs/categories/notes/page/5/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/categories/notes/page/6/index.html b/docs/categories/notes/page/6/index.html index ddc33d77b..849cbd18e 100644 --- a/docs/categories/notes/page/6/index.html +++ b/docs/categories/notes/page/6/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/categories/notes/page/7/index.html b/docs/categories/notes/page/7/index.html index 8e6ae68c7..e0ab4d659 100644 --- a/docs/categories/notes/page/7/index.html +++ b/docs/categories/notes/page/7/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/index.html b/docs/index.html index 6581d3923..c34f4c609 100644 --- a/docs/index.html +++ b/docs/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/page/2/index.html b/docs/page/2/index.html index cd7b59c2c..07ef85b8a 100644 --- a/docs/page/2/index.html +++ b/docs/page/2/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/page/3/index.html b/docs/page/3/index.html index 1eba6e1d8..853c5a444 100644 --- a/docs/page/3/index.html +++ b/docs/page/3/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/page/4/index.html b/docs/page/4/index.html index f33460bb7..b3f17d990 100644 --- a/docs/page/4/index.html +++ b/docs/page/4/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/page/5/index.html b/docs/page/5/index.html index 50d505b6e..b13d0e67d 100644 --- a/docs/page/5/index.html +++ b/docs/page/5/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/page/6/index.html b/docs/page/6/index.html index ceb2062cc..c52be498a 100644 --- a/docs/page/6/index.html +++ b/docs/page/6/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/page/7/index.html b/docs/page/7/index.html index ea2c261bd..efb9b57b3 100644 --- a/docs/page/7/index.html +++ b/docs/page/7/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/page/8/index.html b/docs/page/8/index.html index f58c39c5f..8bf5a6225 100644 --- a/docs/page/8/index.html +++ b/docs/page/8/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/page/9/index.html b/docs/page/9/index.html index 88bd552a5..9064b3e4e 100644 --- a/docs/page/9/index.html +++ b/docs/page/9/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/posts/index.html b/docs/posts/index.html index 58b3980b9..aff36f4f8 100644 --- a/docs/posts/index.html +++ b/docs/posts/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/posts/page/2/index.html b/docs/posts/page/2/index.html index 34c25d304..0c02c2bc9 100644 --- a/docs/posts/page/2/index.html +++ b/docs/posts/page/2/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/posts/page/3/index.html b/docs/posts/page/3/index.html index 43b05af68..bfa4b0ffb 100644 --- a/docs/posts/page/3/index.html +++ b/docs/posts/page/3/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/posts/page/4/index.html b/docs/posts/page/4/index.html index 25156cb8c..139ce8df8 100644 --- a/docs/posts/page/4/index.html +++ b/docs/posts/page/4/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/posts/page/5/index.html b/docs/posts/page/5/index.html index baafb6dc9..54212d7ab 100644 --- a/docs/posts/page/5/index.html +++ b/docs/posts/page/5/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/posts/page/6/index.html b/docs/posts/page/6/index.html index 246ff840f..9ba11fc47 100644 --- a/docs/posts/page/6/index.html +++ b/docs/posts/page/6/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/posts/page/7/index.html b/docs/posts/page/7/index.html index a027b6f9c..53c298ec0 100644 --- a/docs/posts/page/7/index.html +++ b/docs/posts/page/7/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/posts/page/8/index.html b/docs/posts/page/8/index.html index dc908cc42..20afb102f 100644 --- a/docs/posts/page/8/index.html +++ b/docs/posts/page/8/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/posts/page/9/index.html b/docs/posts/page/9/index.html index 7318bbb85..f4e1b54cb 100644 --- a/docs/posts/page/9/index.html +++ b/docs/posts/page/9/index.html @@ -10,7 +10,7 @@ - + diff --git a/docs/sitemap.xml b/docs/sitemap.xml index f93bf7ac6..6dc740c14 100644 --- a/docs/sitemap.xml +++ b/docs/sitemap.xml @@ -3,19 +3,19 @@ xmlns:xhtml="http://www.w3.org/1999/xhtml"> https://alanorth.github.io/cgspace-notes/categories/ - 2023-01-04T17:08:14+03:00 + 2023-01-10T22:22:03+03:00 https://alanorth.github.io/cgspace-notes/ - 2023-01-04T17:08:14+03:00 + 2023-01-10T22:22:03+03:00 https://alanorth.github.io/cgspace-notes/2023-01/ - 2023-01-04T17:08:14+03:00 + 2023-01-10T22:22:03+03:00 https://alanorth.github.io/cgspace-notes/categories/notes/ - 2023-01-04T17:08:14+03:00 + 2023-01-10T22:22:03+03:00 https://alanorth.github.io/cgspace-notes/posts/ - 2023-01-04T17:08:14+03:00 + 2023-01-10T22:22:03+03:00 https://alanorth.github.io/cgspace-notes/2022-12/ 2023-01-01T10:12:13+02:00