Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[R-package] Apply patch for R4.2 on Windows #4923

Merged
merged 1 commit into from
Jan 5, 2022

Conversation

shiyu1994
Copy link
Collaborator

Recently I've got an email from CRAN. LightGBM needs a small fix to work for updated R-devel/R 4.2 on Windows. I've applied the patch provided by CRAN in this PR.

Maybe we need a minor version update for this patch to update our CRAN package.

@jameslamb jameslamb changed the title Apply patch for R4.2 on Windows [R-package] Apply patch for R4.2 on Windows Jan 3, 2022
@jameslamb jameslamb added the fix label Jan 3, 2022
Copy link
Collaborator

@jameslamb jameslamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Linking #4881.

Thanks for this! It's nice that they sent you a patch directly. Could you please paste in the text of the email that CRAN sent, so we can include it in R-package/cran-comments.md during the next release?

I'll try testing master and this patch against the R Hub UCRT R-devel environment later today to confirm that that environment is sufficient to reproduce the issue, and that this patch is sufficient to fix it.

we need a minor version update for this patch to update our CRAN package.

This is another reason I'd like to see the full text of the email CRAN sent you. I'd like to know if they said anything about when we need to upload a patched version by.

Either way, I think the next release should be a major release, v4.0. There are significant breaking changes already on master, and per #3210 we release all components at the same time. See https://github.com/microsoft/LightGBM/releases/tag/untagged-cdc3eab37af1a2dcafa7 (this link is viewable by maintainers only).

image

To avoid the package being removed from CRAN, I think that after this patch is merged we should move forward with a 4.0 release. Other changes that are seem to still not be ready for review, like #4630 and #3234 can be in a future, v5.0, release.

@jameslamb
Copy link
Collaborator

jameslamb commented Jan 4, 2022

/gha run r-solaris

Workflow Solaris CRAN check has been triggered! 🚀
https://github.com/microsoft/LightGBM/actions/runs/1651725289

solaris-x86-patched: https://builder.r-hub.io/status/lightgbm_3.3.1.99.tar.gz-37a5f47dae964f62b290133de329b614
solaris-x86-patched-ods: https://builder.r-hub.io/status/lightgbm_3.3.1.99.tar.gz-a30c7e59814a4346a426c6fcfb42412e
Reports also have been sent to LightGBM public e-mail: https://yopmail.com?lightgbm_rhub_checks
Status: success ✔️.

@jameslamb
Copy link
Collaborator

jameslamb commented Jan 4, 2022

/gha run r-valgrind

Workflow R valgrind tests has been triggered! 🚀
https://github.com/microsoft/LightGBM/actions/runs/1651725635

Status: success ✔️.

@jameslamb
Copy link
Collaborator

I'll try testing master and this patch against the R Hub UCRT R-devel environment

Unfortunately it seems it's not possible to use R Hub to try to replicate whatever bug CRAN saw, because CRAN's patch for LightGBM is automatically applied on R Hub 😱 😱 😱

I built the package from master tonight and submitted it to the R Hub r-devel Windows UCRT environment.

code for submitting to R Hub (click me)
sh build-cran-package.sh
library(rhub)
package_tarball <- paste0("lightgbm_", readLines("VERSION.txt")[1], ".tar.gz")
rhub::check(
    path = package_tarball
    , email = # YOUR EMAIL HERE
    , check_args = "--as-cran"
    , platform = c(
        "windows-x86_64-devel"
    )
    , env_vars = c(
        "R_COMPILE_AND_INSTALL_PACKAGES" = "always"
    )
)

I was stunned to see the following in the build logs (link).

* installing *source* package 'lightgbm' ...
** applying installation-time patches
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3//patches/CRAN/lightgbm.diff'
Content length 712 bytes
==================================================
downloaded 712 bytes

patching file src/network/socket_wrapper.hpp
Applied installation-time patch https://www.r-project.org/nosvn/winutf8/ucrt3//patches/CRAN/lightgbm.diff and saved it as install_time_patches/lightgbm.diff in package installation
full logs (link)

NOTE: I removed 1000+ lines of Eigen warnings from this, since they're not specific to the UCRT build of R and since including them makes

Started by user r-hub Jenkins admin
Building remotely on windows-ucrt-80153829 (slave swarm windows-ucrt) in workspace C:\Users\rhub\workspace\lightgbm_3.3.1.99.tar.gz-63577fea21cc4cabb01ad36e1ba5941e
[lightgbm_3.3.1.99.tar.gz-63577fea21cc4cabb01ad36e1ba5941e] $ powershell.exe -NonInteractive -ExecutionPolicy ByPass "& 'C:\Users\rhub\AppData\Local\Temp\2\hudson4467135517948159470.ps1'"

StatusCode        : 200
StatusDescription : OK
Content           : {"status":"ok"}
RawContent        : HTTP/1.1 200 OK
                    Transfer-Encoding: chunked
                    Connection: keep-alive
                    Vary: Accept-Encoding
                    Content-Type: application/json
                    Date: Mon, 03 Jan 2022 19:05:50 GMT
                    Set-Cookie: r-hub frontend=s%3A7152f4e4...
Forms             : {}
Headers           : {[Transfer-Encoding, chunked], [Connection, keep-alive], [Vary, Accept-Encoding], [Content-Type, 
                    application/json]...}
Images            : {}
InputFields       : {}
Links             : {}
ParsedHtml        : System.__ComObject
RawContentLength  : 15

VERBOSE: Checking lightgbm_3.3.1.99.tar.gz-63577fea21cc4cabb01ad36e1ba5941e
>>>>>============== Creating new user
VERBOSE: Creating new user...
The command completed successfully.

