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

Getting a Parse Exception when running Gitify Build #228

Open
ghost opened this issue Mar 16, 2018 · 2 comments
Open

Getting a Parse Exception when running Gitify Build #228

ghost opened this issue Mar 16, 2018 · 2 comments
Labels

Comments

@ghost
Copy link

ghost commented Mar 16, 2018

Summary

We want to use Gitify for an existing ModX-Installation. We installed it following the instructions and the Gitify extract command ran fine. When trying to build the database on a different machine from the extracted data it works until it comes to the step "Building modSnippet from snippets/...". At this point Gitify throws a "[Symfony\Component\Yaml\Exception\ParseException]" with an additional "Malformed inline YAML string" followed by about 32,000 characters of YAML in one line.
Online YAML validators all show the YAML to be correct, up until the part where the PHP follows, of course.

Step to reproduce

Create a ModX-Installation, install a few plugins like ContentBlocks, pdotools, Babel, LangRouter, TineMCEWrapper, ...
Create some custom content blocks, then extract the data using Gitify extract, commit that to a Git repository, check it out on a different machine and run Gitify build on it.

Observed behavior

It runs up to the point where it tries to build the snippets, then throws a [Symfony\Component\Yaml\Exception\ParseException]

Expected behavior

Rebuild the database.

Environment

Gitify version: Git master branch,
MODX version: MODX Revolution 2.6.1-pl (traditional),
Operating System: Ubuntu 16.04,
MySQL version: 5.7.21,
PHP version: 7.2.3

@Mark-H
Copy link
Member

Mark-H commented Mar 16, 2018

Have you tried narrowing it down to a particular snippet that is failing to parse? Could it be, as the error suggests, an invalid file? There's nothing about PHP in particular that would break the YAML parsing, especially with the PHP being in the content (below the ----'s) instead of in the yaml frontmatter.

@ghost
Copy link
Author

ghost commented Mar 16, 2018

Yes, in the meantime I could narrow it down to the snippet TinyMagicPublisher, which seems to come from the package TinymceWrapper.
Forget about the PHP part, I accidentally submitted the whole file instead of just the YAML part into the validators. The Validators (I checked with different ones) all claim that the YAML that generates the exception is OK. I attached the file in question to this comment (renamed the extension from .php to .txt because of Github guidelines).
TinyMagicPublisher.txt

@Mark-H Mark-H added the bug label Jun 15, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant