argenos / nldates-obsidian

Work with dates in natural language in Obsidian
MIT License
490 stars 44 forks source link

Can't access the date picker. [Solved: Fix in the comments] #65

Closed sethlester closed 2 years ago

sethlester commented 2 years ago

Can't access the date picker.

Current Obsidian Version: v0.12.19 Current nldates-version: v0.6.0

Steps to recreate

  1. Ctrl -P
  2. Select Natural Language Dates: Date Picker

Console Error

main.ts:112 Uncaught TypeError: Cannot read property 'getParsedDate' of undefined
    at NaturalLanguageDates.parse (eval at <anonymous> (app.js:1), <anonymous>:7019:32)
    at NaturalLanguageDates.parseDate (eval at <anonymous> (app.js:1), <anonymous>:7035:21)
    at getDateStr (eval at <anonymous> (app.js:1), <anonymous>:935:43)
    at eval (eval at <anonymous> (app.js:1), <anonymous>:947:26)
    at window.createEl (app.js:1)
    at HTMLDivElement.Node.createEl (app.js:1)
    at DatePickerModal.onOpen (eval at <anonymous> (app.js:1), <anonymous>:944:24)
    at DatePickerModal.e.open (app.js:1)
    at Object.checkCallback (eval at <anonymous> (app.js:1), <anonymous>:6965:71)
    at yL (app.js:1)
robertofgama commented 2 years ago

I have the same problem too.

my console error

date-suggest.ts:35 Uncaught (in promise) TypeError: _this.setInstructions is not a function at new DateSuggest (eval at <anonymous> (app.js:1), <anonymous>:6737:19) at NaturalLanguageDates.eval (eval at <anonymous> (app.js:1), <anonymous>:6971:52) at step (eval at <anonymous> (app.js:1), <anonymous>:72:23) at Object.eval [as next] (eval at <anonymous> (app.js:1), <anonymous>:53:53) at fulfilled (eval at <anonymous> (app.js:1), <anonymous>:43:58) DateSuggest @ date-suggest.ts:35 eval @ main.ts:86 step @ tslib.es6.js:102 eval @ tslib.es6.js:83 fulfilled @ tslib.es6.js:73 Promise.then (async) step @ tslib.es6.js:75 eval @ tslib.es6.js:76 __awaiter @ tslib.es6.js:72 NaturalLanguageDates.onload @ main.ts:19 e.load @ app.js:1 (anonymous) @ app.js:1 (anonymous) @ app.js:1 (anonymous) @ app.js:1 s @ app.js:1 Promise.then (async) l @ app.js:1 (anonymous) @ app.js:1 o @ app.js:1 t.loadPlugin @ app.js:1 (anonymous) @ app.js:1 (anonymous) @ app.js:1 (anonymous) @ app.js:1 (anonymous) @ app.js:1 o @ app.js:1 t.enablePlugin @ app.js:1 (anonymous) @ app.js:1 (anonymous) @ app.js:1 (anonymous) @ app.js:1 s @ app.js:1 Promise.then (async) l @ app.js:1 s @ app.js:1 Promise.then (async) l @ app.js:1 (anonymous) @ app.js:1 o @ app.js:1 t.initialize @ app.js:1 (anonymous) @ app.js:1 (anonymous) @ app.js:1 (anonymous) @ app.js:1 s @ app.js:1 Promise.then (async) l @ app.js:1 a @ app.js:1

liamcain commented 2 years ago

Hi, there was an issue when releasing the latest version, it was only meant to be available to users on the v0.13.0 beta of Obsidian. To fix the issue, could you both uninstall the plugin and try reinstalling? This should make sure you're both using the 0.5.X version of the plugin instead.

robertofgama commented 2 years ago

Hello, i uninstalled my current version and downloaded directly form github the version 0.5.2 and installed manually, after all this resolved my problem, thank you for your attention, helped me a lot

argenos commented 2 years ago

I'm going to close this as a duplicate of #62