Error:  Access is denied.

PSPath            : Microsoft.PowerShell.Core\FileSystem::C:\Users\USERAhtGikMudy\.R
PSParentPath      : Microsoft.PowerShell.Core\FileSystem::C:\Users\USERAhtGikMudy
PSChildName       : .R
PSDrive           : C
PSProvider        : Microsoft.PowerShell.Core\FileSystem
PSIsContainer     : True
Name              : .R
FullName          : C:\Users\USERAhtGikMudy\.R
Parent            : USERAhtGikMudy
Exists            : True
Root              : C:\
Extension         : .R
CreationTime      : 1/3/2022 8:05:58 PM
CreationTimeUtc   : 1/3/2022 7:05:58 PM
LastAccessTime    : 1/3/2022 8:05:58 PM
LastAccessTimeUtc : 1/3/2022 7:05:58 PM
LastWriteTime     : 1/3/2022 8:05:58 PM
LastWriteTimeUtc  : 1/3/2022 7:05:58 PM
Attributes        : Directory
Mode              : d-----
BaseName          : .R
Target            : {}
LinkType          : 

>>>>>============== Downloading and unpacking package file
VERBOSE: Downloading https://builder.r-hub.io/file/0cb8d8ce4460492aa281f5008b53621b
VERBOSE: GET https://builder.r-hub.io/file/0cb8d8ce4460492aa281f5008b53621b with 0-byte payload
VERBOSE: received 1473853-byte response of content type application/octet-stream
VERBOSE: Getting R version from symbolic name...
VERBOSE: Starting sub-process as new user...

setting _R_CHECK_FORCE_SUGGESTS_ to false
setting R_COMPILE_AND_INSTALL_PACKAGES to never
setting R_REMOTES_STANDALONE to true
setting R_REMOTES_NO_ERRORS_FROM_WARNINGS to true
setting R_COMPILE_AND_INSTALL_PACKAGES to always
> dir.create(Sys.getenv('R_LIBS_USER'), showWarnings = FALSE, recursive = TRUE)

setting _R_CHECK_FORCE_SUGGESTS_ to false
setting R_COMPILE_AND_INSTALL_PACKAGES to never
setting R_REMOTES_STANDALONE to true
setting R_REMOTES_NO_ERRORS_FROM_WARNINGS to true
setting R_COMPILE_AND_INSTALL_PACKAGES to always
> install.packages('BiocManager')
Installing package into 'C:/Users/USERAhtGikMudy/AppData/Local/R/win-library/4.2'
(as 'lib' is unspecified)
trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/BiocManager_1.30.16.zip'
Content length 328725 bytes (321 KB)
==================================================
downloaded 321 KB

package 'BiocManager' successfully unpacked and MD5 sums checked

    C:\Users\USERAhtGikMudy\AppData\Local\Temp\RtmpY9ri7t\downloaded_packages
The downloaded binary packages are in

>>>>>============== Querying package dependencies
setting _R_CHECK_FORCE_SUGGESTS_ to false
setting R_COMPILE_AND_INSTALL_PACKAGES to never
setting R_REMOTES_STANDALONE to true
setting R_REMOTES_NO_ERRORS_FROM_WARNINGS to true
setting R_COMPILE_AND_INSTALL_PACKAGES to always
'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details

replacement repositories:
    CRAN: https://cloud.r-project.org

> source('install-github.R')$value('r-lib/remotes@r-hub')
Downloading GitHub repo r-lib/remotes@r-hub
Running `R CMD build`...
* checking for file 'C:\Users\USERAhtGikMudy\AppData\Local\Temp\RtmpEdkfaU\remotes1398721c3fb0\r-lib-remotes-6e26f33/DESCRIPTION' ... OK
* checking DESCRIPTION meta-information ... OK
* checking for LF line-endings in source and make files and shell scripts
* checking for empty or unneeded directories
* building 'remotes_2.1.1.9000.tar.gz'
* preparing 'remotes':
(as 'lib' is unspecified)
Installing package into 'C:/Users/USERAhtGikMudy/AppData/Local/R/win-library/4.2'
'?repositories' for details
'getOption("repos")' replaces Bioconductor standard repositories, see

replacement repositories:
    CRAN: https://cloud.r-project.org

* installing *source* package 'remotes' ...
** using staged installation
** R
** inst
** byte-compile and prepare package for lazy loading
'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details

replacement repositories:
    CRAN: https://cloud.r-project.org

** help
*** installing help indices
** building package indices
'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details

replacement repositories:
    CRAN: https://cloud.r-project.org

** installing vignettes
** testing if installed package can be loaded from temporary location
'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details

    CRAN: https://cloud.r-project.org

replacement repositories:
'getOption("repos")' replaces Bioconductor standard repositories, see

'?repositories' for details
replacement repositories:
    CRAN: https://cloud.r-project.org

** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (remotes)

>>>>>============== Installing package dependencies
setting _R_CHECK_FORCE_SUGGESTS_ to false
setting R_COMPILE_AND_INSTALL_PACKAGES to never
setting R_REMOTES_STANDALONE to true
setting R_REMOTES_NO_ERRORS_FROM_WARNINGS to true
setting R_COMPILE_AND_INSTALL_PACKAGES to always
'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details

replacement repositories:
    CRAN: https://cloud.r-project.org

> remotes::install_deps('lightgbm_3.3.1.99.tar.gz',dependencies=TRUE,INSTALL_opts='--no-multiarch')
xfun       (NA -> 0.29  ) [CRAN]
glue       (NA -> 1.6.0 ) [CRAN]
magrittr   (NA -> 2.0.1 ) [CRAN]
stringi    (NA -> 1.7.6 ) [CRAN]
evaluate   (NA -> 0.14  ) [CRAN]
highr      (NA -> 0.9   ) [CRAN]
stringr    (NA -> 1.4.0 ) [CRAN]
yaml       (NA -> 2.2.1 ) [CRAN]
digest     (NA -> 0.6.29) [CRAN]
base64enc  (NA -> 0.1-3 ) [CRAN]
rlang      (NA -> 0.4.12) [CRAN]
fastmap    (NA -> 1.1.0 ) [CRAN]
htmltools  (NA -> 0.5.2 ) [CRAN]
processx   (NA -> 3.5.2 ) [CRAN]
R6         (NA -> 2.5.1 ) [CRAN]
ps         (NA -> 1.6.0 ) [CRAN]
crayon     (NA -> 1.4.2 ) [CRAN]
rprojroot  (NA -> 2.0.2 ) [CRAN]
cli        (NA -> 3.1.0 ) [CRAN]
desc       (NA -> 1.4.0 ) [CRAN]
rstudioapi (NA -> 0.13  ) [CRAN]
diffobj    (NA -> 0.3.5 ) [CRAN]
fansi      (NA -> 0.5.0 ) [CRAN]
rematch2   (NA -> 2.1.2 ) [CRAN]
tibble     (NA -> 3.1.6 ) [CRAN]
withr      (NA -> 2.4.3 ) [CRAN]
ellipsis   (NA -> 0.3.2 ) [CRAN]
lifecycle  (NA -> 1.0.1 ) [CRAN]
pillar     (NA -> 1.6.4 ) [CRAN]
pkgconfig  (NA -> 2.0.3 ) [CRAN]
vctrs      (NA -> 0.3.8 ) [CRAN]
utf8       (NA -> 1.2.2 ) [CRAN]
knitr      (NA -> 1.37  ) [CRAN]
jsonlite   (NA -> 1.7.2 ) [CRAN]
tinytex    (NA -> 0.36  ) [CRAN]
jquerylib  (NA -> 0.1.4 ) [CRAN]
brio       (NA -> 1.1.3 ) [CRAN]
callr      (NA -> 3.7.0 ) [CRAN]
pkgload    (NA -> 1.2.4 ) [CRAN]
praise     (NA -> 1.0.0 ) [CRAN]
waldo      (NA -> 0.3.1 ) [CRAN]
data.table (NA -> 1.14.2) [CRAN]
rmarkdown  (NA -> 2.11  ) [CRAN]
testthat   (NA -> 3.1.1 ) [CRAN]
Installing 44 packages: xfun, glue, magrittr, stringi, evaluate, highr, stringr, yaml, digest, base64enc, rlang, fastmap, htmltools, processx, R6, ps, crayon, rprojroot, cli, desc, rstudioapi, withr, diffobj, fansi, rematch2, tibble, ellipsis, lifecycle, pillar, pkgconfig, vctrs, utf8, knitr, jsonlite, tinytex, jquerylib, brio, callr, pkgload, praise, waldo, data.table, rmarkdown, testthat
Installing packages into 'C:/Users/USERAhtGikMudy/AppData/Local/R/win-library/4.2'
(as 'lib' is unspecified)
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/xfun_0.29.zip'
Content length 395727 bytes (386 KB)
downloaded 386 KB

==================================================
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/glue_1.6.0.zip'
Content length 163216 bytes (159 KB)
==================================================
downloaded 159 KB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/magrittr_2.0.1.zip'
Content length 224171 bytes (218 KB)
downloaded 218 KB

==================================================
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/stringi_1.7.6.zip'
 length 14153940 bytes (13.5 MB)
downloaded 13.5 MB

==================================================
trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/evaluate_0.14.zip'
Content length 76575 bytes (74 KB)
downloaded 74 KB

==================================================
trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/highr_0.9.zip'
Content length 46663 bytes (45 KB)
==================================================
downloaded 45 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/stringr_1.4.0.zip'
Content length 213484 bytes (208 KB)
==================================================
downloaded 208 KB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/yaml_2.2.1.zip'
Content length 112488 bytes (109 KB)
==================================================
downloaded 109 KB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/digest_0.6.29.zip'
Content length 192581 bytes (188 KB)
downloaded 188 KB

==================================================
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/base64enc_0.1-3.zip'
Content length 31951 bytes (31 KB)
==================================================
downloaded 31 KB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/rlang_0.4.12.zip'
 length 1115948 bytes (1.1 MB)
==================================================

downloaded 1.1 MB
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/fastmap_1.1.0.zip'
Content length 124952 bytes (122 KB)
==================================================

downloaded 122 KB
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/htmltools_0.5.2.zip'
Content length 338993 bytes (331 KB)
downloaded 331 KB

==================================================
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/processx_3.5.2.zip'
Content length 780596 bytes (762 KB)
==================================================
downloaded 762 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/R6_2.5.1.zip'
Content length 84182 bytes (82 KB)
==================================================
downloaded 82 KB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/ps_1.6.0.zip'
Content length 521705 bytes (509 KB)
==================================================
downloaded 509 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/crayon_1.4.2.zip'
Content length 156278 bytes (152 KB)
==================================================
downloaded 152 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/rprojroot_2.0.2.zip'
Content length 105149 bytes (102 KB)
==================================================
downloaded 102 KB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/cli_3.1.0.zip'
 length 1199441 bytes (1.1 MB)
==================================================
downloaded 1.1 MB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/desc_1.4.0.zip'
Content length 536076 bytes (523 KB)
downloaded 523 KB

==================================================
trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/rstudioapi_0.13.zip'
Content length 301719 bytes (294 KB)
==================================================
downloaded 294 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/withr_2.4.3.zip'
Content length 216695 bytes (211 KB)
downloaded 211 KB

==================================================
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/diffobj_0.3.5.zip'
Content length 992503 bytes (969 KB)
downloaded 969 KB

==================================================
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/fansi_0.5.0.zip'
Content length 210615 bytes (205 KB)
==================================================
downloaded 205 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/rematch2_2.1.2.zip'
Content length 47418 bytes (46 KB)
==================================================
downloaded 46 KB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/tibble_3.1.6.zip'
Content length 860100 bytes (839 KB)
==================================================
downloaded 839 KB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/ellipsis_0.3.2.zip'
Content length 39996 bytes (39 KB)
downloaded 39 KB

==================================================
trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/lifecycle_1.0.1.zip'
Content length 122780 bytes (119 KB)
downloaded 119 KB

==================================================
trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/pillar_1.6.4.zip'
Content length 1040395 bytes (1016 KB)
==================================================
downloaded 1016 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/pkgconfig_2.0.3.zip'
Content length 22334 bytes (21 KB)
==================================================
downloaded 21 KB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/vctrs_0.3.8.zip'
 length 1089674 bytes (1.0 MB)
downloaded 1.0 MB

==================================================
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/utf8_1.2.2.zip'
Content length 148573 bytes (145 KB)
==================================================
downloaded 145 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/knitr_1.37.zip'
 length 1469738 bytes (1.4 MB)
==================================================
downloaded 1.4 MB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/jsonlite_1.7.2.zip'
Content length 485687 bytes (474 KB)
downloaded 474 KB

==================================================
trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/tinytex_0.36.zip'
Content length 128731 bytes (125 KB)
==================================================
downloaded 125 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/jquerylib_0.1.4.zip'
Content length 525777 bytes (513 KB)
==================================================
downloaded 513 KB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/brio_1.1.3.zip'
Content length 37477 bytes (36 KB)
downloaded 36 KB
==================================================

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/callr_3.7.0.zip'
Content length 435838 bytes (425 KB)
==================================================
downloaded 425 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/pkgload_1.2.4.zip'
Content length 153851 bytes (150 KB)
==================================================
downloaded 150 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/praise_1.0.0.zip'
Content length 19732 bytes (19 KB)
==================================================
package 'xfun' successfully unpacked and MD5 sums checked
package 'glue' successfully unpacked and MD5 sums checked
package 'magrittr' successfully unpacked and MD5 sums checked
package 'stringi' successfully unpacked and MD5 sums checked
package 'evaluate' successfully unpacked and MD5 sums checked
package 'highr' successfully unpacked and MD5 sums checked
package 'stringr' successfully unpacked and MD5 sums checked
package 'yaml' successfully unpacked and MD5 sums checked
package 'digest' successfully unpacked and MD5 sums checked
package 'base64enc' successfully unpacked and MD5 sums checked
package 'rlang' successfully unpacked and MD5 sums checked
package 'fastmap' successfully unpacked and MD5 sums checked
package 'htmltools' successfully unpacked and MD5 sums checked
package 'processx' successfully unpacked and MD5 sums checked
package 'R6' successfully unpacked and MD5 sums checked
package 'ps' successfully unpacked and MD5 sums checked
package 'crayon' successfully unpacked and MD5 sums checked
package 'rprojroot' successfully unpacked and MD5 sums checked
package 'cli' successfully unpacked and MD5 sums checked
package 'desc' successfully unpacked and MD5 sums checked
package 'rstudioapi' successfully unpacked and MD5 sums checked
package 'withr' successfully unpacked and MD5 sums checked
package 'diffobj' successfully unpacked and MD5 sums checked
package 'fansi' successfully unpacked and MD5 sums checked
package 'rematch2' successfully unpacked and MD5 sums checked
package 'tibble' successfully unpacked and MD5 sums checked
package 'ellipsis' successfully unpacked and MD5 sums checked
package 'lifecycle' successfully unpacked and MD5 sums checked
package 'pillar' successfully unpacked and MD5 sums checked
package 'pkgconfig' successfully unpacked and MD5 sums checked
package 'vctrs' successfully unpacked and MD5 sums checked
package 'utf8' successfully unpacked and MD5 sums checked
package 'knitr' successfully unpacked and MD5 sums checked
package 'jsonlite' successfully unpacked and MD5 sums checked
package 'tinytex' successfully unpacked and MD5 sums checked
package 'jquerylib' successfully unpacked and MD5 sums checked
package 'brio' successfully unpacked and MD5 sums checked
package 'callr' successfully unpacked and MD5 sums checked
package 'pkgload' successfully unpacked and MD5 sums checked
package 'praise' successfully unpacked and MD5 sums checked
package 'waldo' successfully unpacked and MD5 sums checked
package 'data.table' successfully unpacked and MD5 sums checked
package 'rmarkdown' successfully unpacked and MD5 sums checked
package 'testthat' successfully unpacked and MD5 sums checked

The downloaded binary packages are in
    C:\Users\USERAhtGikMudy\AppData\Local\Temp\Rtmpotamkg\downloaded_packages

downloaded 19 KB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/waldo_0.3.1.zip'
Content length 96175 bytes (93 KB)
==================================================
downloaded 93 KB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/data.table_1.14.2.zip'
 length 2236379 bytes (2.1 MB)
==================================================
downloaded 2.1 MB

trying URL 'https://cloud.r-project.org/bin/windows/contrib/4.2/rmarkdown_2.11.zip'
 length 3659640 bytes (3.5 MB)
==================================================
downloaded 3.5 MB

trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3/CRAN/bin/windows/contrib/4.2/testthat_3.1.1.zip'
 length 2066010 bytes (2.0 MB)

==================================================
downloaded 2.0 MB

setting _R_CHECK_FORCE_SUGGESTS_ to false
setting R_COMPILE_AND_INSTALL_PACKAGES to never
setting R_REMOTES_STANDALONE to true
setting R_REMOTES_NO_ERRORS_FROM_WARNINGS to true
setting R_COMPILE_AND_INSTALL_PACKAGES to always
'getOption("repos")' replaces Bioconductor standard repositories, see

'?repositories' for details
replacement repositories:
    CRAN: https://cloud.r-project.org

* installing to library 'C:/Users/USERAhtGikMudy/AppData/Local/R/win-library/4.2'
** using staged installation
* installing *source* package 'lightgbm' ...
** applying installation-time patches
trying URL 'https://www.r-project.org/nosvn/winutf8/ucrt3//patches/CRAN/lightgbm.diff'
Content length 712 bytes
==================================================
downloaded 712 bytes

patching file src/network/socket_wrapper.hpp
Applied installation-time patch https://www.r-project.org/nosvn/winutf8/ucrt3//patches/CRAN/lightgbm.diff and saved it as install_time_patches/lightgbm.diff in package installation

checking whether MM_PREFETCH works...yes
checking whether MM_MALLOC works...yes
** libs
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c boosting/boosting.cpp -o boosting/boosting.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c boosting/gbdt.cpp -o boosting/gbdt.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c boosting/gbdt_model_text.cpp -o boosting/gbdt_model_text.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c boosting/gbdt_prediction.cpp -o boosting/gbdt_prediction.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c boosting/prediction_early_stop.cpp -o boosting/prediction_early_stop.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c io/bin.cpp -o io/bin.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c io/config.cpp -o io/config.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c io/config_auto.cpp -o io/config_auto.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c io/dataset.cpp -o io/dataset.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c io/dataset_loader.cpp -o io/dataset_loader.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c io/file_io.cpp -o io/file_io.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c io/json11.cpp -o io/json11.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c io/metadata.cpp -o io/metadata.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c io/parser.cpp -o io/parser.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c io/train_share_states.cpp -o io/train_share_states.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c io/tree.cpp -o io/tree.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c metric/dcg_calculator.cpp -o metric/dcg_calculator.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c metric/metric.cpp -o metric/metric.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c objective/objective_function.cpp -o objective/objective_function.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c network/ifaddrs_patch.cpp -o network/ifaddrs_patch.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c network/linker_topo.cpp -o network/linker_topo.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c network/linkers_mpi.cpp -o network/linkers_mpi.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c network/linkers_socket.cpp -o network/linkers_socket.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c network/network.cpp -o network/network.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c treelearner/data_parallel_tree_learner.cpp -o treelearner/data_parallel_tree_learner.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c treelearner/feature_parallel_tree_learner.cpp -o treelearner/feature_parallel_tree_learner.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c treelearner/gpu_tree_learner.cpp -o treelearner/gpu_tree_learner.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c treelearner/linear_tree_learner.cpp -o treelearner/linear_tree_learner.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c treelearner/serial_tree_learner.cpp -o treelearner/serial_tree_learner.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c treelearner/tree_learner.cpp -o treelearner/tree_learner.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c treelearner/voting_parallel_tree_learner.cpp -o treelearner/voting_parallel_tree_learner.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c c_api.cpp -o c_api.o
g++  -std=gnu++11 -I"C:/PROGRA~1/R/R-devel/include" -DNDEBUG -I./include -DEIGEN_MPL2_ONLY -DMM_PREFETCH=1 -DMM_MALLOC=1 -DUSE_SOCKET -DLGB_R_BUILD    -I"C:/rtools42/x86_64-w64-mingw32.static.posix/include"  -fopenmp -pthread   -O2 -Wall  -mfpmath=sse -msse2 -mstackrealign -fexceptions  -c lightgbm_R.cpp -o lightgbm_R.o
g++ -shared -s -static-libgcc -o lightgbm.dll lightgbm-win.def boosting/boosting.o boosting/gbdt.o boosting/gbdt_model_text.o boosting/gbdt_prediction.o boosting/prediction_early_stop.o io/bin.o io/config.o io/config_auto.o io/dataset.o io/dataset_loader.o io/file_io.o io/json11.o io/metadata.o io/parser.o io/train_share_states.o io/tree.o metric/dcg_calculator.o metric/metric.o objective/objective_function.o network/ifaddrs_patch.o network/linker_topo.o network/linkers_mpi.o network/linkers_socket.o network/network.o treelearner/data_parallel_tree_learner.o treelearner/feature_parallel_tree_learner.o treelearner/gpu_tree_learner.o treelearner/linear_tree_learner.o treelearner/serial_tree_learner.o treelearner/tree_learner.o treelearner/voting_parallel_tree_learner.o c_api.o lightgbm_R.o -fopenmp -pthread -lws2_32 -lIphlpapi -LC:/rtools42/x86_64-w64-mingw32.static.posix/lib/x64 -LC:/rtools42/x86_64-w64-mingw32.static.posix/lib -LC:/PROGRA~1/R/R-devel/bin/x64 -lR
'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details

replacement repositories:
    CRAN: https://cloud.r-project.org

