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

Git enricher fails to save gitlog.xml #218

Closed
redbeardcreator opened this issue Apr 25, 2015 · 7 comments · Fixed by #219
Closed

Git enricher fails to save gitlog.xml #218

redbeardcreator opened this issue Apr 25, 2015 · 7 comments · Fixed by #219

Comments

@redbeardcreator
Copy link
Contributor

The git enricher throws the following information when attempting to write out the gitlog.xml file. It looks like a path that needs to be evaluated is not. It seems similar to #60, but is only affecting the git enricher.

When I disable the git enricher, document building completes as expected.

This worked previously in a dev version, but I don't know which version it was. The 0.7 release fails to build docs for a number of files in my repository.

Oups... phpDox encountered a problem and has terminated!

It most likely means you've found a bug, so please file a report for this
and paste the following details and the stacktrace (if given) along:

PHP Version: 5.6.7-1 (Linux)
PHPDox Version: 0.7.0-126-g7feacfa
ErrorException: E_WARNING 
Location: /home/michael/.composer/vendor/theseer/fdomdocument/src/fDOMDocument.php (Line 232)

DOMDocument::save(${basedir}/build/phpdox/xml/gitlog.xml): failed to open stream: No such file or directory

#0 /home/michael/.composer/vendor/theseer/fdomdocument/src/fDOMDocument.php(232): DOMDocument->save()
#1 /home/michael/.composer/vendor/theseer/phpdox/src/generator/enricher/git/Git.php(129): TheSeer\fDOM\fDOMDocument->save()
#2 /home/michael/.composer/vendor/theseer/phpdox/src/generator/Generator.php(196): TheSeer\phpDox\Generator\Enricher\Git->enrichEnd()
#3 /home/michael/.composer/vendor/theseer/phpdox/src/generator/Generator.php(147): TheSeer\phpDox\Generator\Generator->handleEvent()
#4 /home/michael/.composer/vendor/theseer/phpdox/src/Application.php(241): TheSeer\phpDox\Generator\Generator->run()
#5 /home/michael/.composer/vendor/theseer/phpdox/src/CLI.php(165): TheSeer\phpDox\Application->runGenerator()
#6 /home/michael/.composer/vendor/theseer/phpdox/phpdox(68): TheSeer\phpDox\CLI->run()
@redbeardcreator
Copy link
Contributor Author

I did a git bisect and found that commit 5fe9804 is the one that introduced the problem. If I get time later today or tonight I'll see if I can figure out exactly where the problem is.

redbeardcreator added a commit to redbeardcreator/phpdox that referenced this issue Apr 25, 2015
Dropping this broke resolution is some cases.

Fixes theseer#218.
@theseer
Copy link
Owner

theseer commented Apr 26, 2015

There's also another issue hidden here: Even if the resolving works the target-directory may not (yet) exist. I'm reopening this issue until i implemented the fix for that.

@theseer theseer reopened this Apr 26, 2015
@theseer
Copy link
Owner

theseer commented Apr 26, 2015

@redbeardcreator Can you provide a testcase für the GlobalConfig unit tests that triggers the line you (re-)added in PR #219. I failed to come up with one previously and thus had it removed.

@redbeardcreator
Copy link
Contributor Author

@theseer, my current project has the problem. I'll see if I can reduce it to a usable test case.

@redbeardcreator
Copy link
Contributor Author

I haven't figured out how to write the unit test, yet, but the project at https://github.com/redbeardcreator/phpdox-testcase will demonstrate the problem. I believe the phpdox.xml file was generated using phpdox --skel.

I will see if I can figure out how to do the unit test.

@theseer
Copy link
Owner

theseer commented Apr 27, 2015

Managed to create a working sample based on your testcase. Thank you!

@redbeardcreator
Copy link
Contributor Author

Your welcome :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants