Skip to content

btw_tools errors: trailing garbage and premature EOF #174

@bianchenhao

Description

@bianchenhao

Recently, when I use btw app with claude 4.6 opus by my own gateway, it raised errors below several times:

**An error occurred:**
parse error: trailing garbage
          start": 380, "line_end": 440}{"_intent": "Read the do_fork_s
                     (right here) ------^
**An error occurred:**
parse error: premature EOF
                                       {"_intent": "Implement the fork
                     (right here) ------^
> sessionInfo()
R version 4.3.2 (2023-10-31)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 22.04.3 LTS

Matrix products: default
BLAS:   /usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3 
LAPACK: /usr/lib/x86_64-linux-gnu/openblas-pthread/libopenblasp-r0.3.20.so;  LAPACK version 3.10.0

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
 [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8   
 [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

time zone: Etc/UTC
tzcode source: system (glibc)

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] biliauth_0.1.0       S7_0.2.0             coro_1.1.0          
 [4] dplyr_1.1.4          paws.storage_0.9.0   rlang_1.1.6         
 [7] jsonlite_2.0.0       base64enc_0.1-3      shinyjs_2.1.0       
[10] future_1.68.0        promises_1.3.3       pool_1.0.4          
[13] RMariaDB_1.3.1       DBI_1.2.3            shinychat_0.3.0.9000
[16] bslib_0.8.0          shiny_1.11.1         ellmer_0.4.0.9000   
[19] btw_1.1.0.9000       callr_3.7.3         

loaded via a namespace (and not attached):
 [1] rappdirs_0.3.3    sass_0.4.9        generics_0.1.4    paws.common_0.8.8
 [5] listenv_0.9.1     hms_1.1.3         digest_0.6.34     magrittr_2.0.3   
 [9] timechange_0.3.0  fastmap_1.2.0     processx_3.8.3    brio_1.1.4       
[13] ps_1.7.6          codetools_0.2-19  httr2_1.2.1       jquerylib_0.1.4  
[17] cli_3.6.5         crayon_1.5.2      parallelly_1.45.1 commonmark_2.0.0 
[21] bit64_4.0.5       withr_3.0.2       cachem_1.1.0      tools_4.3.2      
[25] parallel_4.3.2    memoise_2.0.1     httpuv_1.6.13     globals_0.18.0   
[29] curl_7.0.0        vctrs_0.6.5       R6_2.6.1          mime_0.13        
[33] lubridate_1.9.3   lifecycle_1.0.4   fs_1.6.6          bit_4.0.5        
[37] pkgconfig_2.0.3   pillar_1.11.0     later_1.4.2       glue_1.8.0       
[41] Rcpp_1.1.0        xfun_0.41         tidyselect_1.2.1  tibble_3.3.0     
[45] knitr_1.45        rstudioapi_0.17.1 xtable_1.8-4      htmltools_0.5.8.1
[49] compiler_4.3.2   

gateway:

client1 = ellmer::chat_claude(
    base_url = "http://llmapi.bilibili.co/v1",
    model = 'claude-4.6-opus',
    credentials = function() 'bsk-xxxx',
  )

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions