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

Release/v8.7.0 #224

Merged
merged 44 commits into from
May 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
78b9ea9
readingBindinConstraints dev v860
Apr 20, 2023
7ce05ea
up v2.5.2
Apr 27, 2023
8f38424
readBindingConstraint fix list structure for version >=832, now compa…
Apr 27, 2023
b12105b
readBindingConstraint fix and reforge function
May 5, 2023
007465e
readBindingConstraints update code for version 870
May 16, 2023
51a19a2
resolve conflicts master
May 16, 2023
fd9377a
resolve conflicts master
Oct 31, 2023
15e30b7
add empty test study to test more default returns
Dec 11, 2023
7755082
delete 860 and add 870 study test
Dec 11, 2023
e35840a
fix some tests with new study test 870
Dec 11, 2023
c2dcd69
Merge pull request #225 from rte-antares-rpackage/tests/study_v870
berthetclement Dec 11, 2023
b11bd33
test deleted to put them in one only test script
Dec 15, 2023
32910cb
update study with new bindingconstraint using "both" operator
Dec 15, 2023
ce68a87
readBindingConstraints() fix read txt files of values
Dec 15, 2023
7cfff44
update name of empty_study according to code to load test study
Dec 15, 2023
6baea54
add path of empty study
Dec 15, 2023
bec274b
readBindingConstraints() updated to add test of data values and refor…
Dec 15, 2023
73aa449
reforge ouput object readBindingConstraints() + update summary.bindin…
Dec 18, 2023
56d5449
readBindingConstraints add comments on structure of list
Jan 4, 2024
510f415
readBindingConstraints add part code for "both" case
Jan 9, 2024
21c96c6
update test study with "both" bindingconstraint
Jan 9, 2024
4a24592
readBindingConstraints add tests with empty study, tests structure ob…
Jan 10, 2024
9cf91ca
add lifecycle
Jan 15, 2024
42813ee
readBindingConstraints reforge with private functions
Jan 15, 2024
3443fdc
Merge pull request #226 from rte-antares-rpackage/feature/scenarized_bc
berthetclement Jan 15, 2024
d0980ad
readBindingConstraints add badge + update doc
Jan 17, 2024
38b1673
Merge pull request #229 from rte-antares-rpackage/feature/scenarized_bc
berthetclement Jan 17, 2024
152cc3a
readBindingConstraints update to delete warnings message when .txt fi…
Jan 31, 2024
38764ae
up version to 2.7.0
Jan 31, 2024
c7825b3
minor update
Jan 31, 2024
74b64be
add experimental badge to package
Jan 31, 2024
ed8f231
Merge branch 'master' of https://github.com/rte-antares-rpackage/anta…
Feb 16, 2024
134138f
sync pull from master
Feb 19, 2024
2f5541d
readBindingConstraints() minor fix to read BC v870 from API
Mar 14, 2024
7a6dd63
Merge pull request #238 from rte-antares-rpackage/feature/scenarized_bc
berthetclement Mar 14, 2024
c148d2a
api_put() update to return server description + exception message
Mar 18, 2024
2d0f86c
Merge pull request #239 from rte-antares-rpackage/feature/scenarized_bc
berthetclement Mar 18, 2024
6d8bd97
api_delete() updated to return Description and Exception messages fro…
Mar 26, 2024
7020c47
Merge pull request #240 from rte-antares-rpackage/feature/scenarized_bc
berthetclement Mar 26, 2024
b1aa89c
maj news md
Mar 27, 2024
db474a5
resolve conflicts from "develop" + maj news.md
Apr 4, 2024
bac17cf
update from develop and resolve conflicts
berthetclement Apr 30, 2024
6dcdb00
Merge branch 'develop' of https://github.com/rte-antares-rpackage/ant…
berthetclement May 22, 2024
54f8204
revdep check ok with antaresEditObject v0.6.4
berthetclement May 27, 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
5 changes: 3 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: antaresRead
Type: Package
Title: Import, Manipulate and Explore the Results of an 'Antares' Simulation
Version: 2.6.2
Version: 2.7.0
Authors@R: c(
person("Tatiana", "Vargas", email = "[email protected]", role = c("aut", "cre")),
person("Jalal-Edine", "ZAWAM", role = "aut"),
Expand Down Expand Up @@ -39,7 +39,8 @@ Imports:
httr,
utils,
memuse,
purrr
purrr,
lifecycle
Suggests:
rhdf5 (>= 2.24.0),
testthat,
Expand Down
239 changes: 120 additions & 119 deletions NAMESPACE
Original file line number Diff line number Diff line change
@@ -1,119 +1,120 @@
# Generated by roxygen2: do not edit by hand

S3method("[",antaresDataTable)
S3method(as.antaresDataList,antaresDataList)
S3method(as.antaresDataList,antaresDataTable)
S3method(as.antaresDataList,data.frame)
S3method(as.antaresDataList,default)
S3method(as.antaresDataList,list)
S3method(as.antaresDataTable,antaresDataTable)
S3method(as.antaresDataTable,data.frame)
S3method(as.antaresDataTable,default)
S3method(copyToClipboard,antaresDataList)
S3method(copyToClipboard,data.frame)
S3method(copyToClipboard,default)
S3method(copyToClipboard,matrix)
S3method(merge,antaresDataTable)
S3method(print,antaresDataList)
S3method(print,antaresDataTable)
S3method(print,simOptions)
S3method(subset,antaresDataList)
S3method(summary,bindingConstraints)
S3method(viewAntares,antaresDataList)
S3method(viewAntares,default)
export(.getOptionsH5)
export(.h5ReadAntares)
export(.writeAntaresH5Fun)
export(aggregateResult)
export(api_delete)
export(api_get)
export(api_post)
export(api_put)
export(as.antaresDataList)
export(as.antaresDataTable)
export(changeTimeStep)
export(copyToClipboard)
export(extractDataList)
export(getAlias)
export(getAreas)
export(getDistricts)
export(getGeographicTrimming)
export(getIdCols)
export(getLinks)
export(hvdcModification)
export(isH5Opts)
export(mergeDigests)
export(parAggregateMCall)
export(ponderateMcAggregation)
export(readAntares)
export(readAntaresAreas)
export(readAntaresClusters)
export(readBindingConstraints)
export(readClusterDesc)
export(readClusterResDesc)
export(readClusterSTDesc)
export(readDigestFile)
export(readIni)
export(readIniAPI)
export(readIniFile)
export(readInputRES)
export(readInputTS)
export(readInputThermal)
export(readLayout)
export(readOptimCriteria)
export(removeVirtualAreas)
export(setAlias)
export(setHvdcAreas)
export(setRam)
export(setSimulationPath)
export(setSimulationPathAPI)
export(setTimeoutAPI)
export(showAliases)
export(simOptions)
export(viewAntares)
export(writeAntaresH5)
export(writeDigest)
import(bit64)
import(data.table)
import(doParallel)
import(jsonlite)
import(parallel)
import(plyr)
importFrom(doParallel,registerDoParallel)
importFrom(grDevices,col2rgb)
importFrom(grDevices,rgb)
importFrom(httr,DELETE)
importFrom(httr,GET)
importFrom(httr,POST)
importFrom(httr,PUT)
importFrom(httr,accept_json)
importFrom(httr,add_headers)
importFrom(httr,content)
importFrom(httr,content_type_json)
importFrom(httr,http_status)
importFrom(httr,stop_for_status)
importFrom(httr,timeout)
importFrom(memuse,Sys.meminfo)
importFrom(methods,is)
importFrom(pbapply,pblapply)
importFrom(pbapply,pboptions)
importFrom(plyr,llply)
importFrom(purrr,quietly)
importFrom(shiny,getDefaultReactiveDomain)
importFrom(shiny,incProgress)
importFrom(shiny,withProgress)
importFrom(stats,as.formula)
importFrom(stats,setNames)
importFrom(stats,weighted.mean)
importFrom(stringi,stri_replace_last_fixed)
importFrom(stringr,str_match)
importFrom(stringr,str_replace)
importFrom(stringr,str_split)
importFrom(utils,URLencode)
importFrom(utils,View)
importFrom(utils,read.table)
importFrom(utils,setTxtProgressBar)
importFrom(utils,txtProgressBar)
importFrom(utils,type.convert)
importFrom(utils,untar)
importFrom(utils,write.table)
# Generated by roxygen2: do not edit by hand

S3method("[",antaresDataTable)
S3method(as.antaresDataList,antaresDataList)
S3method(as.antaresDataList,antaresDataTable)
S3method(as.antaresDataList,data.frame)
S3method(as.antaresDataList,default)
S3method(as.antaresDataList,list)
S3method(as.antaresDataTable,antaresDataTable)
S3method(as.antaresDataTable,data.frame)
S3method(as.antaresDataTable,default)
S3method(copyToClipboard,antaresDataList)
S3method(copyToClipboard,data.frame)
S3method(copyToClipboard,default)
S3method(copyToClipboard,matrix)
S3method(merge,antaresDataTable)
S3method(print,antaresDataList)
S3method(print,antaresDataTable)
S3method(print,simOptions)
S3method(subset,antaresDataList)
S3method(summary,bindingConstraints)
S3method(viewAntares,antaresDataList)
S3method(viewAntares,default)
export(.getOptionsH5)
export(.h5ReadAntares)
export(.writeAntaresH5Fun)
export(aggregateResult)
export(api_delete)
export(api_get)
export(api_post)
export(api_put)
export(as.antaresDataList)
export(as.antaresDataTable)
export(changeTimeStep)
export(copyToClipboard)
export(extractDataList)
export(getAlias)
export(getAreas)
export(getDistricts)
export(getGeographicTrimming)
export(getIdCols)
export(getLinks)
export(hvdcModification)
export(isH5Opts)
export(mergeDigests)
export(parAggregateMCall)
export(ponderateMcAggregation)
export(readAntares)
export(readAntaresAreas)
export(readAntaresClusters)
export(readBindingConstraints)
export(readClusterDesc)
export(readClusterResDesc)
export(readClusterSTDesc)
export(readDigestFile)
export(readIni)
export(readIniAPI)
export(readIniFile)
export(readInputRES)
export(readInputTS)
export(readInputThermal)
export(readLayout)
export(readOptimCriteria)
export(removeVirtualAreas)
export(setAlias)
export(setHvdcAreas)
export(setRam)
export(setSimulationPath)
export(setSimulationPathAPI)
export(setTimeoutAPI)
export(showAliases)
export(simOptions)
export(viewAntares)
export(writeAntaresH5)
export(writeDigest)
import(bit64)
import(data.table)
import(doParallel)
import(jsonlite)
import(parallel)
import(plyr)
importFrom(doParallel,registerDoParallel)
importFrom(grDevices,col2rgb)
importFrom(grDevices,rgb)
importFrom(httr,DELETE)
importFrom(httr,GET)
importFrom(httr,POST)
importFrom(httr,PUT)
importFrom(httr,accept_json)
importFrom(httr,add_headers)
importFrom(httr,content)
importFrom(httr,content_type_json)
importFrom(httr,http_status)
importFrom(httr,stop_for_status)
importFrom(httr,timeout)
importFrom(lifecycle,deprecated)
importFrom(memuse,Sys.meminfo)
importFrom(methods,is)
importFrom(pbapply,pblapply)
importFrom(pbapply,pboptions)
importFrom(plyr,llply)
importFrom(purrr,quietly)
importFrom(shiny,getDefaultReactiveDomain)
importFrom(shiny,incProgress)
importFrom(shiny,withProgress)
importFrom(stats,as.formula)
importFrom(stats,setNames)
importFrom(stats,weighted.mean)
importFrom(stringi,stri_replace_last_fixed)
importFrom(stringr,str_match)
importFrom(stringr,str_replace)
importFrom(stringr,str_split)
importFrom(utils,URLencode)
importFrom(utils,View)
importFrom(utils,read.table)
importFrom(utils,setTxtProgressBar)
importFrom(utils,txtProgressBar)
importFrom(utils,type.convert)
importFrom(utils,untar)
importFrom(utils,write.table)
24 changes: 24 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,29 @@
> Copyright © 2016 RTE Réseau de transport d’électricité

# antaresRead 2.7.0

### Breaking changes (Antares v8.7.0) :

* `readBindingConstraints()` read now Scenarized RHS for binding constraints (cf. Antares v8.7 changelog)
- function returns a new list structure
* Private function `fread_antares()` no longer returns warnings
* `api_put()/api_delete()` return a server error message

BUGFIXES :

* `readBindingConstraints()` read well study >= v8.3.2

DATA :

* A test study in tar.gz format is available in version v8.7.0
* An empty test study in version v8.7.0 for marginal cases

Dependencies :

* New package `lifecycle` to manage functions status/package status



# antaresRead 2.6.2 (development)

BUGFIXES :
Expand Down
16 changes: 14 additions & 2 deletions R/API-methods.R
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,13 @@ api_put <- function(opts, endpoint, ..., default_endpoint = "v1/studies") {
config,
...
)
stop_for_status(result)
api_content <- content(result)
if(!is.null(names(api_content)))
api_content <- paste0("\n[Description] : ", api_content$description,
"\n[Exception] : ", api_content$exception)
else
api_content <- NULL
stop_for_status(result, task = api_content)
content(result)
}

Expand Down Expand Up @@ -178,6 +184,12 @@ api_delete <- function(opts, endpoint, ..., default_endpoint = "v1/studies") {
config = config,
...
)
stop_for_status(result)
api_content <- content(result)
if(!is.null(names(api_content)))
api_content <- paste0("\n[Description] : ", api_content$description,
"\n[Exception] : ", api_content$exception)
else
api_content <- NULL
stop_for_status(result, task = api_content)
content(result)
}
7 changes: 7 additions & 0 deletions R/antaresRead-package.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#' @keywords internal
"_PACKAGE"

## usethis namespace: start
#' @importFrom lifecycle deprecated
## usethis namespace: end
NULL
Loading
Loading