Skip to content

Commit

Permalink
fix: get_r_version string conversion not necessary
Browse files Browse the repository at this point in the history
  • Loading branch information
paulmueller committed Oct 18, 2024
1 parent eacf2a6 commit 23f0aa2
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
0.62.3
- fix: get_r_version string conversion not necessary
0.62.2
- fix: use full path to R executable when running lme4 analysis in rsetup
- enh: properly catch CalledProcessError in run_command
Expand Down
4 changes: 2 additions & 2 deletions dclab/lme4/rsetup.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ def get_r_version():
require_r()
cmd = (str(get_r_path()), "--version")
logger.debug(f"Looking for R version with: {' '.join(cmd)}")
tmp = run_command(cmd, stderr=sp.STDOUT)
r_version = tmp.decode("ascii", "ignore").split(os.linesep)
r_version = run_command(cmd, stderr=sp.STDOUT)
r_version = r_version.split(os.linesep)
if r_version[0].startswith("WARNING"):
r_version = r_version[1]
else:
Expand Down
6 changes: 6 additions & 0 deletions tests/test_lme4.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,12 @@ def test_fail_get_non_existent_data():
rlme4.get_feature_data(group="control", repetition=3)


@pytest.mark.xfail(IS_ON_GITHUB_WINDOWS,
reason="https://github.com/astamm/nloptr/issues/115")
def test_get_r_version():
assert rsetup.get_r_version()


@pytest.mark.xfail(IS_ON_GITHUB_WINDOWS,
reason="https://github.com/astamm/nloptr/issues/115")
def test_glmer_basic_larger():
Expand Down

0 comments on commit 23f0aa2

Please sign in to comment.