Marked 2.4.6. fails to open some files

al's Avatar

al

06 Oct, 2014 10:48 PM

I just upgraded to 2.4.6 and now some of my files won't open. The attached example is UTF-8 text. It opened in earlier versions of Marked 2, and still opens fine in Marked 2.2, which 2.4.6 didn't replace.

  1. Support Staff 1 Posted by Brett on 06 Oct, 2014 10:56 PM

    Brett's Avatar

    It opens fine for me in the latest version. Can you show me your
    Processor settings?

    -Brett

  2. 2 Posted by al on 06 Oct, 2014 11:03 PM

    al's Avatar

    here is a screenshot

  3. Support Staff 3 Posted by Brett on 06 Oct, 2014 11:06 PM

    Brett's Avatar

    And when you say it fails to open, are you getting an error?

  4. 4 Posted by al on 06 Oct, 2014 11:10 PM

    al's Avatar

    Yup, the big red cross screen. Woah. I just re-tried and now it works. All I have done is shut down and restart. I promise I was not dreaming! Hmm. I should experiment to see if I can duplicate the error consistently...

  5. 5 Posted by al on 06 Oct, 2014 11:18 PM

    al's Avatar

    Its midnight here and I need sleep.. but just briefly... Opening a file from the "Open" menu always works fine, and double-clicking on the file seems to work. The issue is clicking on a link in another .md file, i.e. [reference text](filename.md)

    But even that is inconsistent - sometimes it bombs and sometimes it doesn't.

  6. Support Staff 6 Posted by Brett on 06 Oct, 2014 11:37 PM

    Brett's Avatar

    I'm guessing that you're running into sandboxing issues with the latest versions. If a user explicitly opens the file (via Open menu, double clicking or drag and drop), permission is granted. Clicking a link does not constitute an express granting of permission, so if the file is in another folder and has never been opened before, it will fail to be read.

  7. 7 Posted by Lars Trebing on 08 Nov, 2014 01:31 AM

    Lars Trebing's Avatar

    Same issue here (non-AppStore Marked 2.4.7 on Mac OS 10.10). Using the files from the attached tar archive:

    1. I open file1.md and file2.md (either from Finder or with the open command in Terminal). Works fine.
    2. I click the link to open file2.md. After telling Marked whether to use the current window or a new one, it opens file2.md as expected.
    3. Back in file1.md, I click the link to open file3.md, and say that I want it in a new window. Nothing happens.
    4. I click the link for file3.md again, this time asking to have it opened in the same window. After a second or too, I get the big “File Type Fail” message.

    After enabling the debug mode using defaults write com.brettterpstra.marked2 debugMode 1, Console.app gives me the following information:

    08/11/14 02:25:09,471 Marked 2[648]: Detected file url: /Users/lars/file3.md (webView:decidePolicyForNavigationAction:request:frame:decisionListener:)
    08/11/14 02:25:13,389 Marked 2[648]: VDKQueue tried to add the path /Users/lars/file3.md to watchedPathEntries, but the VDKQueuePathEntry was nil. 
    It's possible that the host process has hit its max open file descriptors limit.
    08/11/14 02:25:13,389 Marked 2[648]: Monitoring CSS (startMonitoringFile)
    08/11/14 02:25:13,405 sandboxd[311]: ([648]) Marked 2(648) deny file-read-data /Users/lars/file3.md
    08/11/14 02:25:13,414 Marked 2[648]: Loading (tryOpenFile)
    08/11/14 02:25:13,416 Marked 2[648]: file:///Users/lars/file3.md opened with encoding 3127 (tryOpenFile)
    08/11/14 02:25:13,417 Marked 2[648]: Error opening, trying again (loadFromBaseURL)
    08/11/14 02:25:13,432 sandboxd[311]: ([648]) Marked 2(648) deny file-read-data /Users/lars/file3.md
    08/11/14 02:25:14,418 Marked 2[648]: Loading (tryOpenFile)
    08/11/14 02:25:14,421 Marked 2[648]: file:///Users/lars/file3.md opened with encoding 140734693077056 (tryOpenFile)
    08/11/14 02:25:14,422 Marked 2[648]: ERROR text is nil for /Users/lars/file3.md
    08/11/14 02:25:14,422 Marked 2[648]: Loading failed (showErrorNib:)
    08/11/14 02:25:14,435 sandboxd[311]: ([648]) Marked 2(648) deny file-read-data /Users/lars/file3.md
    08/11/14 02:25:26,909 sandboxd[311]: ([648]) Marked 2(648) deny file-read-data /Users/lars/file3.md
    

    Interestingly enough, Marked 2.2 (non-AppStore as well, on the same system) has no problem whatsoever with these file links.

    Is there anything that I can do to get this to work again? Or can I expect it to be fixed in the next update?

  8. Support Staff 8 Posted by Brett on 08 Nov, 2014 01:48 AM

    Brett's Avatar

    It's a simple permissions issue. Drag the parent folder to Marked and it
    will all work fine.

    I'll start having Marked request permissions when opening files through
    links.

    -Brett

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:

»

Already uploaded files

  • Markdown-notes.md 1.11 KB

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac