Skip to content

Commit

Permalink
Fix crash when no column_as_link
Browse files Browse the repository at this point in the history
Bug introduced in funs.py in 298f8cc
  • Loading branch information
jesusff committed Nov 26, 2024
1 parent aae3260 commit d6384e0
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion CMIP6_downscaling_plans.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<a href="./CORDEX_CMIP6_status_by_experiment.html">experiment</a>
</div>
<div style="display:table-cell;text-align:right;width:50%;">
(Version: {datetime.datetime.now().strftime("%Y-%m-%d %H:%M")})
(Version: {datetime.datetime.now(datetime.timezone.utc).strftime("%Y-%m-%d %H:%M")} UTC)
</div>
</div>
</div>
Expand Down
6 changes: 3 additions & 3 deletions docs/CMIP6_downscaling_plans.html
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ <h1>CORDEX CMIP6 downscaling plans</h1>
<a href="./CORDEX_CMIP6_status_by_experiment.html">experiment</a>
</div>
<div style="display:table-cell;text-align:right;width:50%;">
(Version: 2024-11-06 19:07)
(Version: 2024-11-26 17:18 UTC)
</div>
</div>
</div>
Expand Down Expand Up @@ -3905,8 +3905,8 @@ <h1>CORDEX CMIP6 downscaling plans</h1>
<td>ERA5</td>
<td></td>
<td>evaluation</td>
<td><span class="planned">planned</span></td>
<td>2024-12</td>
<td><span class="completed">completed</span></td>
<td>2024-11</td>
<td><span class="tag">EURcoupled</span> ORAS5 BC in the ocean</td>
</tr>
<tr>
Expand Down
8 changes: 4 additions & 4 deletions funs.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def html_header(title = 'CORDEX-CMIP6 downscaling plans'):
<a href="./CORDEX_CMIP6_status_by_experiment.html">experiment</a>
</div>
<div style="display:table-cell;text-align:right;width:50%;">
(Version: {datetime.datetime.now().strftime("%Y-%m-%d %H:%M")})
(Version: {datetime.datetime.now(datetime.timezone.utc).strftime("%Y-%m-%d %H:%M")} UTC)
</div>
</div>
</div>
Expand Down Expand Up @@ -83,9 +83,9 @@ def csv2datatable(csvfile, htmlout, title='', intro='', rename_fields = {}, colu
if column_as_link:
if not column_as_link_source:
column_as_link_source = column_as_link
plans[column_as_link] = (
'<a href="' + plans[column_as_link_source] + '">' + plans[column_as_link] + "</a>"
)
plans[column_as_link] = (
'<a href="' + plans[column_as_link_source] + '">' + plans[column_as_link] + "</a>"
)
if column_as_link != column_as_link_source:
plans.drop(columns=column_as_link_source, inplace=True)

Expand Down

0 comments on commit d6384e0

Please sign in to comment.