-
Notifications
You must be signed in to change notification settings - Fork 74
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix R-level fr-FR translation (#1176)
* update FR .mo file * apply P Grosjean advice * fix R-torch message translations * add fr-translation tests * Delete duplicate test-translation.R * Improve test name * Update test-message-translations.R * add NEWS * Increment version number to 0.13.0.9000 * cleanup NEWS * update FR .mo file * apply P Grosjean advice * fix R-torch message translations * add fr-translation tests * Delete duplicate test-translation.R * Improve test name * Update test-message-translations.R * add NEWS * Increment version number to 0.13.0.9000 * cleanup NEWS * fix gettext return a list that must be flatten * fix 2nd test to be a pure R-level test * align with latest additions * bypass cuda & mps * can we revert 2d78c6b ? * Revert "can we revert 2d78c6b ?" because answer is "No." This reverts commit d27c4f9. * more explicit skip --------- Co-authored-by: Christophe REGOUBY <[email protected]>
- Loading branch information
1 parent
cf26609
commit 37084e4
Showing
8 changed files
with
1,505 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,29 @@ | ||
value_error <- function(..., env = rlang::caller_env()) { | ||
rlang::abort(glue::glue(..., .envir = env), class = "value_error") | ||
rlang::abort(glue::glue(gettext(...)[[1]], .envir = env), class = "value_error") | ||
} | ||
|
||
type_error <- function(..., env = rlang::caller_env()) { | ||
rlang::abort(glue::glue(..., .envir = env), class = "type_error") | ||
rlang::abort(glue::glue(gettext(..., domain = "R-torch")[[1]], .envir = env), class = "type_error") | ||
} | ||
|
||
runtime_error <- function(..., env = rlang::caller_env()) { | ||
rlang::abort(glue::glue(..., .envir = env), class = "runtime_error") | ||
rlang::abort(glue::glue(gettext(..., domain = "R-torch")[[1]], .envir = env), class = "runtime_error") | ||
} | ||
|
||
not_implemented_error <- function(..., env = rlang::caller_env()) { | ||
rlang::abort(glue::glue(..., .envir = env), class = "not_implemented_error") | ||
rlang::abort(glue::glue(gettext(..., domain = "R-torch")[[1]], .envir = env), class = "not_implemented_error") | ||
} | ||
|
||
warn <- function(..., env = rlang::caller_env()) { | ||
rlang::warn(glue::glue(..., .envir = env), class = "warning") | ||
rlang::warn(glue::glue(gettext(..., domain = "R-torch")[[1]], .envir = env), class = "warning") | ||
} | ||
|
||
stop_iteration_error <- function(..., env = rlang::caller_env()) { | ||
rlang::abort(glue::glue(..., .envir = env), class = "stop_iteration_error") | ||
rlang::abort(glue::glue(gettext(..., domain = "R-torch")[[1]], .envir = env), class = "stop_iteration_error") | ||
} | ||
|
||
inform <- rlang::inform | ||
|
||
deprecated <- function(..., env = rlang::caller_env()) { | ||
rlang::warn(..., class = "deprecated") | ||
rlang::warn(gettext(..., domain = "R-torch")[[1]], class = "deprecated") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Oops, something went wrong.