[Windows] Issue copying ACF files on plugin activation

Issue #4 new
Jeff de Wit created an issue

I'm running this on my local on Windows, which may be part of the issue. It's an otherwise clean install with only ACF Pro and wd_s active.

When I activate the Dudley plugin, I get the following message as a WordPress notification:

"The plugin generated 29159 characters of unexpected output during activation. If you notice “headers already sent” messages, problems with syndication feeds or other issues, try deactivating or removing this plugin."

Since none of the ACF files were actually copied, I'm assuming there is something going on with that. My nginx logs seem to confirm this:

2017/07/21 10:58:37 [error] 5848#5996: *21471 FastCGI sent in stderr: "PHP Warning: copy(E:\dev\www\dudley/wp-content/themes/wd_s/acf-json/dudley\banner\group_57c5fa31a1f3f.json): failed to open stream: No such file or directory in E:\dev\www\dudley\wp-content\plugins\dudley\src\Dudley\MetaType\ACF.php on line 138

As a quick test, I created the "/dudley/banner" folders and then the copying works perfectly fine (though it then still stalls on the next module with the same error, kind of as expected at this point).

Comments (1)

  1. Jeremy Ward

    Hey @cheffheid. Thanks for reporting this issue!

    I don't own a Windows machine to test this on, but it looks like it's a directory separator issue, as they were hard-coded into the ACF.php file. I pushed a potential fix up into a separate branch named hotfix/issue-4. If you have time, could you pull down those changes and attempt to copy files over again to confirm whether that fixes things?

  2. Log in to comment