Closed a-stein closed 1 year ago
I am getting this problem too. A look at the inspector - this is the article title that is causing an issue:
plugin:obsidian-omnivore:8190 YAMLParseError: Nested mappings are not allowed in compact mappings at line 2, column 8:
title: In Memoriam: Mac | Get Hiroshima
^
I think the : and | characters are throwing it off - they are not valid YAML - there needs to be a way to clean these titles I think. In the past these characters would come in and I would clean up the title to make the YAML compliant. Now it looks like they are being blocked.
Here is another title throwing the import off: How to Be a Better Manager: The Theory of the Elephant and the Rider | Inc.com
You can edit the title in Omnivore on the web to remove those characters and then bring them in just fine - but I think there should be a way to substitute these characters programmatically.
Hey @a-stein @ms3056 , firstly, sorry for the inconvenience caused.
I removed the quotes around the title
in the YAML of the front matter ("${title}"
) because some titles also have quotes ("this is a title"
) which caused the YAML to be invalid. You can refer to this issue #49
Starting from 1.3.0
, by default, we will use multiline string >
for the title
and author
in the YAML to prevent escaping issues.
Pleases kindly update your template and use >
for the values of string
type in the YAML
Below is an example of front matter section in the template setting:
---
id: {{{id}}}
title: >
{{{title}}}
{{#author}}
author: >
{{{author}}}
{{/author}}
---
still not work. same issue
still not work. same issue
Can confirm. Also getting fetch issue, even with the > implementation.
Hey @legend053 @trwolfe , sorry for the mess.
May I have a look at your template settings? If possible, could you also show me a screenshot of the developer console so I could have a better understanding of the error
Hey @legend053 @trwolfe , sorry for the mess.
May I have a look at your template settings? If possible, could you also show me a screenshot of the developer console so I could have a better understanding of the error
I only added the {{{content}}} at the end. Is that in the wrong spot?
Read on Omnivore Read Original
{{#highlights.length}}
{{#highlights}}
{{{text}}} β€΄οΈ {{#labels}} #{{name}} {{/labels}} {{#note}}
{{{note}}} {{/note}}
{{/highlights}} {{/highlights.length}}
{{{content}}} `
Ahhhh, so randomly, I just deleted my entire Omnivore folder from within Obsidian and re-ran the sync and it worked!
Hey @legend053 @trwolfe , sorry for the mess. May I have a look at your template settings? If possible, could you also show me a screenshot of the developer console so I could have a better understanding of the error
I only added the {{{content}}} at the end. Is that in the wrong spot?
`---
id: {{{id}}} title: > {{{title}}} {{#author}} author: > {{{author}}} {{/author}} {{#labels.length}} tags: {{#labels}} - {{{name}}} {{/labels}} {{/labels.length}} date_saved: {{{dateSaved}}} {{#datePublished}} date_published: {{{datePublished}}} {{/datePublished}}
{{{title}}}
Omnivore
Read on Omnivore Read Original
{{#highlights.length}}
Highlights
{{#highlights}}
{{{text}}} β€΄οΈ {{#labels}} #{{name}} {{/labels}} {{#note}}
{{{note}}} {{/note}}
{{/highlights}} {{/highlights.length}}
{{{content}}} `
Hey @trwolfe , to use multiline string, we need to add two spaces before the {{{title}}}
on the next line in the front matter.
This is invalid
title: >
{{{title}}}
And below is valid:
title: >
{{{title}}}
Heyy All, also have the fetching problem. I have tried the above strategies without success.
I'm experiencing the same issue just today. I have already uninstalled and re-installed Omnivore but I'm still getting the same error. Also, prior to re-installing, I have completely deleted the Omnivore folder from Obsidian.
For now as a temporary solution, I'm using obsidian46 - BRAT with the add beta plugin with frozen version
option version: 1.2.3 and it works fine again π
For now as a temporary solution, I'm using obsidian46 - BRAT with the
add beta plugin with frozen version
option version: 1.2.3 and it works fine again π
it works. version 1.2.3 works great. π
For now as a temporary solution, I'm using obsidian46 - BRAT with the
add beta plugin with frozen version
option version: 1.2.3 and it works fine again πit works. version 1.2.3 works great. π
Confirmed this worked for me as well
For me deleting all of the imports in Obsidian and changing the config with this worked fine.
title: >
{{{title}}}
For now as a temporary solution, I'm using obsidian46 - BRAT with the
add beta plugin with frozen version
option version: 1.2.3 and it works fine again π
Sadly, this did not work for me. :(
EDIT: It worked the second time I did it. Thank you for this workaround.
Hey guys, sorry for the delay. I have fixed this error in the latest release 1.3.1
.
It includes:
Failed to fetch articles
error due to invalid YAML format in the front matter. Now you can define which variables to be used in the front matterPlease let me know if it works for you guys and looking forward to your feedback
I don't like how the tags are coming in. It messes up all of my Dataview Queries.
I don't like:
tags:
I want
tags: [tag1, tag2, tag3]
Or some other YAML-compliant multiple entry methods.
this would work - just remove "name:" for tags please:
tags:
this would work - just remove "name:" for tags please:
tags: - tag1 - tag2 - tag3
Sorry for the breaking change. I'm working on a fix now
no worries. i appreciate the ability to bring Omnivore into Obsidian. Thank you for your hard work.
Hey @ms3056 , a new version 1.3.2
is released to use below format for the tags
in the front matter.
tags:
- tag1
- tag2
- tag3
Could you upgrade your plugin and try again?
This has worked for me - thanks!
Hey guys, sorry for the delay. I have fixed this error in the latest release
1.3.1
.It includes:
Bug Fixes
- Fixed
Failed to fetch articles
error due to invalid YAML format in the front matter. Now you can define which variables to be used in the front matterFeature
- Added a reset template button to reset the template to default
Please let me know if it works for you guys and looking forward to your feedback
This does work. But unfortunatly it prevents you from setting your own keys in fronmatter, like:
created: {{{dateSaved}}}
As I use my own keys this is now unusable to me (Unless I did miss the correct way to do this).
Can you update the template under this link to include the multiline frontmatter fields?
Unfortunately, it still does not seem to be working for me on 1.3.3 after resetting the template to default. I'm not getting an error, it just seems to be stuck syncing for ever.
I got some 5xx error with the generic error message Failed to fetch articles
of the OP once, but that was over the course of hours, and I forgot making a screenshot or noting the stacktrace.
Switching to version 1.2.3 fixed the issue for me as well.
Edit:
It worked again on the latest version on a different machine I sync the plugin settings to. I haven't investigated what makes the difference.
version 1.3.3 does not work again on fetching whole articles. It worked before, but failed to fetch articles starting today.
version 1.3.3 does not work again on fetching whole articles. It worked before, but failed to fetch articles starting today.
I restore it back to 1.2.3. Everything works perfect.
Version 1.3.3 getting "Failed to fetch articles". I reinstalled plugin on Obsidian and generated a new API key but same result. Interestingly it brought across 3 files from archive folder but then same result on refresh. I'd be very grateful if you could find a fix.
Version 1.3.3 getting "Failed to fetch articles". I reinstalled plugin on Obsidian and generated a new API key but same result. Interestingly it brought across 3 files from archive folder but then same result on refresh. I'd be very grateful if you could find a fix.
Make sure even when you reinstall that you remove the value of Last Sync in the Omnivore plug-in settings. This tells the plug-in to not bring anything over that is older than that date.
Hey guys, Omnivore plugin 1.4.0 is out.
I hope it will solve all the issues with parsing YAML in the front matter and the sync will continue even if there was a parsing error.
Additionally, now you can create an alias for the metadata in the front matter in the format of metadata::alias
. For example, state::status
will create a metadata status
to represent the state
. The available metadata could be found here.
Screenshot:
Moreover, for users with the need to put hardcoded metadata in the front matter or some other advanced usage, we have added a "front matter template" section under the "Advanced Settings". It will override the "Front matter" if set. Sample template could be found here.
Screenshot:
Hi All, for some reason I do not understand (on my windows machine) it still notifies failed to fetch articles
On my iPhone and iPad the obsidian plugin just works fine.
what I tried till now:
last sync
hope that anyone has some idea that can help
Hi All, for some reason I do not understand (on my windows machine) it still notifies
failed to fetch articles
On my iPhone and iPad the obsidian plugin just works fine.what I tried till now:
- copied the obsidian vault folder of my iphone to my windows machine (with as result: it works shortly and then stops functioning)
- use the exact same frontmatter template as my iphone obsidian vault
- tried the standard template from the website
- deleted the
last sync
- uninstalled and reinstalled
hope that anyone has some idea that can help
Same here. 1.4.0 has this issue too. So far,1.2.3 works best without such issue. So, roll back to version 1.2.3.
I need to verify this on Windows, but I believe the issue I've seen is emoji's in titles causing invalid Window's file names.
Hey @w36zl @legend053 , thanks for reporting.
After some research, we found out that it's the control characters in the filename caused the error on Windows and it has be fixed in the latest version 1.4.1
.
Could you please upgrade your plugin and let me know if it works for you?
Thank you!
That's great! Thank you will check when I returned home π€©
Yeeeeey @sywhb πππ it's working! Such a joy!! Thank you
I'm experiencing an issue when trying to fetch files with Japanese characters in their filenames using the Omnivore plugin in Obsidian.
The error I encounter is:
Error: EINVAL: invalid argument, open 'H:\Obsidian\Omnivore\2023-06-20\ - Wikipedia.md'
It seems that the Japanese characters are not being included in the filenames.
Example of original file name
'( Japanese characters ) - Wikipedia.md'
'γγ―γγγΈγΌ - Wikipedia.md'
Link:γγ―γγγΈγΌ
The Filename setting in the Omnivore plugin, which I've configured to use {{{title}}} for the file name, appears to be causing this issue. When I adjust this setting to {{{dateSaved}}}, the file fetch is successful, even for webpages with a Japanese title
This problem doesn't occur when the same article is in English.
Link:Technology
@SAK59823 sorry, there is a bug with the current version and I'm fixing it now. Should be done pretty soon
@sywhb, is it possible to latinize titles for filenames? not for all, but optional, of course.
Hey @SAK59823 , I just released 1.5.1
to fix this bug ;)
@sywhb, is it possible to latinize titles for filenames? not for all, but optional, of course.
Hey @LightTemplar , currently we do not latinize titles for filenames but I will take a look at some libraries that we can use
Hey @SAK59823 , I just released
1.5.1
to fix this bug ;)
Thank you!!
I still face this problem, and my version is 1.5.3. The only information is:
Failed to fetch articles
And I have set
Hey @wieniawski-lai , would you mind sharing with me your username so I can check in the backend?
Hey @wieniawski-lai , would you mind sharing with me your username so I can check in the backend?
My username is wieniawski in omnivore.
@wieniawski-lai Thank you! I have found the API call made by the plugin is successful and results have been returned so I guess the error comes from the plugin itself.
Would you mind sharing with me the article template config in your plugin settings?
@wieniawski-lai Thank you! I have found the API call made by the plugin is successful and results have been returned so I guess the error comes from the plugin itself.
Would you mind sharing with me the article template config in your plugin settings?
sure, pls see below
# {{{title}}}
#Omnivore
[Read on Omnivore]({{{omnivoreUrl}}})
[Read Original]({{{originalUrl}}})
{{#highlights.length}}
## Highlights
{{#highlights}}
> {{{text}}} [‴οΈ]({{{highlightUrl}}}) {{#labels}} #{{name}} {{/labels}} ^{{{highlightID}}}
{{#note}}
{{{note}}}
{{/note}}
{{/highlights}}
{{/highlights.length}}
Hey @wieniawski-lai , sorry for the late reply. I have released 1.6.0
to address a few fetching issues.
Could you please kindly upgrade your plugin and re-sync all the articles?
We need to clear this "Last Sync" config in the plugin settings and then click on the sync icon again.
thx, @sywhb
I have updated to v1.6.0, and clear "Last Sync" as you said.
Besides, on windows, my folder to save synced data is
E:/backup/note/0.MISC/5.Omnivore/{{{date}}}
And at this time, there is not error happens. However, I still can not find any md file under E:/backup/note/0.MISC/5.Omnivore/{{{date}}}
Is there any log that I can see?
Thanks for the reply @wieniawski-lai .
I think the "Folder" and "Attachment Folder" should be relative path in the Vault.
We do not support saving notes to a different vault for now
Hi,
I recently updated the Obsidian plugin to 1.3.0. Since then I'm not able to sync any articles at all. I just receive the generic error message
Failed to fetch articles
. I already tried to reinstall the plugin and also added a new API Key, but this didn't help.Any ideas?