* using log directory ‘/srv/hornik/tmp/CRAN/openaistream.Rcheck’ * using R Under development (unstable) (2024-01-10 r85799) * using platform: x86_64-pc-linux-gnu * R was compiled by Debian clang version 17.0.6 (3) Debian flang-new version 17.0.6 (3) * running under: Debian GNU/Linux trixie/sid * using session charset: UTF-8 * checking for file ‘openaistream/DESCRIPTION’ ... OK * checking extension type ... Package * this is package ‘openaistream’ version ‘0.2.0’ * package encoding: UTF-8 * checking CRAN incoming feasibility ... [4s/4s] NOTE Maintainer: ‘Li Gen ’ License components with restrictions and base license permitting such: MIT + file LICENSE File 'LICENSE': YEAR: 2023 COPYRIGHT HOLDER: openaistream authors MIT License Copyright (c) 2023 libingfei Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. * checking package namespace information ... OK * checking package dependencies ... OK * checking if this is a source package ... OK * checking if there is a namespace ... OK * checking for executable files ... OK * checking for hidden files and directories ... OK * checking for portable file names ... OK * checking for sufficient/correct file permissions ... OK * checking whether package ‘openaistream’ can be installed ... [5s/5s] OK * checking package directory ... OK * checking for future file timestamps ... OK * checking DESCRIPTION meta-information ... NOTE License stub is invalid DCF. * checking top-level files ... OK * checking for left-over files ... OK * checking index information ... OK * checking package subdirectories ... OK * checking R files for non-ASCII characters ... OK * checking R files for syntax errors ... OK * checking whether the package can be loaded ... [0s/0s] OK * checking whether the package can be loaded with stated dependencies ... [0s/0s] OK * checking whether the package can be unloaded cleanly ... [0s/0s] OK * checking whether the namespace can be loaded with stated dependencies ... [0s/0s] OK * checking whether the namespace can be unloaded cleanly ... [0s/0s] OK * checking loading without being on the library search path ... [0s/0s] OK * checking use of S3 registration ... OK * checking dependencies in R code ... OK * checking S3 generic/method consistency ... OK * checking replacement functions ... OK * checking foreign function calls ... OK * checking R code for possible problems ... [2s/2s] OK * checking Rd files ... [0s/0s] OK * checking Rd metadata ... OK * checking Rd line widths ... OK * checking Rd cross-references ... OK * checking for missing documentation entries ... OK * checking for code/documentation mismatches ... OK * checking Rd \usage sections ... OK * checking Rd contents ... OK * checking for unstated dependencies in examples ... OK * checking examples ... [0s/0s] OK * checking for unstated dependencies in ‘tests’ ... OK * checking tests ... [4s/231s] ERROR Running ‘testthat.R’ [4s/230s] Running the tests in ‘tests/testthat.R’ failed. Complete output: > # This file is part of the standard setup for testthat. > # It is recommended that you do not modify it. > # > # Where should you do additional test configuration? > # Learn more about the roles of various files in: > # * https://r-pkgs.org/testing-design.html#sec-tests-files-overview > # * https://testthat.r-lib.org/articles/special-files.html > > library(testthat) > library(openaistream) Loading required package: jsonlite Loading required package: httr2 Attaching package: 'httr2' The following objects are masked from 'package:testthat': local_mock, with_mock Loading required package: R6 Loading required package: iterators Loading required package: curl Using libcurl 8.5.0 with GnuTLS/3.8.2 > > test_check("openaistream") * WARNING: failed to open cookie file "" * Found bundle for host: 0x5596209fdb50 [can multiplex] * Re-using existing connection with host api.openai.com * [HTTP/2] [11] OPENED stream for https://api.openai.com/v1/embeddings * [HTTP/2] [11] [:method: POST] * [HTTP/2] [11] [:scheme: https] * [HTTP/2] [11] [:authority: api.openai.com] * [HTTP/2] [11] [:path: /v1/embeddings] * [HTTP/2] [11] [user-agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0] * [HTTP/2] [11] [accept: */*] * [HTTP/2] [11] [accept-encoding: deflate, gzip, br, zstd] * [HTTP/2] [11] [authorization: Bearer ] * [HTTP/2] [11] [content-type: application/json] * [HTTP/2] [11] [content-length: 57] -> POST /v1/embeddings HTTP/2 -> Host: api.openai.com -> User-Agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0 -> Accept: */* -> Accept-Encoding: deflate, gzip, br, zstd -> Authorization: Bearer -> Content-Type: application/json -> Content-Length: 57 -> >> {"model":"text-embedding-ada-002","input":"who are you?"} <- HTTP/2 401 <- date: Thu, 11 Jan 2024 03:15:28 GMT <- content-type: application/json; charset=utf-8 <- content-length: 496 <- vary: Origin <- x-request-id: 26eb54e43217ebf7fe2d91d30bd50f91 <- strict-transport-security: max-age=15724800; includeSubDomains <- cf-cache-status: DYNAMIC * Added cookie __cf_bm="_xv2MDTl_V7q3CmfxID0E_PFqGSNjr7JRwU8eZY.8NI-1704942928-1-AUwBix4wcK0gR7qCkQ6by2j3blPShu9hRnhQxt3LZ1tkTE0JsazPzE8/oVVGzKVxhuClFEEbkNRqbV0MfU/ccz4=" for domain api.openai.com, path /, expire 1704944728 <- set-cookie: __cf_bm=_xv2MDTl_V7q3CmfxID0E_PFqGSNjr7JRwU8eZY.8NI-1704942928-1-AUwBix4wcK0gR7qCkQ6by2j3blPShu9hRnhQxt3LZ1tkTE0JsazPzE8/oVVGzKVxhuClFEEbkNRqbV0MfU/ccz4=; path=/; expires=Thu, 11-Jan-24 03:45:28 GMT; domain=.api.openai.com; HttpOnly; Secure; SameSite=None * Added cookie _cfuvid="QE9Vbn4R4.qmRCf6cNNgdmvwTTjagbSijRZXLJBIyNI-1704942928045-0-604800000" for domain api.openai.com, path /, expire 0 <- set-cookie: _cfuvid=QE9Vbn4R4.qmRCf6cNNgdmvwTTjagbSijRZXLJBIyNI-1704942928045-0-604800000; path=/; domain=.api.openai.com; HttpOnly; Secure; SameSite=None <- server: cloudflare <- cf-ray: 8439fed35bd95bb9-VIE <- alt-svc: h3=":443"; ma=86400 <- << { << "error": { << "message": "You didn't provide an API key. You need to provide your API key in an Authorization header using Bearer auth (i.e. Authorization: Bearer YOUR_KEY), or as the password field (with blank username) if you're accessing the API from your browser and are prompted for a username and password. You can obtain an API key from https://platform.openai.com/account/api-keys.", << "type": "invalid_request_error", << "param": null, << "code": null << } << } * Connection #0 to host api.openai.com left intact * WARNING: failed to open cookie file "" * Found bundle for host: 0x5596209fdb50 [can multiplex] * Re-using existing connection with host api.openai.com * [HTTP/2] [33] OPENED stream for https://api.openai.com/v1/threads//messages * [HTTP/2] [33] [:method: POST] * [HTTP/2] [33] [:scheme: https] * [HTTP/2] [33] [:authority: api.openai.com] * [HTTP/2] [33] [:path: /v1/threads//messages] * [HTTP/2] [33] [user-agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0] * [HTTP/2] [33] [accept: */*] * [HTTP/2] [33] [accept-encoding: deflate, gzip, br, zstd] * [HTTP/2] [33] [authorization: Bearer ] * [HTTP/2] [33] [openai-beta: assistants=v1] * [HTTP/2] [33] [content-type: application/json] * [HTTP/2] [33] [content-length: 51] -> POST /v1/threads//messages HTTP/2 -> Host: api.openai.com -> User-Agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0 -> Accept: */* -> Accept-Encoding: deflate, gzip, br, zstd -> Authorization: Bearer -> OpenAI-Beta: assistants=v1 -> Content-Type: application/json -> Content-Length: 51 -> >> {"file_ids":[null],"role":"user","content":"hello"} <- HTTP/2 401 <- date: Thu, 11 Jan 2024 03:15:30 GMT <- content-type: application/json <- content-length: 231 <- www-authenticate: Basic realm="OpenAI API" <- openai-version: 2020-10-01 <- x-request-id: 7c7d86658a1fb7b630223825ccdbaedd <- openai-processing-ms: 264 <- strict-transport-security: max-age=15724800; includeSubDomains <- cf-cache-status: DYNAMIC * Added cookie __cf_bm="HACdampwYO8tXthwJb0H6F9MlhyjBjH0RtMUyjxO_40-1704942930-1-ATz/SFhCI7FZhtCLehJTwDR6UIihn8xQCmAh0YWuOOLfeEbSVRX9lnLQaiHFLOeWTl9nNMpGgxIRDAqtQPEjPWI=" for domain api.openai.com, path /, expire 1704944730 <- set-cookie: __cf_bm=HACdampwYO8tXthwJb0H6F9MlhyjBjH0RtMUyjxO_40-1704942930-1-ATz/SFhCI7FZhtCLehJTwDR6UIihn8xQCmAh0YWuOOLfeEbSVRX9lnLQaiHFLOeWTl9nNMpGgxIRDAqtQPEjPWI=; path=/; expires=Thu, 11-Jan-24 03:45:30 GMT; domain=.api.openai.com; HttpOnly; Secure; SameSite=None * Added cookie _cfuvid="2iXllgZg5xLWPwNETY2joE8xs_KiJ7_A4_2Gn6WfZMw-1704942930499-0-604800000" for domain api.openai.com, path /, expire 0 <- set-cookie: _cfuvid=2iXllgZg5xLWPwNETY2joE8xs_KiJ7_A4_2Gn6WfZMw-1704942930499-0-604800000; path=/; domain=.api.openai.com; HttpOnly; Secure; SameSite=None <- server: cloudflare <- cf-ray: 8439fee108f35bb9-VIE <- alt-svc: h3=":443"; ma=86400 <- << { << "error": { << "message": "Incorrect API key provided: ''. You can find your API key at https://platform.openai.com/account/api-keys.", << "type": "invalid_request_error", << "param": null, << "code": "invalid_api_key" << } << } * Connection #0 to host api.openai.com left intact * WARNING: failed to open cookie file "" * Found bundle for host: 0x5596209fdb50 [can multiplex] * Re-using existing connection with host api.openai.com * [HTTP/2] [35] OPENED stream for https://api.openai.com/v1/threads//messages * [HTTP/2] [35] [:method: GET] * [HTTP/2] [35] [:scheme: https] * [HTTP/2] [35] [:authority: api.openai.com] * [HTTP/2] [35] [:path: /v1/threads//messages] * [HTTP/2] [35] [user-agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0] * [HTTP/2] [35] [accept: */*] * [HTTP/2] [35] [accept-encoding: deflate, gzip, br, zstd] * [HTTP/2] [35] [authorization: Bearer ] * [HTTP/2] [35] [content-type: application/json] * [HTTP/2] [35] [openai-beta: assistants=v1] -> GET /v1/threads//messages HTTP/2 -> Host: api.openai.com -> User-Agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0 -> Accept: */* -> Accept-Encoding: deflate, gzip, br, zstd -> Authorization: Bearer -> Content-Type: application/json -> OpenAI-Beta: assistants=v1 -> <- HTTP/2 401 <- date: Thu, 11 Jan 2024 03:15:30 GMT <- content-type: application/json <- content-length: 231 <- www-authenticate: Basic realm="OpenAI API" <- openai-version: 2020-10-01 <- x-request-id: c27c2af3af81c3bf17e2e766969ac975 <- openai-processing-ms: 12 <- strict-transport-security: max-age=15724800; includeSubDomains <- cf-cache-status: DYNAMIC * Added cookie __cf_bm="CtICHpXEr2JIaonqWYo_pzF38ircfHVTASlzkIkNcco-1704942930-1-AY8QiV1C2dpvUggfYpY2jt1mPdLmW4GuvIv4UiU89AvpAjApfQvVOIlcZjLHegH2b9GZ3WWwPpjkylYKcUrIDH0=" for domain api.openai.com, path /, expire 1704944730 <- set-cookie: __cf_bm=CtICHpXEr2JIaonqWYo_pzF38ircfHVTASlzkIkNcco-1704942930-1-AY8QiV1C2dpvUggfYpY2jt1mPdLmW4GuvIv4UiU89AvpAjApfQvVOIlcZjLHegH2b9GZ3WWwPpjkylYKcUrIDH0=; path=/; expires=Thu, 11-Jan-24 03:45:30 GMT; domain=.api.openai.com; HttpOnly; Secure; SameSite=None * Added cookie _cfuvid="uUqD_QJdD8l9IADuNJml7zWKPuAOw5fMKZGW2IE6Wr8-1704942930698-0-604800000" for domain api.openai.com, path /, expire 0 <- set-cookie: _cfuvid=uUqD_QJdD8l9IADuNJml7zWKPuAOw5fMKZGW2IE6Wr8-1704942930698-0-604800000; path=/; domain=.api.openai.com; HttpOnly; Secure; SameSite=None <- server: cloudflare <- cf-ray: 8439fee3da245bb9-VIE <- alt-svc: h3=":443"; ma=86400 <- << { << "error": { << "message": "Incorrect API key provided: ''. You can find your API key at https://platform.openai.com/account/api-keys.", << "type": "invalid_request_error", << "param": null, << "code": "invalid_api_key" << } << } * Connection #0 to host api.openai.com left intact [1] "\n1 retry " * WARNING: failed to open cookie file "" * Found bundle for host: 0x5596209fdb50 [can multiplex] * Re-using existing connection with host api.openai.com * [HTTP/2] [5] OPENED stream for https://api.openai.com/v1/threads * [HTTP/2] [5] [:method: POST] * [HTTP/2] [5] [:scheme: https] * [HTTP/2] [5] [:authority: api.openai.com] * [HTTP/2] [5] [:path: /v1/threads] * [HTTP/2] [5] [user-agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0] * [HTTP/2] [5] [accept: */*] * [HTTP/2] [5] [accept-encoding: deflate, gzip, br, zstd] * [HTTP/2] [5] [authorization: Bearer ] * [HTTP/2] [5] [openai-beta: assistants=v1] * [HTTP/2] [5] [content-type: application/json] * [HTTP/2] [5] [content-length: 2] -> POST /v1/threads HTTP/2 -> Host: api.openai.com -> User-Agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0 -> Accept: */* -> Accept-Encoding: deflate, gzip, br, zstd -> Authorization: Bearer -> OpenAI-Beta: assistants=v1 -> Content-Type: application/json -> Content-Length: 2 -> >> [] <- HTTP/2 401 <- date: Thu, 11 Jan 2024 03:19:12 GMT <- content-type: application/json <- content-length: 231 <- www-authenticate: Basic realm="OpenAI API" <- openai-version: 2020-10-01 <- x-request-id: 3bb56d5617b840a552cae4a553099a12 <- openai-processing-ms: 8 <- strict-transport-security: max-age=15724800; includeSubDomains <- cf-cache-status: DYNAMIC * Added cookie __cf_bm="uthqW3MlMEP7dRCo4kAfQRJOd.P.T.kYOngASaVwifo-1704943152-1-ASzkrAazWn1j+9xBUaFNUr0aNY/etZ9JOm7Cv8UH+PMUfodWJe7FIO4lY4D4a3qmaeO2ZLXkYL3lCM+bOoj0Q1g=" for domain api.openai.com, path /, expire 1704944952 <- set-cookie: __cf_bm=uthqW3MlMEP7dRCo4kAfQRJOd.P.T.kYOngASaVwifo-1704943152-1-ASzkrAazWn1j+9xBUaFNUr0aNY/etZ9JOm7Cv8UH+PMUfodWJe7FIO4lY4D4a3qmaeO2ZLXkYL3lCM+bOoj0Q1g=; path=/; expires=Thu, 11-Jan-24 03:49:12 GMT; domain=.api.openai.com; HttpOnly; Secure; SameSite=None * Added cookie _cfuvid="_mAXNisQzQcM_7k65c9.4uUJ4gRwRu3PooWS8yEl3Cg-1704943152040-0-604800000" for domain api.openai.com, path /, expire 0 <- set-cookie: _cfuvid=_mAXNisQzQcM_7k65c9.4uUJ4gRwRu3PooWS8yEl3Cg-1704943152040-0-604800000; path=/; domain=.api.openai.com; HttpOnly; Secure; SameSite=None <- server: cloudflare <- cf-ray: 843a044b48755b9a-VIE <- alt-svc: h3=":443"; ma=86400 <- << { << "error": { << "message": "Incorrect API key provided: ''. You can find your API key at https://platform.openai.com/account/api-keys.", << "type": "invalid_request_error", << "param": null, << "code": "invalid_api_key" << } << } * Connection #1 to host api.openai.com left intact * WARNING: failed to open cookie file "" * Found bundle for host: 0x5596209fdb50 [can multiplex] * Re-using existing connection with host api.openai.com * [HTTP/2] [9] OPENED stream for https://api.openai.com/v1/assistants * [HTTP/2] [9] [:method: POST] * [HTTP/2] [9] [:scheme: https] * [HTTP/2] [9] [:authority: api.openai.com] * [HTTP/2] [9] [:path: /v1/assistants] * [HTTP/2] [9] [user-agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0] * [HTTP/2] [9] [accept: */*] * [HTTP/2] [9] [accept-encoding: deflate, gzip, br, zstd] * [HTTP/2] [9] [authorization: Bearer ] * [HTTP/2] [9] [openai-beta: assistants=v1] * [HTTP/2] [9] [content-type: application/json] * [HTTP/2] [9] [content-length: 1468] -> POST /v1/assistants HTTP/2 -> Host: api.openai.com -> User-Agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0 -> Accept: */* -> Accept-Encoding: deflate, gzip, br, zstd -> Authorization: Bearer -> OpenAI-Beta: assistants=v1 -> Content-Type: application/json -> Content-Length: 1468 -> >> 1468 bytes of binary data <- HTTP/2 401 <- date: Thu, 11 Jan 2024 03:19:12 GMT <- content-type: application/json <- content-length: 231 <- www-authenticate: Basic realm="OpenAI API" <- openai-version: 2020-10-01 <- x-request-id: 06f505abc55d9c0211544a904bf3d0d4 <- openai-processing-ms: 7 <- strict-transport-security: max-age=15724800; includeSubDomains <- cf-cache-status: DYNAMIC * Added cookie __cf_bm="3bkWodToJdymvUBrxhCfqm_9t_wd2CIDrQkwVbakbqI-1704943152-1-AUoDw0UkdWAmfi8Sj+c3gIxo6UZih6yYi5qgEhz1ngztTRMFCiORheJpPB0UknbYVFF1wwv2Ql5aTpwYWAXWV0A=" for domain api.openai.com, path /, expire 1704944952 <- set-cookie: __cf_bm=3bkWodToJdymvUBrxhCfqm_9t_wd2CIDrQkwVbakbqI-1704943152-1-AUoDw0UkdWAmfi8Sj+c3gIxo6UZih6yYi5qgEhz1ngztTRMFCiORheJpPB0UknbYVFF1wwv2Ql5aTpwYWAXWV0A=; path=/; expires=Thu, 11-Jan-24 03:49:12 GMT; domain=.api.openai.com; HttpOnly; Secure; SameSite=None * Added cookie _cfuvid="z.25X2XUHz4NSC4fNk_ZEhGB9hIzzMgDdnfbc.qJ06w-1704943152424-0-604800000" for domain api.openai.com, path /, expire 0 <- set-cookie: _cfuvid=z.25X2XUHz4NSC4fNk_ZEhGB9hIzzMgDdnfbc.qJ06w-1704943152424-0-604800000; path=/; domain=.api.openai.com; HttpOnly; Secure; SameSite=None <- server: cloudflare <- cf-ray: 843a044da9365b9a-VIE <- alt-svc: h3=":443"; ma=86400 <- << { << "error": { << "message": "Incorrect API key provided: ''. You can find your API key at https://platform.openai.com/account/api-keys.", << "type": "invalid_request_error", << "param": null, << "code": "invalid_api_key" << } << } * Connection #1 to host api.openai.com left intact * WARNING: failed to open cookie file "" * Found bundle for host: 0x5596209fdb50 [can multiplex] * Re-using existing connection with host api.openai.com * [HTTP/2] [11] OPENED stream for https://api.openai.com/v1/assistants * [HTTP/2] [11] [:method: POST] * [HTTP/2] [11] [:scheme: https] * [HTTP/2] [11] [:authority: api.openai.com] * [HTTP/2] [11] [:path: /v1/assistants] * [HTTP/2] [11] [user-agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0] * [HTTP/2] [11] [accept: */*] * [HTTP/2] [11] [accept-encoding: deflate, gzip, br, zstd] * [HTTP/2] [11] [authorization: Bearer ] * [HTTP/2] [11] [openai-beta: assistants=v1] * [HTTP/2] [11] [content-type: application/json] * [HTTP/2] [11] [content-length: 704] -> POST /v1/assistants HTTP/2 -> Host: api.openai.com -> User-Agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0 -> Accept: */* -> Accept-Encoding: deflate, gzip, br, zstd -> Authorization: Bearer -> OpenAI-Beta: assistants=v1 -> Content-Type: application/json -> Content-Length: 704 -> >> {"name":"cor_flag2","instructions":"You are a weather bot. Use the provided functions to answer questions.","tools":[{"type":"function","function":{"name":"getCurrentWeather","description":"Get the weather in location","parameters":{"type":"object","properties":{"location":{"type":"string","description":"The city and state e.g. San Francisco, CA"},"unit":{"type":"string","enum":["c","f"]}},"required":["location"]}}},{"type":"function","function":{"name":"getNickname","description":"Get the nickname of a city","parameters":{"type":"object","properties":{"location":{"type":"string","description":"The city and state e.g. San Francisco, CA"}},"required":["location"]}}}],"model":"gpt-4-1106-preview"} <- HTTP/2 401 <- date: Thu, 11 Jan 2024 03:19:12 GMT <- content-type: application/json <- content-length: 231 <- www-authenticate: Basic realm="OpenAI API" <- openai-version: 2020-10-01 <- x-request-id: 52a64f0d7649c5ecb150a3126bac9b71 <- openai-processing-ms: 8 <- strict-transport-security: max-age=15724800; includeSubDomains <- cf-cache-status: DYNAMIC * Added cookie __cf_bm=".M8xKe3qK4UcY9E2DimWhP.fMZHp4fe9EMAAXtPVaps-1704943152-1-Afhi7ujcDwbtWoMVk//zHnFHT296UB4Ks2JtRtCS+wznrdy29WwWglVEsCNklLjqitO11TbFxLOfVHXYCrEYyWw=" for domain api.openai.com, path /, expire 1704944952 <- set-cookie: __cf_bm=.M8xKe3qK4UcY9E2DimWhP.fMZHp4fe9EMAAXtPVaps-1704943152-1-Afhi7ujcDwbtWoMVk//zHnFHT296UB4Ks2JtRtCS+wznrdy29WwWglVEsCNklLjqitO11TbFxLOfVHXYCrEYyWw=; path=/; expires=Thu, 11-Jan-24 03:49:12 GMT; domain=.api.openai.com; HttpOnly; Secure; SameSite=None * Added cookie _cfuvid="yadZra8dLe1wxNQIFI_f5hQJsW4_9puDyIZO2t2ZGk4-1704943152607-0-604800000" for domain api.openai.com, path /, expire 0 <- set-cookie: _cfuvid=yadZra8dLe1wxNQIFI_f5hQJsW4_9puDyIZO2t2ZGk4-1704943152607-0-604800000; path=/; domain=.api.openai.com; HttpOnly; Secure; SameSite=None <- server: cloudflare <- cf-ray: 843a044ed9a15b9a-VIE <- alt-svc: h3=":443"; ma=86400 <- << { << "error": { << "message": "Incorrect API key provided: ''. You can find your API key at https://platform.openai.com/account/api-keys.", << "type": "invalid_request_error", << "param": null, << "code": "invalid_api_key" << } << } * Connection #1 to host api.openai.com left intact * WARNING: failed to open cookie file "" * Found bundle for host: 0x5596209fdb50 [can multiplex] * Re-using existing connection with host api.openai.com * [HTTP/2] [13] OPENED stream for https://api.openai.com/v1/threads/runs * [HTTP/2] [13] [:method: POST] * [HTTP/2] [13] [:scheme: https] * [HTTP/2] [13] [:authority: api.openai.com] * [HTTP/2] [13] [:path: /v1/threads/runs] * [HTTP/2] [13] [user-agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0] * [HTTP/2] [13] [accept: */*] * [HTTP/2] [13] [accept-encoding: deflate, gzip, br, zstd] * [HTTP/2] [13] [authorization: Bearer ] * [HTTP/2] [13] [openai-beta: assistants=v1] * [HTTP/2] [13] [content-type: application/json] * [HTTP/2] [13] [content-length: 91] -> POST /v1/threads/runs HTTP/2 -> Host: api.openai.com -> User-Agent: httr2/1.0.0 r-curl/5.2.0 libcurl/8.5.0 -> Accept: */* -> Accept-Encoding: deflate, gzip, br, zstd -> Authorization: Bearer -> OpenAI-Beta: assistants=v1 -> Content-Type: application/json -> Content-Length: 91 -> >> {"thread":{"messages":[{"role":"user","content":"What foods are good for heart health?"}]}} <- HTTP/2 401 <- date: Thu, 11 Jan 2024 03:19:12 GMT <- content-type: application/json <- content-length: 231 <- www-authenticate: Basic realm="OpenAI API" <- openai-version: 2020-10-01 <- x-request-id: 9b9d55faac4b1367af2ecfcf89391dea <- openai-processing-ms: 10 <- strict-transport-security: max-age=15724800; includeSubDomains <- cf-cache-status: DYNAMIC * Added cookie __cf_bm="yS_81IlYmYu86PiIiPIGkx6eQ9oel1L4iwZ6EcPGGpA-1704943152-1-AUpD96z6j+zVSR04bFKrkfa1RPf9PzSr6pUzHmjaBQ88OMAuDKbD4d/DMz1Tk1iewkMHgVIucHI0fGtubqZ1WYk=" for domain api.openai.com, path /, expire 1704944952 <- set-cookie: __cf_bm=yS_81IlYmYu86PiIiPIGkx6eQ9oel1L4iwZ6EcPGGpA-1704943152-1-AUpD96z6j+zVSR04bFKrkfa1RPf9PzSr6pUzHmjaBQ88OMAuDKbD4d/DMz1Tk1iewkMHgVIucHI0fGtubqZ1WYk=; path=/; expires=Thu, 11-Jan-24 03:49:12 GMT; domain=.api.openai.com; HttpOnly; Secure; SameSite=None * Added cookie _cfuvid="J4LC3W3Fht6HkWXSzg72r1EoEmRYg6hm_CzA1fVe.3s-1704943152804-0-604800000" for domain api.openai.com, path /, expire 0 <- set-cookie: _cfuvid=J4LC3W3Fht6HkWXSzg72r1EoEmRYg6hm_CzA1fVe.3s-1704943152804-0-604800000; path=/; domain=.api.openai.com; HttpOnly; Secure; SameSite=None <- server: cloudflare <- cf-ray: 843a04500a0a5b9a-VIE <- alt-svc: h3=":443"; ma=86400 <- << { << "error": { << "message": "Incorrect API key provided: ''. You can find your API key at https://platform.openai.com/account/api-keys.", << "type": "invalid_request_error", << "param": null, << "code": "invalid_api_key" << } << } * Connection #1 to host api.openai.com left intact [ FAIL 30 | WARN 0 | SKIP 0 | PASS 33 ] ══ Failed tests ════════════════════════════════════════════════════════════════ ── Failure ('test_assistants.R:19:3'): assistants ────────────────────────────── ass$name (`actual`) not equal to "cor_flag" (`expected`). `actual` is NULL `expected` is a character vector ('cor_flag') ── Failure ('test_assistants.R:21:3'): assistants ────────────────────────────── assr$name (`actual`) not equal to "cor_flag" (`expected`). `actual` is NULL `expected` is a character vector ('cor_flag') ── Failure ('test_assistants.R:23:3'): assistants ────────────────────────────── assm$model (`actual`) not equal to "gpt-4-1106-preview" (`expected`). `actual` is NULL `expected` is a character vector ('gpt-4-1106-preview') ── Error ('test_assistants.R:25:3'): assistants ──────────────────────────────── Error in `expect_contains(assl$data$name, "cor_flag")`: `object` and `expected` must both be vectors Backtrace: ▆ 1. └─testthat::expect_contains(assl$data$name, "cor_flag") at test_assistants.R:25:3 2. └─rlang::abort("`object` and `expected` must both be vectors") ── Failure ('test_chat.R:15:3'): chat ────────────────────────────────────────── nrow(streamlg$vres) (`actual`) not equal to 3 (`expected`). `actual` is NULL `expected` is a double vector (3) ── Failure ('test_chat.R:37:3'): chat ────────────────────────────────────────── length(text$all_resp) (`actual`) not equal to 2 (`expected`). `actual`: 0 `expected`: 2 ── Failure ('test_chat.R:39:3'): chat ────────────────────────────────────────── length(text$all_resp) (`actual`) not equal to 2 (`expected`). `actual`: 0 `expected`: 2 ── Failure ('test_chat.R:105:3'): chat ───────────────────────────────────────── text$message (`actual`) not equal to "parse error: trailing garbage\n \"message\": \"'sdasd' is not of type 'inte\n (right here) ------^\n" (`expected`). lines(actual) vs lines(expected) "parse error: trailing garbage" - " \"message\": \"You didn't provide an API ke" + " \"message\": \"'sdasd' is not of type 'inte" " (right here) ------^" "" ── Failure ('test_embedding.R:9:3'): embedding ───────────────────────────────── embed$data$embedding[[1]] has type 'NULL', not 'double'. ── Failure ('test_files.R:9:3'): test files ──────────────────────────────────── file_id$filename (`actual`) not equal to "train.jsonl" (`expected`). `actual` is NULL `expected` is a character vector ('train.jsonl') ── Failure ('test_files.R:15:3'): test files ─────────────────────────────────── file_list$success is not NULL `actual` is a logical vector (FALSE) `expected` is NULL ── Error ('test_files.R:22:3'): test files ───────────────────────────────────── Error: lexical error: invalid char in json text. [FALSE] [Error in `req_perform() (right here) ------^ Backtrace: ▆ 1. └─jsonlite::fromJSON(...) at test_files.R:22:3 2. └─jsonlite:::parse_and_simplify(...) 3. └─jsonlite:::parseJSON(txt, bigint_as_char) 4. └─jsonlite:::parse_string(txt, bigint_as_char) ── Error ('test_fine_tuning.R:18:3'): test fileload and fine train ───────────── Error in `expect_contains(names(job_events$data), "data")`: `object` and `expected` must both be vectors Backtrace: ▆ 1. └─testthat::expect_contains(names(job_events$data), "data") at test_fine_tuning.R:18:3 2. └─rlang::abort("`object` and `expected` must both be vectors") ── Failure ('test_images.R:10:3'): images ────────────────────────────────────── names(pic1) (`actual`) doesn't fully contain all the values in "data" (`expected`). * Missing from `actual`: "data" * Present in `actual`: "success", "message", "type" ── Error ('test_images.R:12:3'): images ──────────────────────────────────────── Error in `request(pic1$data$url)`: `url` must be a single string, not `NULL`. Backtrace: ▆ 1. ├─request(pic1$data$url) %>% req_perform(path = pic_file1) at test_images.R:12:3 2. ├─httr2::req_perform(., path = pic_file1) 3. │ └─httr2:::check_request(req) 4. │ └─httr2:::is_request(req) 5. └─httr2::request(base_url = pic1$data$url) 6. └─httr2:::new_request(base_url) 7. └─httr2:::check_string(url, call = error_call) 8. └─httr2:::stop_input_type(...) 9. └─rlang::abort(message, ..., call = call, arg = arg) ── Failure ('test_messages.R:8:3'): messages ─────────────────────────────────── names(thc) (`actual`) doesn't fully contain all the values in "id" (`expected`). * Missing from `actual`: "id" * Present in `actual`: "success", "message", "type" ── Failure ('test_messages.R:13:3'): messages ────────────────────────────────── mesc$object (`actual`) not equal to "thread.message" (`expected`). `actual` is NULL `expected` is a character vector ('thread.message') ── Error ('test_messages.R:15:3'): messages ──────────────────────────────────── Error in `expect_contains(mesl$data$id, mesc$id)`: `object` and `expected` must both be vectors Backtrace: ▆ 1. └─testthat::expect_contains(mesl$data$id, mesc$id) at test_messages.R:15:3 2. └─rlang::abort("`object` and `expected` must both be vectors") ── Error ('test_models.R:19:5'): long time test ──────────────────────────────── Error in `if (job_retrieve$status == "succeeded") { res <- handle_openai$models$delete(job_retrieve$fine_tuned_model) expect_true(res$deleted) break }`: argument is of length zero ── Failure ('test_moderations.R:9:3'): moderations ───────────────────────────── modc$results$categories$violence is not TRUE `actual` is NULL `expected` is a logical vector (TRUE) ── Failure ('test_run.R:8:3'): run ───────────────────────────────────────────── names(thc) (`actual`) doesn't fully contain all the values in "id" (`expected`). * Missing from `actual`: "id" * Present in `actual`: "success", "message", "type" ── Failure ('test_run.R:51:3'): run ──────────────────────────────────────────── ass$model (`actual`) not equal to "gpt-4-1106-preview" (`expected`). `actual` is NULL `expected` is a character vector ('gpt-4-1106-preview') ── Failure ('test_run.R:53:3'): run ──────────────────────────────────────────── runct$object (`actual`) not equal to "thread.run" (`expected`). `actual` is NULL `expected` is a character vector ('thread.run') ── Error ('test_run.R:55:3'): run ────────────────────────────────────────────── Error in `expect_contains(runl$data$thread_id, runct$thread_id)`: `object` and `expected` must both be vectors Backtrace: ▆ 1. └─testthat::expect_contains(runl$data$thread_id, runct$thread_id) at test_run.R:55:3 2. └─rlang::abort("`object` and `expected` must both be vectors") ── Failure ('test_speech.R:10:3'): speech ────────────────────────────────────── `sss` has type 'list', not 'raw'. ── Error ('test_speech.R:12:3'): speech ──────────────────────────────────────── Error in `writeBin(sss, test_file1)`: can only write vector objects Backtrace: ▆ 1. ├─testthat::expect_silent(writeBin(sss, test_file1)) at test_speech.R:12:3 2. │ └─testthat:::quasi_capture(enquo(object), NULL, evaluate_promise) 3. │ ├─testthat (local) .capture(...) 4. │ │ ├─withr::with_output_sink(...) 5. │ │ │ └─base::force(code) 6. │ │ ├─base::withCallingHandlers(...) 7. │ │ └─base::withVisible(code) 8. │ └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo)) 9. └─base::writeBin(sss, test_file1) ── Failure ('test_thread.R:8:3'): thread ─────────────────────────────────────── names(thc) (`actual`) doesn't fully contain all the values in "id" (`expected`). * Missing from `actual`: "id" * Present in `actual`: "success", "message", "type" ── Failure ('test_thread.R:10:3'): thread ────────────────────────────────────── names(thr) (`actual`) doesn't fully contain all the values in "id" (`expected`). * Missing from `actual`: "id" * Present in `actual`: "success", "message", "type" ── Failure ('test_thread.R:12:3'): thread ────────────────────────────────────── thm$metadata$test (`actual`) not equal to "test" (`expected`). `actual` is NULL `expected` is a character vector ('test') ── Failure ('test_thread.R:14:3'): thread ────────────────────────────────────── thd$deleted is not TRUE `actual` is NULL `expected` is a logical vector (TRUE) [ FAIL 30 | WARN 0 | SKIP 0 | PASS 33 ] Error: Test failures In addition: Warning messages: 1: In .Internal(gc(verbose, reset, full)) : closing unused connection 9 (https://api.openai.com/v1/chat/completions) 2: In .Internal(gc(verbose, reset, full)) : closing unused connection 5 (https://api.openai.com/v1/chat/completions) 3: In .Internal(gc(verbose, reset, full)) : closing unused connection 4 (https://api.openai.com/v1/chat/completions) Execution halted * checking PDF version of manual ... [3s/3s] OK * checking HTML version of manual ... [1s/1s] OK * checking for non-standard things in the check directory ... OK * checking for detritus in the temp directory ... OK * DONE Status: 1 ERROR, 2 NOTEs