|
1 | 1 | <!-- NEWS.md is maintained by https://fledge.cynkra.com, contributors should not edit this file --> |
2 | 2 |
|
3 | | -# dm 1.0.99.9901 |
| 3 | +# dm 1.1.0 |
4 | 4 |
|
5 | | -## Chore |
| 5 | +## Breaking changes |
6 | 6 |
|
7 | | -- Document. |
| 7 | +- A startup message now recommends running `library(dplyr)` before `library(dm)`. |
| 8 | + In a future version, the dm package will no longer reexport all dplyr functions. |
| 9 | + The new pattern ensures that scripts written today will work after that change. |
| 10 | + Set `options(dm.suppress_dplyr_startup_message = TRUE)` to turn off the startup message. |
8 | 11 |
|
9 | | -## Documentation |
| 12 | +- `copy_dm_to()` now uses `dm_sql()` internally and creates key constraints on the |
| 13 | + database (@krlmlr, #1887, #2022). |
| 14 | + Unique keys and autoincrement primary keys (#1725) are set up automatically. |
| 15 | + Data models with cyclic foreign-key references are now supported on all databases |
| 16 | + that allow `ALTER TABLE` to add constraints (all except DuckDB and SQLite, #664). |
10 | 17 |
|
11 | | -- Update examples and vignettes to use `summarize(.by = ...)` instead of `group_by()` (#2415, #2416). |
| 18 | + ``` r |
| 19 | + con <- DBI::dbConnect(duckdb::duckdb()) |
| 20 | + dm_financial() |> |
| 21 | + copy_dm_to(con, ., temporary = FALSE, set_key_constraints = TRUE) |
| 22 | + DBI::dbDisconnect(con) |
| 23 | + ``` |
12 | 24 |
|
13 | | -## Testing |
| 25 | +## Bug fixes |
14 | 26 |
|
15 | | -- Snapshot updates for R-CMD-check-dev ({"package":"duckplyr"}) (#2419). |
| 27 | +- `dm_from_con(learn_keys = TRUE, .names = )` now correctly applies the specified |
| 28 | + table naming pattern (@owenjonesuob, #2213, #2214). |
| 29 | + |
| 30 | +- `dm_from_con()` no longer learns tables from all schemas by default for Postgres, |
| 31 | + MSSQL, and MariaDB (@mgirlich, #1440, #1448). |
| 32 | + The defaults are `"public"` (Postgres), `"dbo"` (MSSQL), and the current |
| 33 | + database (MariaDB), avoiding spurious system tables. |
| 34 | + |
| 35 | +- Fixed a spurious message from `dm_rm_fk()` when foreign keys reference |
| 36 | + non-primary-key columns (#1270, #2367). |
16 | 37 |
|
| 38 | +- Corrected the deprecation warning message for `dm_squash_to_tbl()` (#1364, #2302). |
17 | 39 |
|
18 | | -# dm 1.0.99.9900 |
| 40 | +- `dm_paste()` limits its pipelines to up to 100 steps, splitting longer pipelines as needed (#2301). |
19 | 41 |
|
20 | 42 | ## Features |
21 | 43 |
|
|
32 | 54 | Useful for denormalizing a star schema before reporting or further analysis. |
33 | 55 | Supports `recursive`, `allow_deep`, and any dplyr join type. |
34 | 56 |
|
35 | | - ``` r |
36 | | - dm_nycflights13() |> |
37 | 57 | dm_select_tbl(-weather) |> |
38 | 58 | dm_flatten(flights, recursive = TRUE) |
39 | | - ``` |
40 | | - |
41 | 59 | - `dm_draw()` gains a `backend_opts` argument that collects all backend-specific |
42 | 60 | options in a single named list (#2381). |
43 | 61 | The individual top-level arguments (`graph_attrs`, `node_attrs`, `edge_attrs`, |
44 | 62 | `focus`, `graph_name`, `font_size`, `columnArrows`) are soft-deprecated in |
45 | 63 | favour of passing their equivalents in `backend_opts`. |
46 | 64 |
|
47 | | - ``` r |
48 | | - dm_nycflights13() |> |
49 | 65 | dm_draw(backend_opts = list(column_arrow = FALSE)) |
50 | | - ``` |
51 | | - |
52 | 66 | - `dm_examine_constraints()` gains a `.max_value` argument controlling how many |
53 | 67 | distinct problematic values are reported in the `problem` column (#2200, #2387). |
54 | 68 | The default is `6`; use `.max_value = Inf` to report all violations. |
55 | 69 |
|
56 | | - ``` r |
57 | | - dm_nycflights13() |> |
58 | 70 | dm_examine_constraints(.max_value = Inf) |
59 | | - ``` |
60 | | - |
61 | 71 | - `check_key()` now returns its input data frame when the key is valid |
62 | 72 | (#2221, #2303), making it usable in pipelines. |
63 | 73 |
|
64 | | - ``` r |
65 | 74 | my_data |> |
66 | 75 | check_key(id) |> |
67 | 76 | dplyr::filter(value > 0) |
68 | | - ``` |
69 | | - |
70 | 77 | - igraph is now an optional dependency (#2146, #2364), reducing the mandatory |
71 | 78 | install footprint. |
72 | 79 | Functions that require igraph will prompt you to install it when needed. |
|
82 | 89 | - All user-facing messages now use `cli::cli_inform()` with native formatting |
83 | 90 | (#2374). |
84 | 91 |
|
85 | | -## Breaking changes |
86 | | - |
87 | | -- A startup message now recommends running `library(dplyr)` before `library(dm)`. |
88 | | - In a future version, the dm package will no longer reexport all dplyr functions. |
89 | | - The new pattern ensures that scripts written today will work after that change. |
90 | | - Set `options(dm.suppress_dplyr_startup_message = TRUE)` to turn off the startup message. |
91 | | - |
92 | | -- `copy_dm_to()` now uses `dm_sql()` internally and creates key constraints on the |
93 | | - database (@krlmlr, #1887, #2022). |
94 | | - Unique keys and autoincrement primary keys (#1725) are set up automatically. |
95 | | - Data models with cyclic foreign-key references are now supported on all databases |
96 | | - that allow `ALTER TABLE` to add constraints (all except DuckDB and SQLite, #664). |
97 | | - |
98 | | - ``` r |
99 | | - con <- DBI::dbConnect(duckdb::duckdb()) |
100 | | - dm_financial() |> |
101 | | - copy_dm_to(con, ., temporary = FALSE, set_key_constraints = TRUE) |
102 | | - DBI::dbDisconnect(con) |
103 | | - ``` |
104 | | - |
105 | | -## Bug fixes |
| 92 | +## Chore |
106 | 93 |
|
107 | | -- `dm_from_con(learn_keys = TRUE, .names = )` now correctly applies the specified |
108 | | - table naming pattern (@owenjonesuob, #2213, #2214). |
| 94 | +- Document. |
109 | 95 |
|
110 | | -- `dm_from_con()` no longer learns tables from all schemas by default for Postgres, |
111 | | - MSSQL, and MariaDB (@mgirlich, #1440, #1448). |
112 | | - The defaults are `"public"` (Postgres), `"dbo"` (MSSQL), and the current |
113 | | - database (MariaDB), avoiding spurious system tables. |
| 96 | +## Documentation |
114 | 97 |
|
115 | | -- Fixed a spurious message from `dm_rm_fk()` when foreign keys reference |
116 | | - non-primary-key columns (#1270, #2367). |
| 98 | +- Update examples and vignettes to use `summarize(.by = ...)` instead of `group_by()` (#2415, #2416). |
117 | 99 |
|
118 | | -- Corrected the deprecation warning message for `dm_squash_to_tbl()` (#1364, #2302). |
| 100 | +## Testing |
119 | 101 |
|
120 | | -- `dm_paste()` limits its pipelines to up to 100 steps, splitting longer pipelines as needed (#2301). |
| 102 | +- Snapshot updates for R-CMD-check-dev ({"package":"duckplyr"}) (#2419). |
121 | 103 |
|
122 | 104 |
|
123 | 105 | # dm 1.0.12 |
|
0 commit comments