'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details
replacement repositories:
    CRAN: https://cloud.r-project.org


'getOption("repos")' replaces Bioconductor standard repositories, see
replacement repositories:

    CRAN: https://cloud.r-project.org

'?repositories' for details

'getOption("repos")' replaces Bioconductor standard repositories, see
replacement repositories:

    CRAN: https://cloud.r-project.org
'?repositories' for details

installing to C:/Users/USERAhtGikMudy/AppData/Local/R/win-library/4.2/00LOCK-lightgbm/00new/lightgbm/libs/x64
** R
** data
** demo
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
*** copying figures
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* MD5 sums
packaged installation of 'lightgbm' as lightgbm_3.3.1.99.zip
* DONE (lightgbm)

>>>>>============== Running R CMD check
setting _R_CHECK_FORCE_SUGGESTS_ to false
setting R_COMPILE_AND_INSTALL_PACKAGES to never
setting R_REMOTES_STANDALONE to true
setting R_REMOTES_NO_ERRORS_FROM_WARNINGS to true
setting R_COMPILE_AND_INSTALL_PACKAGES to always
'getOption("repos")' replaces Bioconductor standard repositories, see
'?repositories' for details

replacement repositories:
    CRAN: https://cloud.r-project.org

* using log directory 'C:/Users/USERAhtGikMudy/lightgbm.Rcheck'
* using R Under development (unstable) (2021-12-17 r81389 ucrt)
* using platform: x86_64-w64-mingw32 (64-bit)
* using session charset: UTF-8
* using option '--as-cran'
* checking for file 'lightgbm/DESCRIPTION' ... OK
* checking extension type ... Package
* this is package 'lightgbm' version '3.3.1.99'
* package encoding: UTF-8
* checking CRAN incoming feasibility ... Note_to_CRAN_maintainers
Maintainer: 'Yu Shi <[email protected]>'
* 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 whether package 'lightgbm' can be installed ... OK
* checking installed package size ... OK
* checking package directory ... OK
* checking for future file timestamps ... OK
* checking 'build' directory ... OK
* checking DESCRIPTION meta-information ... OK
* 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 ... OK
* checking whether the package can be loaded with stated dependencies ... OK
* checking whether the package can be unloaded cleanly ... OK
* checking whether the namespace can be loaded with stated dependencies ... OK
* checking whether the namespace can be unloaded cleanly ... OK
* checking loading without being on the library search path ... 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 ... OK
* checking Rd files ... 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 contents of 'data' directory ... OK
* checking data for non-ASCII characters ... OK
* checking data for ASCII and uncompressed saves ... OK
* checking line endings in shell scripts ... OK
* checking line endings in C/C++/Fortran sources/headers ... OK
* checking line endings in Makefiles ... OK
* checking compilation flags in Makevars ... OK
* checking for GNU extensions in Makefiles ... OK
* checking for portable use of $(BLAS_LIBS) and $(LAPACK_LIBS) ... OK
* checking use of PKG_*FLAGS in Makefiles ... OK
* checking use of SHLIB_OPENMP_*FLAGS in Makefiles ... OK
* checking pragmas in C/C++ headers and code ... OK
* checking compilation flags used ... OK
* checking compiled code ... OK
* checking installed files from 'inst/doc' ... OK
* checking files in 'vignettes' ... OK
* checking examples ... OK
* checking examples with --run-donttest ... OK
* checking for unstated dependencies in 'tests' ... OK
* checking tests ...
  Running 'testthat.R' [40s]
 OK
* checking for unstated dependencies in vignettes ... OK
* checking package vignettes in 'inst/doc' ... OK
* checking re-building of vignette outputs ... OK
* checking PDF version of manual ... OK
* checking for non-standard things in the check directory ... OK
* checking for detritus in the temp directory ... NOTE
Found the following files/directories:
  'lastMiKTeXException'
* DONE

Status: 1 NOTE
See
  'C:/Users/USERAhtGikMudy/lightgbm.Rcheck/00check.log'
for details.

>>>>>============== Done with R CMD check
+R-HUB-R-HUB-R-HUB Done.

VERBOSE: Saving artifacts
VERBOSE: Cleaning up, deleting files and user
>>>>>============== Cleaning up files and user

INFO: No tasks running with the specified criteria.
The command completed successfully.

SSH: Connecting from host [win2022]
SSH: Connecting with configuration [files] ...
SSH: Disconnecting configuration [files] ...
SSH: Transferred 6 file(s)
Build step 'Send files or execute commands over SSH' changed build result to SUCCESS
Pinging https://builder.r-hub.io/build/SUCCESS/lightgbm_3.3.1.99.tar.gz-63577fea21cc4cabb01ad36e1ba5941e/2022-01-03T19:21:38Z
{"status":"ok"}
Finished: SUCCESS

@StrikerRUS
Copy link
Collaborator

CRAN's patch for LightGBM is automatically applied on R Hub

I'm really impressed!

OK, great! Then this fact removes urgency for releasing new version of LightGBM, right?

@jameslamb
Copy link
Collaborator

this fact removes urgency for releasing new version of LightGBM, right?

I'm not sure. R Hub is just a testing service, so the fact that patches are automatically applied there isn't necessarily informative about how CRAN will handle such patches.

The official announcement from CRAN that I linked to in #4881 (link) says the following

The change will, however, require some cooperation from some package authors. ...authors of packages using native (C, C++ or Fortran) code should read the following lines. Some of them will have to update their packages, but in most cases they may use patches created by Tomas Kalibera and/or receive more advice from Tomas Kalibera or Uwe Ligges

