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 sharp r6 #1417

Merged
merged 108 commits into from
Jul 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
108 commits
Select commit Hold shift + click to select a range
64b2904
Added authors to _pkgdown.yml
PavelBal Mar 1, 2024
c3aa982
- Exchange rClr for rSharp as dependency
PavelBal Mar 1, 2024
cb252aa
Docs
PavelBal Mar 1, 2024
a9ff16f
Replace all calls to rClr by calls to rShapr
PavelBal Mar 1, 2024
afa99c5
Replace `clrLoadAssembly` by `loadAssembly`
PavelBal Mar 1, 2024
5e6ef83
- Replace `rClrCallStatic` by `callStatic`
PavelBal Mar 1, 2024
0900614
`getEnumNames`
PavelBal Mar 1, 2024
d17ffd0
Use correct package reference in test
PavelBal Mar 5, 2024
7726ebc
- Remove enc2utf, as conversion is done in rSharp
PavelBal Mar 5, 2024
c4ea6f6
Moved some wrappers to NetObject in rSharp
PavelBal Mar 5, 2024
ec28d58
Loading package works
PavelBal Mar 5, 2024
4f3f2b5
.wrapProperty
PavelBal Mar 6, 2024
d2f0e17
Replace all clrGet
PavelBal Mar 6, 2024
44901ff
Replace all clrSet
PavelBal Mar 6, 2024
904681c
Replace clrCall
PavelBal Mar 7, 2024
2cfd437
Replace clrNew
PavelBal Mar 7, 2024
ea2db97
DotNetWrapper expects a NetObject and not a pointer.
PavelBal Mar 7, 2024
7f40e86
Remove ref
PavelBal Mar 7, 2024
c2e4b54
Fix all initilialize
PavelBal Mar 7, 2024
6b78e5b
Remove direct pointers
PavelBal Mar 7, 2024
58777e4
Styler
PavelBal Mar 7, 2024
4698e28
Documentation
PavelBal Mar 7, 2024
98da2e8
Correct calling of private print methods
PavelBal Mar 8, 2024
379610f
Prepend '.' to wrapPropertyReadOnly
PavelBal Mar 8, 2024
533aa3d
Prepend '.' to throwPropertyISREadONly
PavelBal Mar 8, 2024
cbd6af7
Fix test for dotNetWrapper
PavelBal Mar 8, 2024
ddf7295
Fix clrGetType to getType
PavelBal Mar 11, 2024
9d5057e
use NPOI for .NET Core
rwmcintosh Mar 11, 2024
9e35238
Fix .wrapProperty
PavelBal Mar 12, 2024
8e8e505
Fix print calls in DataCombined
PavelBal Mar 12, 2024
8334e63
Update snapshots for the use with the latest TLF
PavelBal Mar 12, 2024
9b77397
Remove unnecessary libs
PavelBal Mar 12, 2024
9e9bf0d
Docs
PavelBal Mar 12, 2024
11fc4d2
Merge branch 'develop' of https://github.com/Open-Systems-Pharmacolog…
PavelBal May 22, 2024
4ac9572
Adjust README.Rmd
PavelBal May 22, 2024
bcc398f
Remove appveyor for R 3.6
PavelBal May 22, 2024
3c5cd80
Skip individual and simulation tests
PavelBal May 22, 2024
e78a3f8
Moved a test using population creation from simulation-results test
PavelBal May 22, 2024
f557c7e
Merge branch 'develop' of https://github.com/Open-Systems-Pharmacolog…
PavelBal May 22, 2024
19fe1fa
Update snapshots.
PavelBal May 22, 2024
6c5fd9f
Delete "install-packages.R"
PavelBal May 22, 2024
0f9dd55
Update documentation
PavelBal May 22, 2024
568deb5
Move vignettes that use PK-Sim functions to WIP folder
PavelBal May 22, 2024
63dcd58
Fixed author roles
PavelBal May 22, 2024
3259623
Fix role
PavelBal May 22, 2024
052bf1d
unzip rSharp archive before installing it
Felixmil May 23, 2024
fd01545
correct typo
Felixmil May 23, 2024
3b829cd
delete and ignore tests/testthat/*.pdf
Felixmil May 23, 2024
a05bf4a
Tweak test to avoid writing file in package directory
Felixmil May 23, 2024
30fa5fd
update c++ libs (#1415)
Yuri05 May 24, 2024
41b16ce
Merge branch 'develop' into r-sharp-r6
Yuri05 May 28, 2024
7c1cc07
Temporarily disable vignettes building for nightly builds (#1418)
Yuri05 May 29, 2024
cddb27f
Temporary fix vignette (#1419)
Yuri05 May 29, 2024
4a3cd4d
Fix packages.ubuntu22.config (#1420)
Yuri05 May 29, 2024
6e4711d
fix weird appveyor build dir change (#1421)
Yuri05 May 29, 2024
8436a02
next try (#1423)
Yuri05 Jun 3, 2024
35a0549
Restrict branch rsharp (#1427)
Yuri05 Jun 3, 2024
60f822a
does this prevent branch building for PR on develop?
rwmcintosh Jun 17, 2024
945ad20
Merge pull request #1435 from Open-Systems-Pharmacology/only_build_pr…
rwmcintosh Jun 17, 2024
a66691e
Merge branch 'develop' of https://github.com/Open-Systems-Pharmacolog…
PavelBal Jun 20, 2024
af7057a
Styler
PavelBal Jun 20, 2024
c955a98
Merge branch 'r-sharp-r6' of https://github.com/Open-Systems-Pharmaco…
PavelBal Jun 20, 2024
f951541
Add script to update core files
Felixmil Jul 16, 2024
7eb419d
update core files
Felixmil Jul 16, 2024
674faac
fix unzip path
Felixmil Jul 16, 2024
61a2e57
fix path
Felixmil Jul 16, 2024
b1286f0
Update initPKSIM function to always target "lib" folder
Felixmil Jul 16, 2024
774a3fb
Overwrite unziped files
Felixmil Jul 16, 2024
107f42c
Merge commit 'bf57d506286d57a245d30fd1b2194056bca8c945'
Felixmil Jul 16, 2024
712b1aa
Add gha for rsharp (#1444)
Felixmil Jul 16, 2024
ad15617
Enable articles about individuals and populations in pkgdown
PavelBal Jul 17, 2024
762836d
Update NEWS
PavelBal Jul 17, 2024
aa75b61
Remove install_dependencies.R
PavelBal Jul 17, 2024
a865987
🤖 Update Core Files.
github-actions[bot] Jul 17, 2024
023577e
Update readme section about loading the workspace
PavelBal Jul 17, 2024
3277e20
Merge branch 'r-sharp-r6' of https://github.com/Open-Systems-Pharmaco…
PavelBal Jul 17, 2024
f4bd252
Update README
PavelBal Jul 17, 2024
7c90872
Move excluded vignettes back to folder
PavelBal Jul 17, 2024
09c0e09
Remove packages.config
PavelBal Jul 17, 2024
dd4a3a4
Fix individual-characteristics.R
PavelBal Jul 17, 2024
2a41931
Fix utilities-population
PavelBal Jul 17, 2024
5382ddf
Enable some skipped tests
PavelBal Jul 17, 2024
cebb7b6
Styler
PavelBal Jul 17, 2024
8965aa9
Fix population vignette failing
PavelBal Jul 17, 2024
6850882
Merge branch 'main' into r-sharp-r6
PavelBal Jul 17, 2024
3d67842
Pksim installation vignette (#1456)
Felixmil Jul 17, 2024
9f290b9
Merge branch 'main' into r-sharp-r6
PavelBal Jul 18, 2024
32f99ee
🤖 Update Core Files.
github-actions[bot] Jul 18, 2024
1e8930a
Increment version number to 12.1.0
Felixmil Jul 18, 2024
6822b87
Merge branch 'r-sharp-r6' of https://github.com/Open-Systems-Pharmaco…
Felixmil Jul 18, 2024
e2d593f
🤖 Update Core Files.
github-actions[bot] Jul 19, 2024
a95d208
add LD_LIBRARY_PATH variable
Felixmil Jul 19, 2024
1f41f5e
Merge branch 'r-sharp-r6' of https://github.com/Open-Systems-Pharmaco…
Felixmil Jul 19, 2024
4b57f12
temporarly ignore vignettes building and check
Felixmil Jul 19, 2024
f4ad4c6
idem
Felixmil Jul 19, 2024
2de6592
dynamically load shared object files
rwmcintosh Jul 19, 2024
4f0803e
restore vignettes building
Felixmil Jul 19, 2024
0faf80c
prepend PKSim dependent vignettes with _ to ignore them
Felixmil Jul 22, 2024
d00429e
Better/clearer binary initialization
Felixmil Jul 22, 2024
4488aa3
🤖 Update Core Files.
github-actions[bot] Jul 22, 2024
c04af7b
Move vignettes to draft folder to prevent RCMDCheck test on them
Felixmil Jul 22, 2024
90d0add
update pkgdown structure
Felixmil Jul 22, 2024
e6d0430
add devtools as suggests (for dev)
Felixmil Jul 22, 2024
4a199f9
Remove test skip conditions
Felixmil Jul 23, 2024
0e9f317
Restore vignettes
Felixmil Jul 23, 2024
3218927
run update_core_files.R
Felixmil Jul 23, 2024
1277c16
styler::style_pkg()
Felixmil Jul 23, 2024
a17836e
add alt text for osp logo
Felixmil Jul 23, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -34,5 +34,6 @@ tests\^spelling
^BinaryFiles$
^README\.Rmd$
^vignettes/images/simulation_lifecycle_flowcharts\.drawio$
^update_core_files.R
^\.github$
^codecov\.yml$
75 changes: 75 additions & 0 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
on:
workflow_call:

name: R-CMD-check

permissions: read-all

jobs:
R-CMD-check:
runs-on: ${{ matrix.config.os }}

name: ${{ matrix.config.os }} (${{ matrix.config.r }})

strategy:
fail-fast: false
matrix:
config:
# - {os: macos-latest, r: 'release'}
- {os: windows-latest, r: 'release'}
# - {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'}
- {os: ubuntu-latest, r: 'release'}
# - {os: ubuntu-latest, r: 'oldrel-1'}

env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes

steps:
- uses: actions/checkout@v4

- uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
http-user-agent: ${{ matrix.config.http-user-agent }}
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::rcmdcheck
needs: check

- uses: r-lib/actions/check-r-package@v2
with:
upload-snapshots: true
build_args: 'c("--no-manual","--compact-vignettes=gs+qpdf")'
error-on: 'c("error")'

- name: Build package
if: ${{ success() }}
run: |
output_dir <- file.path(normalizePath(Sys.getenv("RUNNER_TEMP"), winslash = "/"), "built_package")
dir.create(output_dir)
devtools::build(binary = TRUE, path = output_dir)
shell: Rscript {0}

- name: Get package version from DESCRIPTION file and set as environment variable
run: |
echo "PKG_VERSION=$(grep -oP '(?<=Version: )\d+\.\d+\.\d+\.*\d*' DESCRIPTION)" >> $GITHUB_ENV
shell: bash

- name: get R version and set as environment variable
run: |
echo "R_VERSION=$(Rscript -e 'cat(R.version$major, R.version$minor, sep = ".")')" >> $GITHUB_ENV
shell: bash

- name: Upload built package
if: ${{ success() }}
uses: actions/upload-artifact@v4
with:
name: ospsuite-v${{ env.PKG_VERSION }}-${{runner.os}}-r_${{ env.R_VERSION }}
path: ${{ runner.temp }}/built_package/*
43 changes: 15 additions & 28 deletions .github/workflows/main-workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,42 +5,29 @@ on:
branches: [main]
pull_request:


jobs:
bump-dev-version: # only do that when actually merging in main/develop branch
if: github.event_name != 'pull_request'
uses: ./.github/workflows/bump-dev-version.yaml
secrets: inherit

R-CMD-Check:
if: ${{ always() }}
update-core-files:
if: ${{ !cancelled() && github.event_name == 'pull_request' }}
needs: [bump-dev-version]
uses: Open-Systems-Pharmacology/Workflows/.github/workflows/R-CMD-check-build.yml@main
with:
install-pksim: true
install-rClr: true
extra-packages: |
ospsuite.utils=github::Open-Systems-Pharmacology/OSPSuite.RUtils
tlf=github::Open-Systems-Pharmacology/TLF-Library
uses: ./.github/workflows/update-core-files.yaml

R-CMD-Check:
if: ${{ !cancelled() }}
needs: [update-core-files]
uses: ./.github/workflows/R-CMD-check.yaml

test-coverage:
if: ${{ always() }}
needs: [R-CMD-Check]
uses: Open-Systems-Pharmacology/Workflows/.github/workflows/test-pkg-and-coverage.yml@main
with:
install-pksim: true
install-rClr: true
extra-packages: |
ospsuite.utils=github::Open-Systems-Pharmacology/OSPSuite.RUtils
tlf=github::Open-Systems-Pharmacology/TLF-Library
if: ${{ !cancelled() }}
needs: [update-core-files]
uses: ./.github/workflows/test-coverage.yaml


pkgdown:
if: ${{ always() }}
needs: [R-CMD-Check]
uses: Open-Systems-Pharmacology/Workflows/.github/workflows/pkgdown.yml@main
with:
install-pksim: true
install-rClr: true
extra-packages: |
ospsuite.utils=github::Open-Systems-Pharmacology/OSPSuite.RUtils
tlf=github::Open-Systems-Pharmacology/TLF-Library
if: ${{ !cancelled() }}
needs: [update-core-files]
uses: ./.github/workflows/pkgdown.yaml
44 changes: 44 additions & 0 deletions .github/workflows/pkgdown.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
on:
workflow_call:

name: pkgdown

permissions: read-all

jobs:
pkgdown:
runs-on: ubuntu-latest
# Only restrict concurrency for non-PR jobs
concurrency:
group: pkgdown-${{ github.event_name != 'pull_request' || github.run_id }}
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
permissions:
contents: write
steps:
- uses: actions/checkout@v4

- uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::pkgdown, local::.
needs: website

- name: Build site
run: pkgdown::build_site_github_pages(new_process = FALSE, install = FALSE)
shell: Rscript {0}

- name: Deploy to GitHub pages 🚀
if: github.event_name != 'pull_request'
uses: JamesIves/github-pages-deploy-action@v4.5.0
with:
clean: false
branch: gh-pages
folder: docs
58 changes: 58 additions & 0 deletions .github/workflows/test-coverage.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
on:
workflow_call:

name: test-coverage

permissions: read-all

jobs:
test-coverage:
runs-on: ubuntu-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}

steps:
- uses: actions/checkout@v4

- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::covr, any::xml2
needs: coverage

- name: Test coverage
run: |
cov <- covr::package_coverage(
quiet = FALSE,
clean = FALSE,
install_path = file.path(normalizePath(Sys.getenv("RUNNER_TEMP"), winslash = "/"), "package")
)
covr::to_cobertura(cov)
shell: Rscript {0}

- uses: codecov/codecov-action@v4
with:
fail_ci_if_error: ${{ github.event_name != 'pull_request' && true || false }}
file: ./cobertura.xml
plugin: noop
disable_search: true
token: ${{ secrets.CODECOV_TOKEN }}

- name: Show testthat output
if: always()
run: |
## --------------------------------------------------------------------
find '${{ runner.temp }}/package' -name 'testthat.Rout*' -exec cat '{}' \; || true
shell: bash

- name: Upload test results
if: failure()
uses: actions/upload-artifact@v4
with:
name: coverage-test-failures
path: ${{ runner.temp }}/package
34 changes: 34 additions & 0 deletions .github/workflows/update-core-files.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
on:
workflow_call:

name: R-CMD-check

permissions: write-all


jobs:
update-core-files:
runs-on: ubuntu-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}

steps:
- uses: actions/checkout@v4
with:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.ref }}

- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true

- name: download-and-unzip-core-files
run: source("update_core_files.R")
shell: Rscript {0}

- uses: EndBug/add-and-commit@v9
if: ${{ success() }}
with:
message: '🤖 Update Core Files.'
default_author: github_actions
add: 'inst/lib'
8 changes: 7 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,12 @@ vignettes/*.pdf

# Shiny token, see https://shiny.rstudio.com/articles/shinyapps.html
rsconnect/
doc

Meta

# Website output folder
docs
doc

# test artifacts
tests/testthat/*.pdf
20 changes: 11 additions & 9 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
Type: Package
Package: ospsuite
Title: R package to manipulate OSPSuite Models
Version: 12.0.0.9003
Version: 12.1.0
Authors@R:
c(person("Open-Systems-Pharmacology Community", role = "cph"),
c(person("Open-Systems-Pharmacology Community", role = c("cph", "fnd")),
person("Michael", "Sevestre", role = c("aut", "cre"), email = "michael@design2code.ca"),
person("Pavel", "Balazki", role = "aut"),
person("Juri", "Solodenko", role = "aut", comment = c(ORCID = "0000-0001-6922-588X")),
Expand All @@ -19,8 +19,8 @@ URL: https://github.com/open-systems-pharmacology/ospsuite-r,
BugReports:
https://github.com/open-systems-pharmacology/ospsuite-r/issues
Depends:
R (>= 3.6),
rClr (>= 0.9.1),
R (>= 4.1),
rSharp
Imports:
dplyr (>= 1.0.0),
ospsuite.utils (>= 1.5.0),
Expand All @@ -43,11 +43,12 @@ Suggests:
vdiffr (>= 1.0.0),
withr,
showtext,
sysfonts
sysfonts,
devtools (>= 2.4.5)
Language: en-US
Encoding: UTF-8
LazyData: true
RoxygenNote: 7.3.1
RoxygenNote: 7.3.2
Roxygen: list(markdown = TRUE)
VignetteBuilder: knitr
Config/testthat/edition: 3
Expand Down Expand Up @@ -140,6 +141,7 @@ Collate:
'value-point.R'
'zzz.R'
'zzz_deprecated.R'
Remotes:
Open-Systems-Pharmacology/OSPSuite.RUtils,
Open-Systems-Pharmacology/TLF-Library
Remotes:
Open-Systems-Pharmacology/rSharp,
ospsuite.utils=Open-Systems-Pharmacology/OSPSuite.RUtils,
tlf=Open-Systems-Pharmacology/TLF-Library
2 changes: 1 addition & 1 deletion NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ export(validateDimension)
export(validateUnit)
import(data.table)
import(ospsuite.utils)
import(rClr)
import(rSharp)
import(tidyr)
import(tlf)
import(xml2)
Expand Down
23 changes: 22 additions & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,22 @@
# ospsuite 12.0 (development)
# ospsuite 12.1.0

## New dependencies

- `{rSharp}`

## New features

- The package does not require a local installation of PK-Sim any more. All required
dependencies are shipped with the package.

- The package fully supports Linux.

## Major Changes

- The package loses dependency `{rClr}`


# ospsuite 12.0.0

## New dependencies

Expand All @@ -21,6 +39,8 @@
- Added a function `exportSteadyStateToXLS()` to export steady state values
calculated for one simulation using the `getSteadyState()` to an Excel file
that can be imported in MoBi.



## Breaking Changes

Expand All @@ -29,6 +49,7 @@
of class `Quantity` as inputs, to be consistent with the `toBaseUnit()`
function.


## Major Changes

- Lower limit of quantification (LLOQ) is plotted as dotted lines for
Expand Down
Loading
Loading