diff --git a/.env.test b/.env.test index cf9b3c3..4afe39a 100644 --- a/.env.test +++ b/.env.test @@ -1,3 +1,3 @@ DETECTOR_VERSION=1 LINKRESOLVER_BASEURL=https://mit.primo.exlibrisgroup.com/discovery/openurl?institution=01MIT_INST&rfr_id=info:sid/mit.tacos.api&vid=01MIT_INST:MIT -UNPAYWALL_EMAIL=timdex@mit.edu +TACOS_EMAIL=tacos-help@mit.edu diff --git a/README.md b/README.md index 78a03a3..430e00d 100644 --- a/README.md +++ b/README.md @@ -65,7 +65,7 @@ changes, this is the signal which indicates that terms need to be re-evaluated. `ORIGINS`: comma-separated list of domains allowed to connect to (and thus query or contribute to) the application. Be sure to specify the port number if a connecting application is not using the standard ports (this applies mostly to local development). If not defined, no external connections will be permitted. -`UNPAYWALL_EMAIL`: email address to include in API call as required in their [documentation](https://unpaywall.org/products/api). Your personal email is appropriate for development. Deployed and for tests, use the timdex moira list email. +`TACOS_EMAIL`: email address to include in API calls or contact information. Currently used in API calls to [Unpaywall](https://unpaywall.org/products/api) and [OpenLibrary](https://openlibrary.org/developers/api). Your personal email is appropriate for development. Deployed and for tests, use the tacos-help moira list email. ### Optional diff --git a/app.json b/app.json index a674237..0cc96f8 100644 --- a/app.json +++ b/app.json @@ -11,7 +11,7 @@ "LINKRESOLVER_BASEURL": { "required": false }, - "UNPAYWALL_EMAIL": { + "TACOS_EMAIL": { "required": false } }, diff --git a/app/models/lookup_doi.rb b/app/models/lookup_doi.rb index 7e8eba1..ab2ccb0 100644 --- a/app/models/lookup_doi.rb +++ b/app/models/lookup_doi.rb @@ -30,7 +30,7 @@ def extract_metadata(external_data) end def url(doi) - "https://api.unpaywall.org/v2/#{doi}?email=#{ENV.fetch('UNPAYWALL_EMAIL')}" + "https://api.unpaywall.org/v2/#{doi}?email=#{ENV.fetch('TACOS_EMAIL')}" end def fetch(doi) diff --git a/app/models/lookup_isbn.rb b/app/models/lookup_isbn.rb index d17f5d1..d273e59 100644 --- a/app/models/lookup_isbn.rb +++ b/app/models/lookup_isbn.rb @@ -36,7 +36,10 @@ def fetch_authors(isbn_json) end def parse_response(url) - resp = HTTP.headers(accept: 'application/json', 'Content-Type': 'application/json').follow.get(url) + email = ENV.fetch('TACOS_EMAIL') + resp = HTTP.headers(accept: 'application/json', + 'Content-Type': 'application/json', + 'User-Agent': "MITL TACOS (#{email})").follow.get(url) if resp.status == 200 JSON.parse(resp.to_s) diff --git a/test/test_helper.rb b/test/test_helper.rb index 0ba70c7..ed94b0f 100644 --- a/test/test_helper.rb +++ b/test/test_helper.rb @@ -17,6 +17,28 @@ VCR.configure do |config| config.cassette_library_dir = 'test/vcr_cassettes' config.hook_into :webmock + + # Filter TACOS email. It's not sensitive, but keeping it out of code is still good practice to avoid spam + config.filter_sensitive_data('FAKE_TACOS_EMAIL') do + ENV.fetch('TACOS_EMAIL', nil).to_s + end + + config.before_record do |interaction| + header = interaction.response&.headers&.[]('Report-To') + header&.each do |redacted_text| + interaction.filter!(redacted_text, '') + end + + header = interaction.response&.headers&.[]('Reporting-Endpoints') + header&.each do |redacted_text| + interaction.filter!(redacted_text, '') + end + + header = interaction.response&.headers&.[]('Nel') + header&.each do |redacted_text| + interaction.filter!(redacted_text, '') + end + end end module ActionDispatch diff --git a/test/vcr_cassettes/doi_10_1038/d41586-023-03497-2.yml b/test/vcr_cassettes/doi_10_1038/d41586-023-03497-2.yml index bd1f68a..e6a61e1 100644 --- a/test/vcr_cassettes/doi_10_1038/d41586-023-03497-2.yml +++ b/test/vcr_cassettes/doi_10_1038/d41586-023-03497-2.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: get - uri: https://api.unpaywall.org/v2/10.1038/d41586-023-03497-2?email=timdex@mit.edu + uri: https://api.unpaywall.org/v2/10.1038/d41586-023-03497-2?email=FAKE_TACOS_EMAIL body: encoding: ASCII-8BIT string: '' @@ -14,24 +14,24 @@ http_interactions: Host: - api.unpaywall.org User-Agent: - - http.rb/5.1.1 + - http.rb/5.2.0 response: status: code: 200 message: OK headers: Report-To: - - '{"group":"heroku-nel","max_age":3600,"endpoints":[{"url":"https://nel.heroku.com/reports?ts=1700238936&sid=c46efe9b-d3d2-4a0c-8c76-bfafa16c5add&s=hAVtQDLeLgABDWA%2Fyfxl0sXzZLCU4MerIlfAeEp3kAM%3D"}]}' + - "" Reporting-Endpoints: - - heroku-nel=https://nel.heroku.com/reports?ts=1700238936&sid=c46efe9b-d3d2-4a0c-8c76-bfafa16c5add&s=hAVtQDLeLgABDWA%2Fyfxl0sXzZLCU4MerIlfAeEp3kAM%3D + - "" Nel: - - '{"report_to":"heroku-nel","max_age":3600,"success_fraction":0.005,"failure_fraction":0.05,"response_headers":["Via"]}' + - "" Connection: - close Server: - gunicorn Date: - - Fri, 17 Nov 2023 16:35:36 GMT + - Mon, 13 Jan 2025 14:40:13 GMT Content-Type: - application/json Content-Length: @@ -55,5 +55,5 @@ http_interactions: "has_repository_copy": false, "best_oa_location": null, "first_oa_location": null, "oa_locations": [], "oa_locations_embargoed": [], "updated": "2023-11-14T01:48:08.241432", "data_standard": 2, "z_authors": null}' - recorded_at: Fri, 17 Nov 2023 16:35:36 GMT -recorded_with: VCR 6.2.0 + recorded_at: Mon, 13 Jan 2025 14:40:13 GMT +recorded_with: VCR 6.3.1 diff --git a/test/vcr_cassettes/doi_not_found.yml b/test/vcr_cassettes/doi_not_found.yml index 5ffde2a..d2bae0a 100644 --- a/test/vcr_cassettes/doi_not_found.yml +++ b/test/vcr_cassettes/doi_not_found.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: get - uri: https://api.unpaywall.org/v2/123456?email=timdex@mit.edu + uri: https://api.unpaywall.org/v2/123456?email=FAKE_TACOS_EMAIL body: encoding: ASCII-8BIT string: '' @@ -14,24 +14,24 @@ http_interactions: Host: - api.unpaywall.org User-Agent: - - http.rb/5.1.1 + - http.rb/5.2.0 response: status: code: 404 message: Not Found headers: Report-To: - - '{"group":"heroku-nel","max_age":3600,"endpoints":[{"url":"https://nel.heroku.com/reports?ts=1700240669&sid=c46efe9b-d3d2-4a0c-8c76-bfafa16c5add&s=BtnuqhUFIjq4XdK5GrNboBWBkxLQHGOWd5xwkbPOFCw%3D"}]}' + - "" Reporting-Endpoints: - - heroku-nel=https://nel.heroku.com/reports?ts=1700240669&sid=c46efe9b-d3d2-4a0c-8c76-bfafa16c5add&s=BtnuqhUFIjq4XdK5GrNboBWBkxLQHGOWd5xwkbPOFCw%3D + - "" Nel: - - '{"report_to":"heroku-nel","max_age":3600,"success_fraction":0.005,"failure_fraction":0.05,"response_headers":["Via"]}' + - "" Connection: - close Server: - gunicorn Date: - - Fri, 17 Nov 2023 17:04:29 GMT + - Mon, 13 Jan 2025 14:40:13 GMT Content-Type: - application/json Content-Length: @@ -52,5 +52,5 @@ http_interactions: "error": true, "message": "'123456' isn't in Unpaywall. See https://support.unpaywall.org/a/solutions/articles/44001900286" } - recorded_at: Fri, 17 Nov 2023 17:04:29 GMT -recorded_with: VCR 6.2.0 + recorded_at: Mon, 13 Jan 2025 14:40:13 GMT +recorded_with: VCR 6.3.1 diff --git a/test/vcr_cassettes/isbn_978-0-08-102133-0.yml b/test/vcr_cassettes/isbn_978-0-08-102133-0.yml index 4068835..dee3824 100644 --- a/test/vcr_cassettes/isbn_978-0-08-102133-0.yml +++ b/test/vcr_cassettes/isbn_978-0-08-102133-0.yml @@ -11,12 +11,12 @@ http_interactions: - application/json Content-Type: - application/json + User-Agent: + - MITL TACOS (FAKE_TACOS_EMAIL) Connection: - close Host: - openlibrary.org - User-Agent: - - http.rb/5.1.1 response: status: code: 302 @@ -25,7 +25,7 @@ http_interactions: Server: - nginx/1.18.0 (Ubuntu) Date: - - Fri, 17 Nov 2023 17:59:26 GMT + - Mon, 13 Jan 2025 14:41:00 GMT Content-Type: - text/html Transfer-Encoding: @@ -41,13 +41,13 @@ http_interactions: Location: - https://openlibrary.org/books/OL28035297M.json X-Ol-Stats: - - '"IB 1 0.025 MC 1 0.000 TT 0 0.026"' + - '"IB 1 0.051 MC 1 0.001 TT 0 0.053"' Referrer-Policy: - no-referrer-when-downgrade body: encoding: ASCII-8BIT string: '' - recorded_at: Fri, 17 Nov 2023 17:59:26 GMT + recorded_at: Mon, 13 Jan 2025 14:41:00 GMT - request: method: get uri: https://openlibrary.org/books/OL28035297M.json @@ -57,10 +57,10 @@ http_interactions: headers: Accept: - application/json + User-Agent: + - MITL TACOS (FAKE_TACOS_EMAIL) Connection: - close - User-Agent: - - http.rb/5.1.1 Host: - openlibrary.org response: @@ -71,7 +71,7 @@ http_interactions: Server: - nginx/1.18.0 (Ubuntu) Date: - - Fri, 17 Nov 2023 17:59:27 GMT + - Mon, 13 Jan 2025 14:41:01 GMT Content-Type: - application/json Transfer-Encoding: @@ -85,7 +85,7 @@ http_interactions: Access-Control-Max-Age: - '86400' X-Ol-Stats: - - '"MC 2 0.001 TT 0 0.003"' + - '"MC 2 0.001 TT 0 0.004"' Referrer-Policy: - no-referrer-when-downgrade body: @@ -102,7 +102,7 @@ http_interactions: 24, 2019", "last_modified": {"type": "/type/datetime", "value": "2020-10-11T22:17:32.783921"}, "works": [{"key": "/works/OL20729883W"}], "type": {"key": "/type/edition"}, "revision": 3}' - recorded_at: Fri, 17 Nov 2023 17:59:27 GMT + recorded_at: Mon, 13 Jan 2025 14:41:01 GMT - request: method: get uri: https://openlibrary.org/authors/OL7885052A.json @@ -114,12 +114,12 @@ http_interactions: - application/json Content-Type: - application/json + User-Agent: + - MITL TACOS (FAKE_TACOS_EMAIL) Connection: - close Host: - openlibrary.org - User-Agent: - - http.rb/5.1.1 response: status: code: 200 @@ -128,7 +128,7 @@ http_interactions: Server: - nginx/1.18.0 (Ubuntu) Date: - - Fri, 17 Nov 2023 17:59:27 GMT + - Mon, 13 Jan 2025 14:41:03 GMT Content-Type: - application/json Transfer-Encoding: @@ -142,7 +142,7 @@ http_interactions: Access-Control-Max-Age: - '86400' X-Ol-Stats: - - '"MC 2 0.001 TT 0 0.003"' + - '"MC 2 0.001 TT 0 0.004"' Referrer-Policy: - no-referrer-when-downgrade body: @@ -152,5 +152,5 @@ http_interactions: {"type": "/type/datetime", "value": "2020-05-12T11:06:50.608473"}, "latest_revision": 1, "key": "/authors/OL7885052A", "type": {"key": "/type/author"}, "revision": 1}' - recorded_at: Fri, 17 Nov 2023 17:59:27 GMT -recorded_with: VCR 6.2.0 + recorded_at: Mon, 13 Jan 2025 14:41:03 GMT +recorded_with: VCR 6.3.1 diff --git a/test/vcr_cassettes/isbn_not_found.yml b/test/vcr_cassettes/isbn_not_found.yml index 576ff0d..022cbba 100644 --- a/test/vcr_cassettes/isbn_not_found.yml +++ b/test/vcr_cassettes/isbn_not_found.yml @@ -11,12 +11,12 @@ http_interactions: - application/json Content-Type: - application/json + User-Agent: + - MITL TACOS (FAKE_TACOS_EMAIL) Connection: - close Host: - openlibrary.org - User-Agent: - - http.rb/5.1.1 response: status: code: 404 @@ -25,7 +25,7 @@ http_interactions: Server: - nginx/1.18.0 (Ubuntu) Date: - - Fri, 17 Nov 2023 17:59:28 GMT + - Mon, 13 Jan 2025 14:41:00 GMT Transfer-Encoding: - chunked Connection: @@ -37,9 +37,9 @@ http_interactions: Access-Control-Max-Age: - '86400' X-Ol-Stats: - - '"IB 1 0.003 MC 1 0.000 TT 0 0.004"' + - '"IB 1 0.011 MC 1 0.000 TT 0 0.012"' body: encoding: ASCII-8BIT string: '{"error": "notfound", "key": "/isbn/asdf"}' - recorded_at: Fri, 17 Nov 2023 17:59:27 GMT -recorded_with: VCR 6.2.0 + recorded_at: Mon, 13 Jan 2025 14:41:00 GMT +recorded_with: VCR 6.3.1 diff --git a/test/vcr_cassettes/issn_1078-8956.yml b/test/vcr_cassettes/issn_1078-8956.yml index 6978cb9..6176e00 100644 --- a/test/vcr_cassettes/issn_1078-8956.yml +++ b/test/vcr_cassettes/issn_1078-8956.yml @@ -14,14 +14,14 @@ http_interactions: Host: - api.crossref.org User-Agent: - - http.rb/5.1.1 + - http.rb/5.2.0 response: status: code: 200 message: OK headers: Date: - - Fri, 17 Nov 2023 17:50:18 GMT + - Mon, 13 Jan 2025 14:40:13 GMT Content-Type: - application/json Transfer-Encoding: @@ -51,9 +51,8 @@ http_interactions: - close body: encoding: UTF-8 - string: '{"status":"ok","message-type":"journal","message-version":"1.0.0","message":{"last-status-check-time":1700181899183,"counts":{"current-dois":1650,"backfile-dois":12848,"total-dois":14498},"breakdowns":{"dois-by-issued-year":[[2011,644],[1996,620],[1998,608],[1995,603],[2012,602],[1997,579],[1999,576],[2023,575],[2022,571],[2010,570],[2000,553],[2004,528],[2002,519],[2013,513],[2003,512],[2001,511],[2006,505],[2021,504],[2020,502],[2005,482],[2009,472],[2007,450],[2008,431],[2019,423],[2014,418],[2018,372],[2015,304],[2016,298],[2017,253]]},"publisher":"Springer - Science and Business Media LLC","coverage":{"affiliations-current":0.0,"similarity-checking-current":1.0,"descriptions-current":0.0,"ror-ids-current":0.0,"funders-backfile":0.01377646326276463,"licenses-backfile":0.9914383561643836,"funders-current":0.2903030303030303,"affiliations-backfile":0.0,"resource-links-backfile":0.9914383561643836,"orcids-backfile":0.0886519302615193,"update-policies-current":0.8406060606060606,"ror-ids-backfile":0.0,"orcids-current":0.6896969696969697,"similarity-checking-backfile":0.9915161892901619,"references-backfile":0.7176992528019925,"descriptions-backfile":0.0,"award-numbers-backfile":0.01113013698630137,"update-policies-backfile":0.2390255292652553,"licenses-current":1.0,"award-numbers-current":0.1987878787878788,"abstracts-backfile":0.001556662515566625,"resource-links-current":1.0,"abstracts-current":0.1903030303030303,"references-current":0.7290909090909091},"title":"Nature - Medicine","subjects":[{"ASJC":1300,"name":"General Biochemistry, Genetics - and Molecular Biology"},{"ASJC":2700,"name":"General Medicine"}],"coverage-type":{"all":{"last-status-check-time":1700181899183,"affiliations":0.0,"abstracts":0.02303607145320367,"orcids":0.1570453134698945,"licenses":0.9923442996068694,"references":0.7189461342161528,"funders":0.04524449962066349,"similarity-checking":0.9924132698806813,"award-numbers":0.03248499896544589,"ror-ids":0.0,"update-policies":0.3074694806538382,"resource-links":0.9923442996068694,"descriptions":0.0},"backfile":{"last-status-check-time":1700181899183,"affiliations":0.0,"abstracts":0.001556662515566625,"orcids":0.0886519302615193,"licenses":0.9914383561643836,"references":0.7176992528019925,"funders":0.01377646326276463,"similarity-checking":0.9915161892901619,"award-numbers":0.01113013698630137,"ror-ids":0.0,"update-policies":0.2390255292652553,"resource-links":0.9914383561643836,"descriptions":0.0},"current":{"last-status-check-time":1700181899183,"affiliations":0.0,"abstracts":0.1903030303030303,"orcids":0.6896969696969697,"licenses":1.0,"references":0.7290909090909091,"funders":0.2903030303030303,"similarity-checking":1.0,"award-numbers":0.1987878787878788,"ror-ids":0.0,"update-policies":0.8406060606060606,"resource-links":1.0,"descriptions":0.0}},"flags":{"deposits-abstracts-current":true,"deposits-orcids-current":true,"deposits":true,"deposits-affiliations-backfile":false,"deposits-update-policies-backfile":true,"deposits-similarity-checking-backfile":true,"deposits-award-numbers-current":true,"deposits-resource-links-current":true,"deposits-ror-ids-current":false,"deposits-articles":true,"deposits-affiliations-current":false,"deposits-funders-current":true,"deposits-references-backfile":true,"deposits-ror-ids-backfile":false,"deposits-abstracts-backfile":true,"deposits-licenses-backfile":true,"deposits-award-numbers-backfile":true,"deposits-descriptions-current":false,"deposits-references-current":true,"deposits-resource-links-backfile":true,"deposits-descriptions-backfile":false,"deposits-orcids-backfile":true,"deposits-funders-backfile":true,"deposits-update-policies-current":true,"deposits-similarity-checking-current":true,"deposits-licenses-current":true},"ISSN":["1078-8956","1744-7933"],"issn-type":[{"value":"1078-8956","type":"print"},{"value":"1744-7933","type":"electronic"}]}}' - recorded_at: Fri, 17 Nov 2023 17:50:18 GMT -recorded_with: VCR 6.2.0 + string: '{"status":"ok","message-type":"journal","message-version":"1.0.0","message":{"last-status-check-time":1736729415763,"counts":{"current-dois":1409,"backfile-dois":13923,"total-dois":15332},"breakdowns":{"dois-by-issued-year":[[2024,712],[2011,644],[2023,638],[1996,620],[1998,608],[1995,603],[2012,602],[1997,579],[1999,576],[2022,571],[2010,570],[2000,553],[2004,528],[2002,519],[2013,513],[2003,512],[2001,511],[2006,505],[2021,504],[2020,502],[2005,482],[2009,472],[2007,450],[2008,431],[2019,423],[2014,418],[2018,372],[2015,304],[2016,298],[2017,253],[2025,59]]},"publisher":"Springer + Science and Business Media LLC","coverage":{"affiliations-current":0.0,"similarity-checking-current":1.0,"descriptions-current":0.0,"ror-ids-current":0.0,"funders-backfile":0.03555268261150614,"licenses-backfile":0.9921712274653451,"funders-current":0.2931156848828957,"affiliations-backfile":0.0,"resource-links-backfile":0.9921712274653451,"orcids-backfile":0.1353874883286648,"update-policies-current":0.8616039744499645,"ror-ids-backfile":0.0,"orcids-current":0.7061745919091554,"similarity-checking-backfile":0.9921712274653451,"references-backfile":0.7167995403289521,"descriptions-backfile":0.0,"award-numbers-backfile":0.02578467284349637,"update-policies-backfile":0.2867198161315808,"licenses-current":1.0,"award-numbers-current":0.1980127750177431,"abstracts-backfile":0.01379013143719026,"resource-links-current":1.0,"abstracts-current":0.2505322924059617,"references-current":0.7792760823278921},"title":"Nature + Medicine","subjects":[],"coverage-type":{"all":{"last-status-check-time":1736729415763,"affiliations":0.0,"abstracts":0.03554425096197743,"orcids":0.1878301702210918,"licenses":0.9928259309985,"references":0.7224939672601578,"funders":0.05921867866692754,"similarity-checking":0.9928259309985,"award-numbers":0.04160960020870019,"ror-ids":0.0,"update-policies":0.3395291201982652,"resource-links":0.9928259309985,"descriptions":0.0},"backfile":{"last-status-check-time":1736729415763,"affiliations":0.0,"abstracts":0.01379013143719026,"orcids":0.1353874883286648,"licenses":0.9921712274653451,"references":0.7167995403289521,"funders":0.03555268261150614,"similarity-checking":0.9921712274653451,"award-numbers":0.02578467284349637,"ror-ids":0.0,"update-policies":0.2867198161315808,"resource-links":0.9921712274653451,"descriptions":0.0},"current":{"last-status-check-time":1736729415763,"affiliations":0.0,"abstracts":0.2505322924059617,"orcids":0.7061745919091554,"licenses":1.0,"references":0.7792760823278921,"funders":0.2931156848828957,"similarity-checking":1.0,"award-numbers":0.1980127750177431,"ror-ids":0.0,"update-policies":0.8616039744499645,"resource-links":1.0,"descriptions":0.0}},"flags":{"deposits-abstracts-current":true,"deposits-orcids-current":true,"deposits":true,"deposits-affiliations-backfile":false,"deposits-update-policies-backfile":true,"deposits-similarity-checking-backfile":true,"deposits-award-numbers-current":true,"deposits-resource-links-current":true,"deposits-ror-ids-current":false,"deposits-articles":true,"deposits-affiliations-current":false,"deposits-funders-current":true,"deposits-references-backfile":true,"deposits-ror-ids-backfile":false,"deposits-abstracts-backfile":true,"deposits-licenses-backfile":true,"deposits-award-numbers-backfile":true,"deposits-descriptions-current":false,"deposits-references-current":true,"deposits-resource-links-backfile":true,"deposits-descriptions-backfile":false,"deposits-orcids-backfile":true,"deposits-funders-backfile":true,"deposits-update-policies-current":true,"deposits-similarity-checking-current":true,"deposits-licenses-current":true},"ISSN":["1078-8956","1744-7933","1546-170X"],"issn-type":[{"type":"print","value":"1078-8956"},{"type":"electronic","value":"1744-7933"},{"type":null,"value":"1546-170X"}]}}' + recorded_at: Mon, 13 Jan 2025 14:40:13 GMT +recorded_with: VCR 6.3.1 diff --git a/test/vcr_cassettes/issn_not_found.yml b/test/vcr_cassettes/issn_not_found.yml index 1ef07ee..d1e9c50 100644 --- a/test/vcr_cassettes/issn_not_found.yml +++ b/test/vcr_cassettes/issn_not_found.yml @@ -14,14 +14,14 @@ http_interactions: Host: - api.crossref.org User-Agent: - - http.rb/5.1.1 + - http.rb/5.2.0 response: status: code: 404 message: Not Found headers: Date: - - Fri, 17 Nov 2023 17:54:49 GMT + - Mon, 13 Jan 2025 14:40:13 GMT Content-Type: - application/json;charset=utf-8 Transfer-Encoding: @@ -54,5 +54,5 @@ http_interactions: body: encoding: UTF-8 string: Resource not found. - recorded_at: Fri, 17 Nov 2023 17:54:49 GMT -recorded_with: VCR 6.2.0 + recorded_at: Mon, 13 Jan 2025 14:40:13 GMT +recorded_with: VCR 6.3.1 diff --git a/test/vcr_cassettes/pmid_37953305.yml b/test/vcr_cassettes/pmid_37953305.yml index 8729df5..b80a55b 100644 --- a/test/vcr_cassettes/pmid_37953305.yml +++ b/test/vcr_cassettes/pmid_37953305.yml @@ -14,14 +14,14 @@ http_interactions: Host: - eutils.ncbi.nlm.nih.gov User-Agent: - - http.rb/5.1.1 + - http.rb/5.2.0 response: status: code: 200 message: OK headers: Date: - - Fri, 17 Nov 2023 17:30:05 GMT + - Mon, 13 Jan 2025 14:40:13 GMT Server: - Finatra Strict-Transport-Security: @@ -31,9 +31,9 @@ http_interactions: Referrer-Policy: - origin-when-cross-origin Ncbi-Sid: - - 030462E715EBA16A_B93BSID + - 5F6D2469CAE34EB2_F73ESID Ncbi-Phid: - - 322C56F00DDF264500003C3277045652.1.1.m_3 + - 939B684A59FD7FC5000063FE40C0D237.1.1.m_3 Content-Type: - text/xml; charset=UTF-8 Cache-Control: @@ -47,8 +47,8 @@ http_interactions: Access-Control-Expose-Headers: - X-RateLimit-Limit,X-RateLimit-Remaining Set-Cookie: - - ncbi_sid=030462E715EBA16A_B93BSID; domain=.nih.gov; path=/; expires=Sun, 17 - Nov 2024 17:30:06 GMT + - ncbi_sid=5F6D2469CAE34EB2_F73ESID; domain=.nih.gov; path=/; expires=Tue, 13 + Jan 2026 14:40:13 GMT Vary: - Accept-Encoding X-Ua-Compatible: @@ -63,8 +63,8 @@ http_interactions: encoding: UTF-8 string: |- - + - 3795330520231112
1476-46872023Nov09NatureNatureFlashy molecules decode a polymer's lengthening chain.10.1038/d41586-023-03497-2engNews20231109
EnglandNature04104620028-0836IMChemistry
2023111304220231113042202311122340aheadofprint3795330510.1038/d41586-023-03497-210.1038/d41586-023-03497-2Ye, R. et al. Nature Chem. https://doi.org/10.1038/s41557-023-01363-2 (2023).10.1038/s41557-023-01363-2
- recorded_at: Fri, 17 Nov 2023 17:30:06 GMT -recorded_with: VCR 6.2.0 + 379533052023112320231123
1476-468762379882023NovNatureNatureFlashy molecules decode a polymer's lengthening chain.66966910.1038/d41586-023-03497-2engNews
EnglandNature04104620028-08360Polymers0Biocompatible MaterialsIMPolymersBiocompatible MaterialsChemistry
2023112364220231113042202311122340ppublish3795330510.1038/d41586-023-03497-210.1038/d41586-023-03497-2Ye, R. et al. Nature Chem. https://doi.org/10.1038/s41557-023-01363-2 (2023).10.1038/s41557-023-01363-2
+ recorded_at: Mon, 13 Jan 2025 14:40:13 GMT +recorded_with: VCR 6.3.1 diff --git a/test/vcr_cassettes/pmid_not_found.yml b/test/vcr_cassettes/pmid_not_found.yml index 4365777..a3c8716 100644 --- a/test/vcr_cassettes/pmid_not_found.yml +++ b/test/vcr_cassettes/pmid_not_found.yml @@ -14,14 +14,14 @@ http_interactions: Host: - eutils.ncbi.nlm.nih.gov User-Agent: - - http.rb/5.1.1 + - http.rb/5.2.0 response: status: code: 400 message: Bad Request headers: Date: - - Fri, 17 Nov 2023 17:34:04 GMT + - Mon, 13 Jan 2025 14:40:12 GMT Server: - Finatra Strict-Transport-Security: @@ -31,9 +31,9 @@ http_interactions: Referrer-Policy: - origin-when-cross-origin Ncbi-Sid: - - 4F4503D287162994_A463SID + - BE097B0128FEB7F4_EF6ESID Ncbi-Phid: - - D0BD49FBABD19BD500004D63451EE40A.1.1.m_1 + - 939B684A59FD7FC5000060FE40BF4196.1.1.m_1 Content-Type: - text/xml; charset=UTF-8 Cache-Control: @@ -47,8 +47,8 @@ http_interactions: Access-Control-Expose-Headers: - X-RateLimit-Limit,X-RateLimit-Remaining Set-Cookie: - - ncbi_sid=4F4503D287162994_A463SID; domain=.nih.gov; path=/; expires=Sun, 17 - Nov 2024 17:34:04 GMT + - ncbi_sid=BE097B0128FEB7F4_EF6ESID; domain=.nih.gov; path=/; expires=Tue, 13 + Jan 2026 14:40:13 GMT Vary: - Accept-Encoding X-Ua-Compatible: @@ -64,5 +64,5 @@ http_interactions: string: "\n\n\n\tID list is empty! Possibly it has no correct IDs.\n\n" - recorded_at: Fri, 17 Nov 2023 17:34:04 GMT -recorded_with: VCR 6.2.0 + recorded_at: Mon, 13 Jan 2025 14:40:13 GMT +recorded_with: VCR 6.3.1 diff --git a/test/vcr_cassettes/searchevent_10_1038/nphys1170.yml b/test/vcr_cassettes/searchevent_10_1038/nphys1170.yml index 35594f2..4d4e901 100644 --- a/test/vcr_cassettes/searchevent_10_1038/nphys1170.yml +++ b/test/vcr_cassettes/searchevent_10_1038/nphys1170.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: get - uri: https://api.unpaywall.org/v2/10.1038/nphys1170?email=timdex@mit.edu + uri: https://api.unpaywall.org/v2/10.1038/nphys1170?email=FAKE_TACOS_EMAIL body: encoding: ASCII-8BIT string: '' @@ -14,24 +14,24 @@ http_interactions: Host: - api.unpaywall.org User-Agent: - - http.rb/5.1.1 + - http.rb/5.2.0 response: status: code: 200 message: OK headers: Report-To: - - '{"group":"heroku-nel","max_age":3600,"endpoints":[{"url":"https://nel.heroku.com/reports?ts=1700244429&sid=c46efe9b-d3d2-4a0c-8c76-bfafa16c5add&s=%2BFYNLpKXL4HZPdB1xG6M8ZbB%2BFCWyaRsIfiUGcOabNg%3D"}]}' + - "" Reporting-Endpoints: - - heroku-nel=https://nel.heroku.com/reports?ts=1700244429&sid=c46efe9b-d3d2-4a0c-8c76-bfafa16c5add&s=%2BFYNLpKXL4HZPdB1xG6M8ZbB%2BFCWyaRsIfiUGcOabNg%3D + - "" Nel: - - '{"report_to":"heroku-nel","max_age":3600,"success_fraction":0.005,"failure_fraction":0.05,"response_headers":["Via"]}' + - "" Connection: - close Server: - gunicorn Date: - - Fri, 17 Nov 2023 18:07:09 GMT + - Mon, 13 Jan 2025 14:40:13 GMT Content-Type: - application/json Content-Length: @@ -56,5 +56,5 @@ http_interactions: [], "oa_locations_embargoed": [], "updated": "2021-04-01T04:17:18.585258", "data_standard": 2, "z_authors": [{"given": "Markus", "family": "Aspelmeyer", "sequence": "first"}]}' - recorded_at: Fri, 17 Nov 2023 18:07:09 GMT -recorded_with: VCR 6.2.0 + recorded_at: Mon, 13 Jan 2025 14:40:13 GMT +recorded_with: VCR 6.3.1