Support » Plugin: Publish To Apple News » INVALID DOCUMENT error.

  • Resolved agiddens1

    (@agiddens1)


    I’m getting an intermittent error when trying to post to Apple News.

    Anyone have any idea what’s causing it and how to fix please?

    There has been an error with the API: INVALID_DOCUMENT – The value for the property “URL” at line 1 and column 3237 is not valid: Stream & Watch:smarturl.it/frontinme Artist Connect: http://www.instagram.com/harrynathan_www.facebook.com/harrynathanwww.soundcloud.com/harrynathanwww.twitter.com/harrynathan_ Credits: Written, Produced & Performed by Harry Nathan Mixed & Produced by Harry Nathan & Preston J. Walker Mastering by Kevin Grainger Press Photos by Tal Hymans Music Video created by Harry Nathan, Odeya Rush, Ryan Lee & Christian Valderrama (keyPath components->1->components->7->URL)

Viewing 10 replies - 1 through 10 (of 10 total)
  • Thread Starter agiddens1

    (@agiddens1)

    Also this…

    There has been an error with the API:
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->3->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->4->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->6->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->8->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->10->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->12->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->14->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->16->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->18->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->20->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->22->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->24->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->26->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->28->text)
    INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->30->text)

    I’m also getting a series of errors similar to this:

    There has been an error with the API: INVALID_DOCUMENT – “text” was “” should be not (null or an empty string) (keyPath components->1->components->11->text)

    But strangely only for one category, the other category has published fine?

    Seeing this error as well..

    There has been an error with the API: INVALID_DOCUMENT – The value for the property “URL” at line 1 and column #### is not valid:

    even on NON-LINKED urls

    something isn’t parsing correctly or it is just bork.

    Thread Starter agiddens1

    (@agiddens1)

    Is there any news from the devs on when this will be fixed? Even after todays new version the issue remains.

    I’m also getting this error and can’t see what’s wrong with any of the links.

    There has been an error with the API: INVALID_DOCUMENT – The value for the property “URL” at line 1 and column XXXX is not valid

    From what I can tell this line is the culprit.

    “const FACEBOOK_MATCH = ‘/(?:https?:\/\/)?(?:www\.)?(?:facebook|fb|m\.facebook)\.(?:com|me)\/(?:(?:\w)*#!\/)?(?:pages\/)?(?:[\w\-]*\/)*([\w\-\.]+)(?:\/)?/i’;” @ https://github.com/alleyinteractive/apple-news/blob/6f0b4eb1a99394eae6871b1b3069efe4fe1e40a9/includes/apple-exporter/components/class-facebook.php#L27

    It is assuming even regular Facebook links as facebook_post component and creating the errors. Any suggestion of how to suppress this would be helpful.

    I’m seeing the same problem, and you’re right — I think it is somehow confusing what should be body text with a Facebook post! Here’s what I see on a news article that parsed properly:

    {"role":"body","text":"<p><strong>Press Contact:<\/strong><br \/>\nName:

    and one that didn’t parse properly:

    {"role":"facebook_post","URL":"Press Contact:\nName:

    Could we get this fixed, please?

    Steve

    One more comment: My posts include a link to Facebook, and if I remove that link, the article publishes to Apple News properly. Put it back in, I get the error…

    Steve

    And for agiddens1, I do have a workaround for you on the INVALID DOCUMENT bug; I found that if there are ANY blank lines at the end of the post being sent to Apple News, you get this error. Go into your original post and remove all blank lines at the end, and the error should resolve itself.

    Now, if we could just get a fix for this Facebook URL problem…

    Plugin Author Kevin Fodness

    (@kevinfodness)

    We just released version 2.1.0 which contains a fix for the empty paragraph bug in its many forms. If you’re still experiencing that issue on the new version, please open a new support request, as there may have been a particular trigger that we’ve missed. Thanks!

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘INVALID DOCUMENT error.’ is closed to new replies.