Authors have been invited since March 2021 to adopt these patches

After the switch, R-devel will be automatically installing patches for CRAN and required Bioconductor packages at installation time, as “ucrt3” does now. This feature will be used temporarily to give package authors more time to fix their packages. Eventually, patching a package at installation time may be turned into a warning and the patches may be removed.

This leads me to believe we don't need to act urgently, but CRAN is being intentionally vague here about when they'll force us to create a new release. I'd like to see the full text of the email(s) @shiyu1994 received from CRAN to see if they gave any indication about how urgently we need to do a new release.

Either way....I support these changes if they pass they solaris and valgrind checks, and I'm ok with not doing a new release just because of this if CRAN isn't forcing us to do so.

@jameslamb jameslamb self-requested a review January 4, 2022 02:46
Copy link
Collaborator

@jameslamb jameslamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works for me as long as the valgrind and solaris jobs succeed, thanks!

@shiyu1994
Copy link
Collaborator Author

The full text of the email from CRAN is pasted below.

Dear maintainers,

This concerns the CRAN packages

Cairo cepreader gpboost httpuv ipaddress lightgbm proj4 prophet
RcppCWB RcppParallel RDieHarder re2 redux rgeolocate RGtk2 tth
udunits2 unrtf

maintained by one of you:

Andreas Blaette [email protected]: RcppCWB
David Hall [email protected]: ipaddress
Dirk Eddelbuettel [email protected]: RDieHarder
Fabio Sigrist [email protected]: gpboost
Friedrich Leisch [email protected]: tth
Girish Palya [email protected]: re2
James Hiebert [email protected]: udunits2
Jari Oksanen [email protected]: cepreader
Kevin Ushey [email protected]: RcppParallel
ORPHANED: RGtk2
Os Keyes [email protected]: rgeolocate
Rich FitzJohn [email protected]: redux
Sean Taylor [email protected]: prophet
Simon Urbanek [email protected]: proj4
Simon Urbanek [email protected]: Cairo
Winston Chang [email protected]: httpuv
Yu Shi [email protected]: lightgbm

your packages need to be updated for R-devel/R 4.2 to work on Windows,
following the recent switch to UCRT and Rtools42.

Sorry for the group message, please feel free to respond individually
regarding your package or ask specifically about what needs to be fixed.

I've created patches for you, so please review them and fix your packages:

https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fsvn.r-project.org%2FR-dev-web%2Ftrunk%2FWindowsBuilds%2Fwinutf8%2Fucrt3%2Fr_packages%2Fpatches%2FCRAN%2F&amp;data=04%7C01%7Cyushi2%40microsoft.com%7C8e6c353d1a8842c81eeb08d9bef5d835%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637750786169848244%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&amp;sdata=rFGf7Y4Dvo6g1kzV%2BeAJDLGm1TUtzQsLsavElTw6H1U%3D&amp;reserved=0

You can apply them as follows

tar xfz package_1.0.0.tar.gz

wget
https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fsvn.r-project.org%2FR-dev-web%2Ftrunk%2FWindowsBuilds%2Fwinutf8%2Fucrt3%2Fr_packages%2Fpatches%2FCRAN%2Fpackage.diff&amp;data=04%7C01%7Cyushi2%40microsoft.com%7C8e6c353d1a8842c81eeb08d9bef5d835%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637750786169848244%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&amp;sdata=iyTjhoqvzj3IbQ8HGCZeh1IQl34FAGpIdVyZWkzNvO0%3D&amp;reserved=0

patch --binary < package.diff

These patches are currently automatically applied by R-devel on Windows
at installation time, which makes most of your packages pass their
checks (as OK or NOTE), but please check your results carefully and
carefully review the patches. Usually these changes were because of
newer GCC or newer MinGW in the toolchain, but some for other reasons,
and some of them will definitely have to be improved so that the package
keeps building also for older versions of R using Rtools40. We have only
been testing the patches with UCRT (and Rtools42) on Windows.

For more information, please see

https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdeveloper.r-project.org%2FBlog%2Fpublic%2F2021%2F12%2F07%2Fupcoming-changes-in-r-4.2-on-windows%2F&amp;data=04%7C01%7Cyushi2%40microsoft.com%7C8e6c353d1a8842c81eeb08d9bef5d835%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637750786169848244%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&amp;sdata=SY77zgtbDbHvTxTgPLOoe%2Fw5OZDhXvJoxpVOoEaKoYo%3D&amp;reserved=0
https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdeveloper.r-project.org%2FWindowsBuilds%2Fwinutf8%2Fucrt3%2Fhowto.html&amp;data=04%7C01%7Cyushi2%40microsoft.com%7C8e6c353d1a8842c81eeb08d9bef5d835%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637750786169848244%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&amp;sdata=dlVJ4nhQlmDPd56bHoVsWZuRfrUUorvOWxoUTmVDM%2Bg%3D&amp;reserved=0

Once you add your patches/fix the issues, your package will probably
show a warning during R CMD check (as patching would be attempted to be
applied again). That's ok, at that point please let me know and I will
remove my patch from the repository of automatically applied patches.

If you end up just applying the patch as is, there is probably no need
testing on your end, but you can do so using Winbuilder, r-hub, github
actions (e.g. https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fkalibera%2Fucrt3&amp;data=04%7C01%7Cyushi2%40microsoft.com%7C8e6c353d1a8842c81eeb08d9bef5d835%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637750786169848244%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&amp;sdata=msqoPzqDStlAUn%2Bb6gGevwFPD%2FaNL5dTxiNud2Sqzy8%3D&amp;reserved=0).

