Skip to content

[R-package] CRAN warning about use of vsprintf() #5618

Closed

Description

@shiyu1994

Description

On Dec 3rd, I received the following email from CRAN

[????????? ripley@stats.ox.ac.uk ????????? [https://aka.ms/LearnAboutSenderIdentification?????????????]](https://aka.ms/LearnAboutSenderIdentification?????????????%5d)

Dear maintainer,

Please see the problems shown on
<https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fcran.r-project.org%2Fweb%2Fchecks%2Fcheck_results_lightgbm.html&data=05%7C01%7Cyushi2%40microsoft.com%7C6bbf2f089d94451d7c7208dad50de56c%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C638056552948658112%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=QhvwqS7zT0kfP%2FUXkBOB00Y%2FTm%2FRzCVKSa3FfBl8w1I%3D&reserved=0>.

Please correct before 2022-12-17 to safely retain your package on CRAN.

Do remember to look at the 'Additional issues'.

The CRAN Team

We need to fix the issue before 17th Dec.

Activity

  1. guolinke commented on Dec 4, 2022

    @guolinke
    Collaborator
  2. jameslamb commented on Dec 4, 2022

    @jameslamb
    Member

    Thanks @shiyu1994 ! I think this is fixed by #5561 , just need to release the changes. I will put up a release PR when I'm back from traveling on December 6.

  3. changed the title [-][CRAN] CRAN package warning pending for fix[/-] [+][R-package] CRAN warning about use of `vsprintf()`[/+] on Dec 6, 2022
  4. jameslamb commented on Dec 6, 2022

    @jameslamb
    Member

    I've copied the exact text of the CRAN warnings here. In the future @shiyu1994 , please do that so that these issues can be found from search engines. That way, other projects getting the same warning from CRAN can learn from how we fixed it here in LightGBM.

    Result: WARN
    File ‘lightgbm/libs/lightgbm.so’:
    Found ‘__vsprintf_chk’, possibly from ‘vsprintf’ (C)
    Objects: ‘boosting/boosting.o’, ‘boosting/gbdt.o’,
    ‘boosting/gbdt_model_text.o’, ‘boosting/prediction_early_stop.o’,
    ‘io/bin.o’, ‘io/config.o’, ‘io/config_auto.o’, ‘io/dataset.o’,
    ‘io/dataset_loader.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/linkers_socket.o’,
    ‘network/network.o’, ‘treelearner/data_parallel_tree_learner.o’,
    ‘treelearner/feature_parallel_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’
    Compiled code should not call entry points which might terminate R nor
    write to stdout/stderr instead of to the console, nor use Fortran I/O
    nor system RNGs nor [v]sprintf.
    See ‘Writing portable packages’ in the ‘Writing R Extensions’ manual.
    Flavors: r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-gcc

    and

    Check: compiled code
    Result: WARN
    File ‘lightgbm/libs/lightgbm.so’:
    Found ‘vsprintf’, possibly from ‘vsprintf’ (C)
    Objects: ‘boosting/boosting.o’, ‘boosting/gbdt.o’,
    ‘boosting/gbdt_model_text.o’, ‘boosting/prediction_early_stop.o’,
    ‘io/bin.o’, ‘io/config.o’, ‘io/config_auto.o’, ‘io/dataset.o’,
    ‘io/dataset_loader.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/linkers_socket.o’,
    ‘network/network.o’, ‘treelearner/data_parallel_tree_learner.o’,
    ‘treelearner/feature_parallel_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’
    Compiled code should not call entry points which might terminate R nor
    write to stdout/stderr instead of to the console, nor use Fortran I/O
    nor system RNGs nor [v]sprintf.
    See ‘Writing portable packages’ in the ‘Writing R Extensions’ manual.
    Flavor: r-devel-linux-x86_64-fedora-clang

  5. shiyu1994 commented on Dec 7, 2022

    @shiyu1994
    CollaboratorAuthor

    @jameslamb Thanks for the reminder.

  6. jameslamb commented on Dec 22, 2022

    @jameslamb
    Member

    v3.3.4 is now on CRAN (#5619). It's passing all CRAN checks without warnings.

    https://cran.r-project.org/web/checks/check_results_lightgbm.html

    So this is resolved. Thanks for letting us know so quickly @shiyu1994 !

  7. github-actions commented on Aug 19, 2023

    @github-actions
    Contributor

    This issue 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.

  8. locked as resolved and limited conversation to collaborators on Aug 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions