prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  Set initial date in date picker in models/file/widgets
  This is needed to make image diff not fail when example is run on different days.
  
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `examples/models/file/widgets.py`
  Content:
  ```
  1 from __future__ import print_function
  2 
  3 #from datetime import date
  4 
  5 from bokeh.document import Document
  6 from bokeh.embed import file_html
  7 from bokeh.resources import INLINE
  8 from bokeh.util.browser import view
  9 from bokeh.models import ColumnDataSource
  10 from bokeh.models.layouts import Column, Row, WidgetBox
  11 from bokeh.models.widgets import (
  12     Button, Toggle, Dropdown,
  13     CheckboxGroup, RadioGroup,
  14     CheckboxButtonGroup, RadioButtonGroup,
  15     TextInput, AutocompleteInput,
  16     Select, MultiSelect,
  17     Slider, RangeSlider, #DateRangeSlider,
  18     DatePicker,
  19     Paragraph, Div, PreText,
  20     Panel, Tabs,
  21     DataTable, TableColumn,
  22     StringFormatter, NumberFormatter,
  23     StringEditor, IntEditor, NumberEditor, SelectEditor,
  24 )
  25 from bokeh.plotting import figure
  26 from bokeh.sampledata.iris import flowers
  27 from bokeh.sampledata.autompg2 import autompg2 as mpg
  28 
  29 button = Button(label="Button (disabled) - still has click event", button_type="primary", disabled=True)
  30 toggle = Toggle(label="Toggle button", button_type="success")
  31 
  32 menu = [("Item 1", "item_1_value"), ("Item 2", "item_2_value"), ("Item 3", "item_3_value")]
  33 
  34 dropdown = Dropdown(label="Dropdown button", button_type="warning", menu=menu)
  35 #dropdown_split = Dropdown(label="Split button", button_type="danger", menu=menu, default_value="default"))
  36 
  37 checkbox_group = CheckboxGroup(labels=["Option 1", "Option 2", "Option 3"], active=[0, 1])
  38 radio_group = RadioGroup(labels=["Option 1", "Option 2", "Option 3"], active=0)
  39 
  40 checkbox_button_group = CheckboxButtonGroup(labels=["Option 1", "Option 2", "Option 3"], active=[0, 1])
  41 radio_button_group = RadioButtonGroup(labels=["Option 1", "Option 2", "Option 3"], active=0)
  42 
  43 text_input = TextInput(placeholder="Enter value ...")
  44 
  45 completions = ["aaa", "aab", "aac", "baa", "caa"]
  46 autocomplete_input = AutocompleteInput(placeholder="Enter value ...", completions=completions)
  47 
  48 select = Select(options=["Option 1", "Option 2", "Option 3"])
  49 
  50 multi_select = MultiSelect(options=["Option %d" % (i+1) for i in range(16)], size=6)
  51 
  52 slider = Slider(value=10, start=0, end=100, step=0.5)
  53 
  54 range_slider = RangeSlider(value=[10, 90], start=0, end=100, step=0.5)
  55 
  56 #date_range_slider = DateRangeSlider(value=(date(2016, 1, 1), date(2016, 12, 31)))
  57 
  58 date_picker = DatePicker()
  59 
  60 paragraph = Paragraph(text="some text")
  61 
  62 div = Div(text="some <b>text</b>")
  63 
  64 pre_text = PreText(text="some text")
  65 
  66 def mk_tab(color):
  67     plot = figure(plot_width=300, plot_height=300)
  68     plot.scatter(flowers["petal_length"], flowers["petal_width"], color=color, fill_alpha=0.2, size=12)
  69     return Panel(title="Tab 1: %s" % color.capitalize(), child=plot)
  70 
  71 tabs = Tabs(tabs=[mk_tab("red"), mk_tab("green"), mk_tab("blue")])
  72 
  73 source = ColumnDataSource(data=mpg)
  74 columns = [
  75     TableColumn(field="manufacturer",
  76                 title="Manufacturer",
  77                 editor=SelectEditor(options=sorted(mpg["manufacturer"].unique())),
  78                 formatter=StringFormatter(font_style="bold")),
  79     TableColumn(field="model",
  80                 title="Model",
  81                 editor=StringEditor(completions=sorted(mpg["model"].unique()))),
  82     TableColumn(field="displ",
  83                 title="Displacement",
  84                 editor=NumberEditor(step=0.1),
  85                 formatter=NumberFormatter(format="0.0")),
  86     TableColumn(field="year",
  87                 title="Year",
  88                 editor=IntEditor()),
  89     TableColumn(field="cyl",
  90                 title="Cylinders",
  91                 editor=IntEditor()),
  92     TableColumn(field="trans",
  93                 title="Transmission",
  94                 editor=SelectEditor(options=sorted(mpg["trans"].unique()))),
  95     TableColumn(field="drv",
  96                 title="Drive",
  97                 editor=SelectEditor(options=sorted(mpg["drv"].unique()))),
  98     TableColumn(field="class",
  99                 title="Class",
  100                 editor=SelectEditor(options=sorted(mpg["class"].unique()))),
  101     TableColumn(field="cty",
  102                 title="City MPG",
  103                 editor=IntEditor()),
  104     TableColumn(field="hwy",
  105                 title="Highway MPG",
  106                 editor=IntEditor()),
  107 ]
  108 table = DataTable(source=source, columns=columns, editable=True, width=800)
  109 
  110 widgets = Column(children=[
  111     Row(children=[
  112         WidgetBox(children=[
  113             button, toggle, dropdown, #dropdown_split,
  114             checkbox_group, radio_group,
  115             checkbox_button_group, radio_button_group,
  116         ]),
  117         WidgetBox(children=[
  118             text_input, autocomplete_input,
  119             select, multi_select,
  120             slider, range_slider, #date_range_slider,
  121             date_picker,
  122             paragraph, div, pre_text,
  123         ]),
  124         WidgetBox(children=[
  125             tabs,
  126         ], width=400),
  127     ]),
  128     WidgetBox(children=[table]),
  129 ])
  130 
  131 
  132 doc = Document()
  133 doc.add_root(widgets)
  134 
  135 if __name__ == "__main__":
  136     doc.validate()
  137     filename = "widgets.html"
  138     with open(filename, "w") as f:
  139         f.write(file_html(doc, INLINE, "Widgets"))
  140     print("Wrote %s" % filename)
  141     view(filename)
  142
  ```
  --- END FILES ---
  
  Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.
  
  Here is an example:
  
  ```diff
  diff --git a/examples/server_async.py b/examples/server_async.py
  --- a/examples/server_async.py
  +++ b/examples/server_async.py
  @@ -313,4 +313,4 @@
   
   
   if __name__ == "__main__":
  -    asyncio.run(run_async_server("."), debug=True)
  +    asyncio.run(run_async_server(), debug=True)
  diff --git a/examples/server_sync.py b/examples/server_sync.py
  --- a/examples/server_sync.py
  +++ b/examples/server_sync.py
  @@ -313,5 +313,5 @@
   
   
   if __name__ == "__main__":
  -    server = run_sync_server(".")
  +    server = run_sync_server()
       server.shutdown()
  
  ```
  
golden_diff: diff --git a/examples/models/file/widgets.py b/examples/models/file/widgets.py
  --- a/examples/models/file/widgets.py
  +++ b/examples/models/file/widgets.py
  @@ -1,6 +1,6 @@
   from __future__ import print_function
   
  -#from datetime import date
  +from datetime import date
   
   from bokeh.document import Document
   from bokeh.embed import file_html
  @@ -55,7 +55,7 @@
   
   #date_range_slider = DateRangeSlider(value=(date(2016, 1, 1), date(2016, 12, 31)))
   
  -date_picker = DatePicker()
  +date_picker = DatePicker(value=date(2017, 8, 1))
   
   paragraph = Paragraph(text="some text")
  
verification_info: {"golden_diff": "diff --git a/examples/models/file/widgets.py b/examples/models/file/widgets.py\n--- a/examples/models/file/widgets.py\n+++ b/examples/models/file/widgets.py\n@@ -1,6 +1,6 @@\n from __future__ import print_function\n \n-#from datetime import date\n+from datetime import date\n \n from bokeh.document import Document\n from bokeh.embed import file_html\n@@ -55,7 +55,7 @@\n \n #date_range_slider = DateRangeSlider(value=(date(2016, 1, 1), date(2016, 12, 31)))\n \n-date_picker = DatePicker()\n+date_picker = DatePicker(value=date(2017, 8, 1))\n \n paragraph = Paragraph(text=\"some text\")\n", "issue": "Set initial date in date picker in models/file/widgets\nThis is needed to make image diff not fail when example is run on different days.\r\n\n", "before_files": [{"content": "from __future__ import print_function\n\n#from datetime import date\n\nfrom bokeh.document import Document\nfrom bokeh.embed import file_html\nfrom bokeh.resources import INLINE\nfrom bokeh.util.browser import view\nfrom bokeh.models import ColumnDataSource\nfrom bokeh.models.layouts import Column, Row, WidgetBox\nfrom bokeh.models.widgets import (\n    Button, Toggle, Dropdown,\n    CheckboxGroup, RadioGroup,\n    CheckboxButtonGroup, RadioButtonGroup,\n    TextInput, AutocompleteInput,\n    Select, MultiSelect,\n    Slider, RangeSlider, #DateRangeSlider,\n    DatePicker,\n    Paragraph, Div, PreText,\n    Panel, Tabs,\n    DataTable, TableColumn,\n    StringFormatter, NumberFormatter,\n    StringEditor, IntEditor, NumberEditor, SelectEditor,\n)\nfrom bokeh.plotting import figure\nfrom bokeh.sampledata.iris import flowers\nfrom bokeh.sampledata.autompg2 import autompg2 as mpg\n\nbutton = Button(label=\"Button (disabled) - still has click event\", button_type=\"primary\", disabled=True)\ntoggle = Toggle(label=\"Toggle button\", button_type=\"success\")\n\nmenu = [(\"Item 1\", \"item_1_value\"), (\"Item 2\", \"item_2_value\"), (\"Item 3\", \"item_3_value\")]\n\ndropdown = Dropdown(label=\"Dropdown button\", button_type=\"warning\", menu=menu)\n#dropdown_split = Dropdown(label=\"Split button\", button_type=\"danger\", menu=menu, default_value=\"default\"))\n\ncheckbox_group = CheckboxGroup(labels=[\"Option 1\", \"Option 2\", \"Option 3\"], active=[0, 1])\nradio_group = RadioGroup(labels=[\"Option 1\", \"Option 2\", \"Option 3\"], active=0)\n\ncheckbox_button_group = CheckboxButtonGroup(labels=[\"Option 1\", \"Option 2\", \"Option 3\"], active=[0, 1])\nradio_button_group = RadioButtonGroup(labels=[\"Option 1\", \"Option 2\", \"Option 3\"], active=0)\n\ntext_input = TextInput(placeholder=\"Enter value ...\")\n\ncompletions = [\"aaa\", \"aab\", \"aac\", \"baa\", \"caa\"]\nautocomplete_input = AutocompleteInput(placeholder=\"Enter value ...\", completions=completions)\n\nselect = Select(options=[\"Option 1\", \"Option 2\", \"Option 3\"])\n\nmulti_select = MultiSelect(options=[\"Option %d\" % (i+1) for i in range(16)], size=6)\n\nslider = Slider(value=10, start=0, end=100, step=0.5)\n\nrange_slider = RangeSlider(value=[10, 90], start=0, end=100, step=0.5)\n\n#date_range_slider = DateRangeSlider(value=(date(2016, 1, 1), date(2016, 12, 31)))\n\ndate_picker = DatePicker()\n\nparagraph = Paragraph(text=\"some text\")\n\ndiv = Div(text=\"some <b>text</b>\")\n\npre_text = PreText(text=\"some text\")\n\ndef mk_tab(color):\n    plot = figure(plot_width=300, plot_height=300)\n    plot.scatter(flowers[\"petal_length\"], flowers[\"petal_width\"], color=color, fill_alpha=0.2, size=12)\n    return Panel(title=\"Tab 1: %s\" % color.capitalize(), child=plot)\n\ntabs = Tabs(tabs=[mk_tab(\"red\"), mk_tab(\"green\"), mk_tab(\"blue\")])\n\nsource = ColumnDataSource(data=mpg)\ncolumns = [\n    TableColumn(field=\"manufacturer\",\n                title=\"Manufacturer\",\n                editor=SelectEditor(options=sorted(mpg[\"manufacturer\"].unique())),\n                formatter=StringFormatter(font_style=\"bold\")),\n    TableColumn(field=\"model\",\n                title=\"Model\",\n                editor=StringEditor(completions=sorted(mpg[\"model\"].unique()))),\n    TableColumn(field=\"displ\",\n                title=\"Displacement\",\n                editor=NumberEditor(step=0.1),\n                formatter=NumberFormatter(format=\"0.0\")),\n    TableColumn(field=\"year\",\n                title=\"Year\",\n                editor=IntEditor()),\n    TableColumn(field=\"cyl\",\n                title=\"Cylinders\",\n                editor=IntEditor()),\n    TableColumn(field=\"trans\",\n                title=\"Transmission\",\n                editor=SelectEditor(options=sorted(mpg[\"trans\"].unique()))),\n    TableColumn(field=\"drv\",\n                title=\"Drive\",\n                editor=SelectEditor(options=sorted(mpg[\"drv\"].unique()))),\n    TableColumn(field=\"class\",\n                title=\"Class\",\n                editor=SelectEditor(options=sorted(mpg[\"class\"].unique()))),\n    TableColumn(field=\"cty\",\n                title=\"City MPG\",\n                editor=IntEditor()),\n    TableColumn(field=\"hwy\",\n                title=\"Highway MPG\",\n                editor=IntEditor()),\n]\ntable = DataTable(source=source, columns=columns, editable=True, width=800)\n\nwidgets = Column(children=[\n    Row(children=[\n        WidgetBox(children=[\n            button, toggle, dropdown, #dropdown_split,\n            checkbox_group, radio_group,\n            checkbox_button_group, radio_button_group,\n        ]),\n        WidgetBox(children=[\n            text_input, autocomplete_input,\n            select, multi_select,\n            slider, range_slider, #date_range_slider,\n            date_picker,\n            paragraph, div, pre_text,\n        ]),\n        WidgetBox(children=[\n            tabs,\n        ], width=400),\n    ]),\n    WidgetBox(children=[table]),\n])\n\n\ndoc = Document()\ndoc.add_root(widgets)\n\nif __name__ == \"__main__\":\n    doc.validate()\n    filename = \"widgets.html\"\n    with open(filename, \"w\") as f:\n        f.write(file_html(doc, INLINE, \"Widgets\"))\n    print(\"Wrote %s\" % filename)\n    view(filename)\n", "path": "examples/models/file/widgets.py"}], "after_files": [{"content": "from __future__ import print_function\n\nfrom datetime import date\n\nfrom bokeh.document import Document\nfrom bokeh.embed import file_html\nfrom bokeh.resources import INLINE\nfrom bokeh.util.browser import view\nfrom bokeh.models import ColumnDataSource\nfrom bokeh.models.layouts import Column, Row, WidgetBox\nfrom bokeh.models.widgets import (\n    Button, Toggle, Dropdown,\n    CheckboxGroup, RadioGroup,\n    CheckboxButtonGroup, RadioButtonGroup,\n    TextInput, AutocompleteInput,\n    Select, MultiSelect,\n    Slider, RangeSlider, #DateRangeSlider,\n    DatePicker,\n    Paragraph, Div, PreText,\n    Panel, Tabs,\n    DataTable, TableColumn,\n    StringFormatter, NumberFormatter,\n    StringEditor, IntEditor, NumberEditor, SelectEditor,\n)\nfrom bokeh.plotting import figure\nfrom bokeh.sampledata.iris import flowers\nfrom bokeh.sampledata.autompg2 import autompg2 as mpg\n\nbutton = Button(label=\"Button (disabled) - still has click event\", button_type=\"primary\", disabled=True)\ntoggle = Toggle(label=\"Toggle button\", button_type=\"success\")\n\nmenu = [(\"Item 1\", \"item_1_value\"), (\"Item 2\", \"item_2_value\"), (\"Item 3\", \"item_3_value\")]\n\ndropdown = Dropdown(label=\"Dropdown button\", button_type=\"warning\", menu=menu)\n#dropdown_split = Dropdown(label=\"Split button\", button_type=\"danger\", menu=menu, default_value=\"default\"))\n\ncheckbox_group = CheckboxGroup(labels=[\"Option 1\", \"Option 2\", \"Option 3\"], active=[0, 1])\nradio_group = RadioGroup(labels=[\"Option 1\", \"Option 2\", \"Option 3\"], active=0)\n\ncheckbox_button_group = CheckboxButtonGroup(labels=[\"Option 1\", \"Option 2\", \"Option 3\"], active=[0, 1])\nradio_button_group = RadioButtonGroup(labels=[\"Option 1\", \"Option 2\", \"Option 3\"], active=0)\n\ntext_input = TextInput(placeholder=\"Enter value ...\")\n\ncompletions = [\"aaa\", \"aab\", \"aac\", \"baa\", \"caa\"]\nautocomplete_input = AutocompleteInput(placeholder=\"Enter value ...\", completions=completions)\n\nselect = Select(options=[\"Option 1\", \"Option 2\", \"Option 3\"])\n\nmulti_select = MultiSelect(options=[\"Option %d\" % (i+1) for i in range(16)], size=6)\n\nslider = Slider(value=10, start=0, end=100, step=0.5)\n\nrange_slider = RangeSlider(value=[10, 90], start=0, end=100, step=0.5)\n\n#date_range_slider = DateRangeSlider(value=(date(2016, 1, 1), date(2016, 12, 31)))\n\ndate_picker = DatePicker(value=date(2017, 8, 1))\n\nparagraph = Paragraph(text=\"some text\")\n\ndiv = Div(text=\"some <b>text</b>\")\n\npre_text = PreText(text=\"some text\")\n\ndef mk_tab(color):\n    plot = figure(plot_width=300, plot_height=300)\n    plot.scatter(flowers[\"petal_length\"], flowers[\"petal_width\"], color=color, fill_alpha=0.2, size=12)\n    return Panel(title=\"Tab 1: %s\" % color.capitalize(), child=plot)\n\ntabs = Tabs(tabs=[mk_tab(\"red\"), mk_tab(\"green\"), mk_tab(\"blue\")])\n\nsource = ColumnDataSource(data=mpg)\ncolumns = [\n    TableColumn(field=\"manufacturer\",\n                title=\"Manufacturer\",\n                editor=SelectEditor(options=sorted(mpg[\"manufacturer\"].unique())),\n                formatter=StringFormatter(font_style=\"bold\")),\n    TableColumn(field=\"model\",\n                title=\"Model\",\n                editor=StringEditor(completions=sorted(mpg[\"model\"].unique()))),\n    TableColumn(field=\"displ\",\n                title=\"Displacement\",\n                editor=NumberEditor(step=0.1),\n                formatter=NumberFormatter(format=\"0.0\")),\n    TableColumn(field=\"year\",\n                title=\"Year\",\n                editor=IntEditor()),\n    TableColumn(field=\"cyl\",\n                title=\"Cylinders\",\n                editor=IntEditor()),\n    TableColumn(field=\"trans\",\n                title=\"Transmission\",\n                editor=SelectEditor(options=sorted(mpg[\"trans\"].unique()))),\n    TableColumn(field=\"drv\",\n                title=\"Drive\",\n                editor=SelectEditor(options=sorted(mpg[\"drv\"].unique()))),\n    TableColumn(field=\"class\",\n                title=\"Class\",\n                editor=SelectEditor(options=sorted(mpg[\"class\"].unique()))),\n    TableColumn(field=\"cty\",\n                title=\"City MPG\",\n                editor=IntEditor()),\n    TableColumn(field=\"hwy\",\n                title=\"Highway MPG\",\n                editor=IntEditor()),\n]\ntable = DataTable(source=source, columns=columns, editable=True, width=800)\n\nwidgets = Column(children=[\n    Row(children=[\n        WidgetBox(children=[\n            button, toggle, dropdown, #dropdown_split,\n            checkbox_group, radio_group,\n            checkbox_button_group, radio_button_group,\n        ]),\n        WidgetBox(children=[\n            text_input, autocomplete_input,\n            select, multi_select,\n            slider, range_slider, #date_range_slider,\n            date_picker,\n            paragraph, div, pre_text,\n        ]),\n        WidgetBox(children=[\n            tabs,\n        ], width=400),\n    ]),\n    WidgetBox(children=[table]),\n])\n\n\ndoc = Document()\ndoc.add_root(widgets)\n\nif __name__ == \"__main__\":\n    doc.validate()\n    filename = \"widgets.html\"\n    with open(filename, \"w\") as f:\n        f.write(file_html(doc, INLINE, \"Widgets\"))\n    print(\"Wrote %s\" % filename)\n    view(filename)\n", "path": "examples/models/file/widgets.py"}]}