If you wanted to test locally on your Windows machine and do not have a
UCRT version of R-devel yet, please uninstall your old version of
R-devel, delete the old library used with that, install a new UCRT
version of R-devel , and install Rtools42. You can keep Rtools40
installed if you need it with R 4.1 or earlier.

Currently, the new R-devel can be downloaded from
https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.r-project.org%2Fnosvn%2Fwinutf8%2Fucrt3%2Fweb%2Frdevel.html&amp;data=04%7C01%7Cyushi2%40microsoft.com%7C8e6c353d1a8842c81eeb08d9bef5d835%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637750786169848244%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&amp;sdata=0hCwONzLmcW0GIXNqiOZQEIuhNA%2BjHhQvXsofs8J98o%3D&amp;reserved=0

And Rtools42 from
https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.r-project.org%2Fnosvn%2Fwinutf8%2Fucrt3%2Fweb%2Frtools.html&amp;data=04%7C01%7Cyushi2%40microsoft.com%7C8e6c353d1a8842c81eeb08d9bef5d835%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637750786169848244%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&amp;sdata=WLWLbOyQKbaYz8gkfKz2sqoGknjIOtl1aGAhUF%2Bpylg%3D&amp;reserved=0

If you end up testing locally, you can use R_INSTALL_TIME_PATCHES
environment variable to disable the automated patching, see the "howto"
document above. That way you could also see what the original issue was
causing.

If you wanted to find libraries to link for yourself, e.g. in a newer
version of your package, please look for "Using findLinkingOrder with
Rtools42 (tiff package example)" in the "howto" document above. I
created the patches for you manually before we finished this script, so
you may be able to create a shorter version using it, but - it's
probably not worth the effort.

If you wanted to try in a virtual machine, but did not have a license,
you can use also an automated setup of a free trial VM from
https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdeveloper.r-project.org%2FBlog%2Fpublic%2F2021%2F03%2F18%2Fvirtual-windows-machine-for-checking-r-packages&amp;data=04%7C01%7Cyushi2%40microsoft.com%7C8e6c353d1a8842c81eeb08d9bef5d835%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637750786169848244%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&amp;sdata=aFFQYuC9CoBwBiLgZHi8N3yUnSiHu5Xtdqb2YBiMIHQ%3D&amp;reserved=0

(but that needs a very good and un-metered network connection to install)

Please let us know if you have any questions.

Thanks,
Tomas & Uwe

@shiyu1994
Copy link
Collaborator Author

And in another email, it is said that we'd better do it in early Jaunuary.

Dear Tomas, dear Uwe,

a big thank you for your extraordinary support und the detailed instructions.

I have just released a new RcppCWB version (v0.4.4) yet did not implement UCRT-related updates. Now my schedule before Christmas is quite busy ... Thus my question is when do you want to see the updates on CRAN?

As always, the sooner the better.
But if you do not manage to get it to CRAN before CRAN closes for its
winter vacation, early January will suffice.

Best,
Uwe Ligges

@shiyu1994
Copy link
Collaborator Author

shiyu1994 commented Jan 4, 2022

early January will suffice.

In that case, maybe we still need a minor version release first? Or shall we make it 4.0?

@jameslamb
Copy link
Collaborator

In that case, maybe we still need a minor version release first? Or shall we make it 4.0?

Thanks for sharing that! Based on that reaction from CRAN asking for a new release in January, I think we should proceed with BOTH...put up a new release AND make that a 4.0. Since there are so many significant breaking changes already on master.

@StrikerRUS
Copy link
Collaborator

Unfortunately it seems it's not possible to use R Hub to try to replicate whatever bug CRAN saw, because CRAN's patch for LightGBM is automatically applied on R Hub

R Hub is just a testing service, so the fact that patches are automatically applied there isn't necessarily informative about how CRAN will handle such patches.

Now we know that auto-patching is done by R-devel

These patches are currently automatically applied by R-devel on Windows
at installation time,

and we can disable this by R_INSTALL_TIME_PATCHES:

If you end up testing locally, you can use R_INSTALL_TIME_PATCHES
environment variable to disable the automated patching

@StrikerRUS
Copy link
Collaborator

I think we can have a new 3.3.2 LightGBM patch release with only this PR included with the aim to not being dropped from CRAN for our slowness.

@jameslamb
Copy link
Collaborator

I think we can have a new 3.3.2 LightGBM patch release with only this PR included with the aim to not being dropped from CRAN

I totally support that. Just thought from the discussion in #3210 that you felt strongly that all components for LightGBM should always be released together.

@StrikerRUS
Copy link
Collaborator

Just thought from the discussion in #3210 that you felt strongly that all components for LightGBM should always be released together.

Yes... I still have the same position.

I mean, we will have 3.3.2 release with our standard releasing process uploading all generated artifacts to all distributing channels (e.g., there will be 3.3.2 release at PyPI and Homebrew).

@jameslamb
Copy link
Collaborator

we will have 3.3.2 release with our standard releasing process

I see, ok. I totally support that, but will definitely need your help with it. As I understand it a lot of LightGBM's release process uses automation that pulls from master, so I'm not sure how to re-use that automation to release from a different branch.

@StrikerRUS
Copy link
Collaborator

I hope there won't be a lot of changes in CI. 🙏

@shiyu1994 shiyu1994 merged commit 100a10d into microsoft:master Jan 5, 2022
@github-actions
Copy link

This pull request has been automatically locked since there has not been any recent activity since it was closed. To start a new related discussion, open a new issue at https://github.com/microsoft/LightGBM/issues including a reference to this.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants