kidok / protobuf

Automatically exported from code.google.com/p/protobuf
0 stars 0 forks source link

Windows: IE Dev Channel (App-V?) causes protobuf tests to fail on the C: drive #649

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Install IE dev channel
2. Build protobuf using the MSVC project files
3. Run the test binaries

What is the expected output? What do you see instead?

I expect all tests to pass.

Instead, I get an error in CommandLineInterfaceTest.OutputDirectoryIsFileError.

The error I get is:

..\src\google\protobuf\compiler\command_line_interface_unittest.cc(349): error: 
Value of: expected_substring
Actual: "foo.proto/: Not a directory"
Expected: a substring of error_text_
Which is: 
"s6j4./proto2_cli_test_temp/foo.proto/foo.proto.MockCodeGenerator.test_generator
: No such file or directory"

I spent some time debugging this issue on the mumble-releng issue tracker: 
https://github.com/mumble-voip/mumble-releng/issues/5

It turns out that it's IE Dev Channel that's causing the issue.

The issue is the following:

We have a file, foo.proto on the filesystem.  We want to use the access() 
function to determine whether the file is a directory, so we append a slash at 
the end.

Calling the function with IE Dev Channel (and thus App-V) installed yields the 
following:

    access("foo.proto/", F_OK) == 0

Without IE Dev Channel/App-V:

    access("foo.proto/", F_OK) == -1

This functionality is used in VerifyDirectoryExists in 
command_line_interface.cc in the protoc compiler: 
https://code.google.com/p/protobuf/source/browse/trunk/src/google/protobuf/compi
ler/command_line_interface.cc#146

I am reporting the issue here so there's a record of the issue in the protobuf 
tracker.  I'll submit a bug report to Microsoft as well.

Original issue reported on code.google.com by kra...@gmail.com on 29 Jun 2014 at 10:04

GoogleCodeExporter commented 9 years ago
See also the upstream bug: 
https://connect.microsoft.com/IE/feedback/details/909134/unexpected-filesystem-i
nteractions-after-installing-ie-dev-channel-app-v-access-lies

Original comment by kra...@gmail.com on 29 Jun 2014 at 10:28

GoogleCodeExporter commented 9 years ago
Updated https://github.com/mumble-voip/mumble-releng/issues/5:

It also happens inside junction points.

Original comment by kra...@gmail.com on 29 Jun 2014 at 9:23

GoogleCodeExporter commented 9 years ago
Microsoft has closed the ticket as WontFix:  
https://connect.microsoft.com/IE/feedback/details/909134/unexpected-filesystem-i
nteractions-after-installing-ie-dev-channel-app-v-access-lies

Maybe the protobuf test should be changed to work with App-V Client or within 
junction points in general?

FWIW, we're building with this patch to avoid the issue:

https://github.com/mumble-voip/mumble-releng/blob/master/buildenv/1.3.x/win32-st
atic/patches/protobuf-2.5.0-win32-disable-OutputDirectoryIsFileError-test.patch

Original comment by kra...@gmail.com on 29 Jul 2014 at 3:51