Templater icon indicating copy to clipboard operation
Templater copied to clipboard

daily quote CORS failure causes template load to fail

Open thesamim opened this issue 2 years ago • 1 comments

Plugin information (please complete the following information):

  • OS: Windows 10
  • Templater version: 1.12.0
  • Obsidian version: 0.14.15
  • Templater settings: Template folder location: "Templates/"

Describe the bug Daily Quote in template fails. Template loading fails altogether.

Expected behavior If a part of the template fails, rest of template should ought to load.

Attachments

  1. templaterDailyQuoteFailTrace.log
  2. daily.md

Notes:

  1. The Daily Quotes failure is annoying, but not that important.
  2. Not sure what other failures could occur, but catching the exceptions and proceeding with other parsing would be ideal.

templaterDailyQuoteFailTrace.log daily.md

thesamim avatar Jun 17 '22 17:06 thesamim

Similar to #661, #595 Please see my comment in #595

<%*
    try {
        tR += await tp.web.daily_quote()
    } catch (err) {
        new Notice("Error: \n" + err , 2000);
    }
%>

Note: this Templater feature came from a Templater Showcase #157, which utilizes lukePeavey's quotable. On his repo, his api is apparently down right now

welpdx avatar Jun 17 '22 19:06 welpdx