You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
If user accidently uses golem::add_module("mod_99_tests", fct = "some_test_funs") this creates:
Probably unwanted module name "mod_mod_XXXX"; happens to me at least because I keep forgetting this behaviour after a while and then have to rename files and modules
That is because internally, the add_r_files() deletes the mod_-part but then cannot find the correct module name.
To Reproduce
Steps to reproduce the behavior:
golem::add_module("mod_99_tests", fct = "some_test_funs") ; fct or utils arguments must be provided
Expected behavior
Either fix the internal add_r_files() to correctly find the module name in this "buggy"/"esoteric" case or make a name syntax check explicit as one could assume that the user actually wanted to have module named "mod_" without double prefix "mod_mod".
I made a branch on my fork implementing the latter, as I found it difficult to believe that someone really wants a module named "mod_mod_XXX" but who knows.
session info
> sessioninfo::session_info()
─ Session info ────────────────────────────────────────────────────────────────────────────────────────────────────────
setting value
version R version 4.2.2 Patched (2022-11-10 r83330)
os Linux Mint 20
system x86_64, linux-gnu
ui RStudio
language en_US
collate en_US.UTF-8
ctype en_US.UTF-8
tz Europe/Berlin
date 2023-03-02
rstudio 2022.07.2+576 Spotted Wakerobin (desktop)
pandoc NA
ilyaZar
changed the title
Cannot find module name for "mod_mod_XXX" type module names [BUG] [FR]
Cannot find module name for "mod_mod_XXX" type module names [BUG]
Mar 2, 2023
Describe the bug
If user accidently uses
golem::add_module("mod_99_tests", fct = "some_test_funs")
this creates:That is because internally, the
add_r_files()
deletes themod_
-part but then cannot find the correct module name.To Reproduce
Steps to reproduce the behavior:
golem::add_module("mod_99_tests", fct = "some_test_funs")
;fct
orutils
arguments must be providedExpected behavior
Either fix the internal
add_r_files()
to correctly find the module name in this "buggy"/"esoteric" case or make a name syntax check explicit as one could assume that the user actually wanted to have module named "mod_" without double prefix "mod_mod".I made a branch on my fork implementing the latter, as I found it difficult to believe that someone really wants a module named "mod_mod_XXX" but who knows.
session info
The text was updated successfully, but these errors were encountered: