Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Some images are shown while some not #360

Open
2 tasks done
didiowen opened this issue Sep 3, 2024 · 6 comments
Open
2 tasks done

[Bug]: Some images are shown while some not #360

didiowen opened this issue Sep 3, 2024 · 6 comments
Assignees
Labels
🐛 Bug Something isn't working 🆘 Help wanted Extra attention is needed : the maintener need external help

Comments

@didiowen
Copy link

didiowen commented Sep 3, 2024

Issue validation

  • I checked the issue to prevent duplicate
  • I checked my configurations files and the documentation

Command used

Refresh published and upload new notes

Plugin version

7.2.13

Describe the bug

My uploaded pages works fine at the first attempt, but after some revisions the images are not showing correctly.

For example, in this page some images were shown correctly with the following html:

<img alt="b3d2f56abc296d9dc6b97219bea1bada_MD5.jpeg"
src=". ./ .. /X/attachments/
b3d2f56abc296d9dc6b97219bea1bada_MD5. jpeg">

...while the one at the bottom of the page was shown as ".. /X/attachments/5820fcb1f443750d420fb2328167d274_MD5.jpegl
5820fcb1f443750d420fb2328167d274_MD5.jpeg".

<img alt=" .. /X/
attachments/5820fcb1f443750d420fb2328167d274_MD5.jpeg|
5820fcb1f443750d420fb2328167d274_MD5.jpeg" src=" .. / .. /X/
attachments/5820fcb1f443750d420fb2328167d274_MD5.jpeg|
5820fcb1f443750d420fb2328167d274_MD5.jpeg">
...

In my original .md file, I didn't assign alias to any of the images, just a simple ![[filename.jpeg]], so it wasn't caused by alias. I've also tried to change the "Attachment" settings from configuring a default folder to using the Obsidian folder structure, but the problem remains.

How to reproduce ?

No response

Minimal Reproducible Example

---
title: Tuberculosis
creation date: 2024-08-12 23:08
tags: [medicine/TB, publish]
share: true
category: medicine
alias: tb
---

Some text

![[eb9c6714ed9a2bd4f2e3862fe0c6477f_MD5.jpeg]]
![[70b2c6f4f5838a906dedac0d22900aea_MD5.jpeg]]

Configuration

{
  "github": {
    "branch": "main",
    "automaticallyMergePR": true,
    "dryRun": {
      "enable": false,
      "folderName": "enveloppe"
    },
    "tokenPath": "%configDir%/plugins/%pluginID%/env",
    "api": {
      "tiersForApi": "Github Free/Pro/Team (default)",
      "hostname": ""
    },
    "workflow": {
      "commitMessage": "[PUBLISHER] Merge",
      "name": ""
    },
    "verifiedRepo": true
  },
  "upload": {
    "behavior": "yaml",
    "defaultName": "docs",
    "rootFolder": "docs",
    "yamlFolderKey": "category",
    "frontmatterTitle": {
      "enable": true,
      "key": "alias"
    },
    "replaceTitle": [
      {
        "regex": "title",
        "replacement": "p_title",
        "type": "title"
      }
    ],
    "replacePath": [],
    "autoclean": {
      "includeAttachments": true,
      "enable": true,
      "excluded": [
        "/\\.bib$/",
        "/\\.csl$/"
      ]
    },
    "folderNote": {
      "enable": false,
      "rename": "index.md",
      "addTitle": {
        "enable": false,
        "key": "title"
      }
    },
    "metadataExtractorPath": ""
  },
  "conversion": {
    "hardbreak": true,
    "dataview": true,
    "censorText": [],
    "tags": {
      "inline": false,
      "exclude": [],
      "fields": []
    },
    "links": {
      "internal": true,
      "unshared": true,
      "wiki": false,
      "slugify": "disable"
    }
  },
  "embed": {
    "attachments": true,
    "overrideAttachments": [
      {
        "path": "X/library.bib",
        "destination": "docs/X/",
        "forcePush": true
      }
    ],
    "keySendFile": [
      "bib",
      "csl"
    ],
    "notes": true,
    "folder": "docs/attachments",
    "convertEmbedToLinks": "bake",
    "charConvert": "->",
    "unHandledObsidianExt": [
      "bib",
      "csl"
    ],
    "sendSimpleLinks": true,
    "bake": {
      "textBefore": "",
      "textAfter": ""
    },
    "useObsidianFolder": true
  },
  "plugin": {
    "shareKey": "share",
    "excludedFolder": [],
    "copyLink": {
      "enable": false,
      "links": "https://didiowen.github.io/notes-not-scandal/",
      "removePart": [
        "docs/"
      ],
      "transform": {
        "toUri": false,
        "slugify": "lower",
        "applyRegex": [
          {
            "regex": "",
            "replacement": ""
          }
        ]
      }
    },
    "setFrontmatterKey": "Set"
  },
  "tabsId": "embed-configuration"
}

