Updated: New Note functionality breaks on renaming “Untitled n” note to “untitled n”

I can’t create a new note in any other way but from the Quick Switcher.
This means that the Cmd+N hotkey doesn’t work and the file explorer “New Note” button doesn’t work either.

I’ve turned off my custom CSS, relaunched the app and the issue still persists.

Now, here it gets weird—I opened the Help vault and tried it there—all the needed new note functions work without a problem.

I’ve checked the hotkey settings — Cmd+N is there. I’ve tried to set it again, but nothing changed. Tried to set it to some other key combo—still no change.

Steps to reproduce

  1. Open Obsidian
  2. Press Cmd+N

Expected result

Get a blank new note

Actual result

Nothing happens

Environment

  • Operating system: MacOS 10.14
  • Obsidian version: 0.8.0

Additional information

As you probably know the repro steps don’t work for me. There’s probably something issue with your vault specifically.

Do you see any errors in the developer tools console?

P.S. Before you have reliable repro steps, posting under “Help” might work better.

@rsdimitrov Rumen, chance are you’re trying to create a new note while you’re on Bulgarian keyboard layout. That doesn’t work in Obsidian for now and has been previously filed as a bug without a fix for now thought.

1 Like

@Silver Looking in the dev tools was a nice nudge, thanks! Here is what I’ve got after pressing the new note hotkey three times:

image

This lead me to look into the notes into my vault that were titled “Untitled”. I had 16 of them — Untitled, Untitled 1…Untitled 15

In some of them I had text, others were zero bytes. Renaming the ones that had contents fixed the issue. Then I deleted all the empty ones and decided to try and see if there was an upper limit to new notes (was this my issue?).

Pressing Cmd+N few dozen times in Obsidian just created the proper amount of empty files.

Now, here is where it gets interesting. I renamed the last created note from “Untitled 27.md” to “untitled 27.md” and got the same error I’ve been getting before—“File already exists”.

Renaming the note back to “Untitled 27.md” had the Cmd+N hotkey function normally. Turns out that if I rename any of the files in the Untitled note stack from “Untitled n.md” to “untitled n.md” the new note functionality breaks.

Here is the dev console output after I reloaded Obsidian and performed the above experiments:
image
note: FileSystem is case insensitive info was present when I took the first screenshot, too. I just didn’t think it was relevant at the time of writing.

Here is my updated bug report:


New Note functionality breaks on renaming “Untitled n” note to “untitled n”

Steps to reproduce

  1. Open Obsidian
  2. Press Cmd+N and create a new note
  3. Rename the “Untitled n” note to “untitled n”
  4. Press Cmd+N to create a new note

Expected result

Get a blank new note with title “Untitled n+1”

Actual result

Nothing happens in the Obsidian UI and this error shows up in the Developer tools console:
image

2 Likes

thanks for updating us

I installed Obsidian and imported notes I had exported from Simplenote into a new vault.
Afterwards I was unable to create a new note in this vault.

Searching the forum I found this old bug report which pointed me to the solution:

It turns out the issue was that the vault contained a file named untitled.md (lowercase).
Deleting that file resolved the issue.

The bug report linked above has been closed, however the bug itself still exists.
I don’t think it is at all reasonable that the existence of a untitled.md file should render the app useless (being able to create new notes seems pretty important).

Steps to reproduce

On macOS

  • Open a new or existing vault
  • Create a new note and change the title to “untitled” (lowercase)
  • Try to create another new note

Expected result

A new note is created and displayed on screen.

Actual result

Nothing.

Environment

  • Operating system:
    macOS 10.15.6
  • Obsidian version:
    0.8.15

Additional information

The vault is on an APFS drive, which is not case-sensitive. This is the default on macOS.

Thanks! I was just having this same issue and that fixed it.

I suspect this one should be a fairly easy fix. Pretty sure the issue here is that the code assumes a case sensitive file system and checks for the existence of “Untitled.md” in a way that returns false even when “untitled.md” exists, and then tries to create “Untitled.md”. The fix should be to make the initial file existence check case insensitive.

will be fixed v0.10