Skip to content

Commit e6b5559

Browse files
committed
changelog for prevent_initial_call fix, and black
1 parent ea4bf5c commit e6b5559

File tree

3 files changed

+7
-8
lines changed

3 files changed

+7
-8
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
All notable changes to `dash` will be documented in this file.
33
This project adheres to [Semantic Versioning](https://semver.org/).
44

5+
## [UNRELEASED]
6+
### Fixed
7+
- [#1384](https://github.com/plotly/dash/pull/1384) Fixed a bug introduced by [#1180](https://github.com/plotly/dash/pull/1180) breaking use of `prevent_initial_call` as a positional arg in callback definitions
8+
59
## [1.15.0] - 2020-08-25
610
### Added
711
- [#1355](https://github.com/plotly/dash/pull/1355) Removed redundant log message and consolidated logger initialization. You can now control the log level - for example suppress informational messages from Dash with `app.logger.setLevel(logging.WARNING)`.

tests/integration/callbacks/test_prevent_initial.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -339,11 +339,7 @@ def test_cbpi004_positional_arg(dash_duo):
339339
app = dash.Dash(__name__)
340340
app.layout = html.Div([html.Button("click", id="btn"), html.Div(id="out")])
341341

342-
@app.callback(
343-
Output("out", "children"),
344-
Input("btn", "n_clicks"),
345-
True
346-
)
342+
@app.callback(Output("out", "children"), Input("btn", "n_clicks"), True)
347343
def f(n):
348344
return n
349345

tests/integration/callbacks/test_validation.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -207,16 +207,15 @@ def test_cbva005_tuple_args(dash_duo):
207207
)
208208

209209
@app.callback(
210-
Output("out1", "children"),
211-
(Input("in1", "children"), Input("in2", "children"))
210+
Output("out1", "children"), (Input("in1", "children"), Input("in2", "children"))
212211
)
213212
def f(i1, i2):
214213
return "1: " + i1 + i2
215214

216215
@app.callback(
217216
(Output("out2", "children"),),
218217
Input("in1", "children"),
219-
(State("in2", "children"),)
218+
(State("in2", "children"),),
220219
)
221220
def g(i1, i2):
222221
return ("2: " + i1 + i2,)

0 commit comments

Comments
 (0)