atom-notes icon indicating copy to clipboard operation
atom-notes copied to clipboard

cannot use the toggle to create a new file

Open aglime opened this issue 4 years ago • 5 comments

Hello,

I'm a newbie and not a coder by trade. I really like the idea of using nvalt functionality with Atom. I was able to get the keymap set and am able to toggle the search for .md in my project folder, but for some reason I cannot type the proposed name of a new file in the prompt and create a new .md. (as demonstrated in the video example) When I type (for example) new-file and hit enter, nothing happens. Am I missing a step?

Thanks!

aglime avatar Mar 04 '20 12:03 aglime

I don't think you're doing anything wrong. If there are any errors they may show up in console of the developer tools; you can open it with the "Open Dev Tools" command.

Also note that if you don't enter any text into a new file, it won't be saved when you closed the window.

lexicalunit avatar Mar 04 '20 23:03 lexicalunit

Thank you so much for the reply. I think I have captured the current "log" of the error that is produced by the console in the atom debugger. I've pasted it below. I was getting an access permissions error, but I updated Node and that seemed to go away.

Right now the only error relates to "no deserializer found for Object_proto_: ??

Thank you again for your help!

Below is the log:

/Users/ashleyglime/.atom/packages/atom-notes/lib/atom-notes.js:87 Activating atom-notes :11 No deserializer found for Object__proto__: constructor: ƒ Object()arguments: (...)assign: ƒ assign()caller: (...)create: ƒ create()defineProperties: ƒ defineProperties()defineProperty: ƒ defineProperty()entries: ƒ entries()freeze: ƒ freeze()getOwnPropertyDescriptor: ƒ getOwnPropertyDescriptor()getOwnPropertyDescriptors: ƒ getOwnPropertyDescriptors()getOwnPropertyNames: ƒ getOwnPropertyNames()getOwnPropertySymbols: ƒ getOwnPropertySymbols()getPrototypeOf: ƒ getPrototypeOf()is: ƒ is()isExtensible: ƒ isExtensible()isFrozen: ƒ isFrozen()isSealed: ƒ isSealed()keys: ƒ keys()length: 1name: "Object"preventExtensions: ƒ preventExtensions()prototype: {constructor: ƒ, defineGetter: ƒ, defineSetter: ƒ, hasOwnProperty: ƒ, lookupGetter: ƒ, …}seal: ƒ seal()setPrototypeOf: ƒ setPrototypeOf()values: ƒ values()proto: ƒ ()[[Scopes]]: Scopes[0]hasOwnProperty: ƒ hasOwnProperty()isPrototypeOf: ƒ isPrototypeOf()propertyIsEnumerable: ƒ propertyIsEnumerable()toLocaleString: ƒ toLocaleString()toString: ƒ toString()valueOf: ƒ valueOf()defineGetter: ƒ defineGetter()defineSetter: ƒ defineSetter()lookupGetter: ƒ lookupGetter()lookupSetter: ƒ lookupSetter()get proto: ƒ proto()set proto: ƒ proto() deserialize @ :11 /Users/ashleyglime/.atom/packages/atom-notes/lib/notes-store.js:182 atom-notes: indexing... /Users/ashleyglime/.atom/packages/atom-notes/lib/atom-notes.js:249 atom-notes: ready in 43ms /Users/ashleyglime/.atom/packages/language-atom-notes/lib/main.js:42 language-atom-notes: ensuring markdown-preview supports our grammar... /Users/ashleyglime/.atom/packages/language-atom-notes/lib/main.js:42 language-atom-notes: ensuring spell-check supports our grammar...

aglime avatar Mar 05 '20 14:03 aglime

Oh no, that's not good. Not sure why you're getting that deserialization error. It looks like an unhandled exception tho the lines afterward seem to indicate that atom-notes does continue on and index things properly, finishing its activation in 43ms. It could be in a bad state and not working properly though due to the unhandled exception.

I'm going to add some guards to try and handle the exception where I think it's being thrown. Seemingly from the call to atom.deserializers.deserialize() despite my deserializer implementation already having its own internal exception handling — maybe this is a bug in atom's deserialization library somewhere?

lexicalunit avatar Mar 05 '20 18:03 lexicalunit

So, I'm actually experiencing this same error too. It seems to happen the first time Atom loads the package. Subsequent hard reloads seem to work for some reason. Sadly, I think this means that this error isn't related to the issue you're experiencing. I'm getting the same error and yet my atom-notes is still functioning properly. Ideally I'd like the eliminate the error entirely in any case, but I think doing so wouldn't help resolve the problem you're facing.

lexicalunit avatar Mar 05 '20 18:03 lexicalunit

One thing you might check is that after you type something into atom-notes and hit enter, can you go to the directory where your notes are being saved and see if there is a file there named whatever you just typed? If so, try editing that file and adding some text to it and saving it. Does it then show up in atom-notes?

Just kinda throwing things out there and seeing what sticks... sorry I'm not sure what could be going wrong 😢

lexicalunit avatar Mar 05 '20 18:03 lexicalunit