Relevant log output

No response

OS

No response

Anything else?

No response

Obsidian information

SYSTEM INFO:
	Obsidian version: v1.6.7
	Installer version: v1.4.16
	Operating system: Windows 10 Pro 10.0.22631
	Login status: logged in
	Catalyst license: none
	Insider build toggle: off
	Live preview: on
	Base theme: dark
	Community theme: Minimal v7.7.4
	Snippets enabled: 1
	Restricted mode: off
	Plugins installed: 47
	Plugins enabled: 32
		1: Image Layouts v0.15.5
		2: ReadItLater v0.5.0
		3: Tag Wrangler v0.6.1
		4: Tasks v7.9.0
		5: Minimal Theme Settings v8.1.1
		6: Dataview v0.5.67
		7: Homepage v4.0.4
		8: Buttons v0.5.1
		9: Templater v2.4.2
		10: Style Settings v1.0.9
		11: Smart Typography v1.0.18
		12: Settings Search v1.3.10
		13: QuickAdd v1.11.1
		14: Periodic Notes v0.0.17
		15: Natural Language Dates v0.6.2
		16: Mononote v1.2.2
		17: Calendar v1.5.10
		18: Commander v0.5.1
		19: Local Images Plus v0.15.9
		20: Metadata Menu v0.8.7
		21: Zotero Integration v3.2.1
		22: Spaced Repetition v1.12.5
		23: Highlightr v1.2.2
		24: Book Search v0.7.4
		25: Breadcrumbs v3.6.11
		26: iCal v1.19.0
		27: Day Planner v0.21.1
		28: ICS v1.6.6.1
		29: Enveloppe v7.2.13
		30: Citations v0.4.5
		31: Pandoc Plugin v0.4.1
		32: Pandoc Reference List v2.0.25

RECOMMENDATIONS:
	Custom theme and snippets: for cosmetic issues, please first try updating your theme and disabling your snippets. If still not fixed, please try to make the issue happen in the Sandbox Vault or disable community theme and snippets.
	Community plugins: for bugs, please first try updating all your plugins to latest. If still not fixed, please try to make the issue happen in the Sandbox Vault or disable community plugins.
@didiowen didiowen added the 🐛 Bug Something isn't working label Sep 3, 2024
@Mara-Li
Copy link
Member

Mara-Li commented Sep 3, 2024

Alias are automatically added to keep consistancies between parser.

I think the regex i used here broken the path, probably of the long name or some special character.

I will investigate when I have the time.

@didiowen
Copy link
Author

didiowen commented Sep 3, 2024

So I could probably temporarily fix this by adding alias myself?

@Mara-Li
Copy link
Member

Mara-Li commented Sep 3, 2024

Probably, yes. You should try

@didiowen
Copy link
Author

didiowen commented Sep 3, 2024

Adding alias solves the problem! Huge thanks!

@Mara-Li
Copy link
Member

Mara-Li commented Sep 4, 2024

Adding alias solves the problem! Huge thanks!

I will try to fix it this week-end by the way

@Lisandra-Archive
Copy link

I let it as stale and pin the issue, because I don't want to dig into the regex to fix this T-T Sorry.

@Mara-Li Mara-Li added the 🆘 Help wanted Extra attention is needed : the maintener need external help label Sep 22, 2024
@Mara-Li Mara-Li pinned this issue Sep 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 Bug Something isn't working 🆘 Help wanted Extra attention is needed : the maintener need external help
Projects
None yet
Development

No branches or pull requests

3 participants