-
Notifications
You must be signed in to change notification settings - Fork 995
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
Filter directories #1719
Filter directories #1719
Conversation
Signed-off-by: SSE4 <tomskside@gmail.com>
Codecov Report
@@ Coverage Diff @@
## develop #1719 +/- ##
===========================================
+ Coverage 95.78% 95.78% +<.01%
===========================================
Files 309 309
Lines 26196 26226 +30
===========================================
+ Hits 25091 25121 +30
Misses 1105 1105 |
For the record, pasted the new build_info into my dev environment and it did solve my problems. Thanks all |
Excellent! Thanks for testing and thanks all for the good job |
I just upgraded to 0.27.0 and noticed a regression that seems to be related to this change. I'm noticing that my CONAN_INCLUDE_DIRS_NIAGARA is always empty now if I specify more than one generator. I've traced it down to We should have a way to purge the cache. |
I have created this test, and it is passing: def regression_test(self):
# Possible regression of: https://github.com/conan-io/conan/pull/1719#issuecomment-339137460
client = TestClient()
client.save({"conanfile.py": """from conans import ConanFile
class Pkg(ConanFile):
exports_sources = "*"
def package(self):
self.copy("*", dst="include")
""", "header.h": ""})
client.run("create Pkg/0.1@user/stable")
client.save({"conanfile.txt": "[requires]\nPkg/0.1@user/stable\n"
"[generators]\ncmake\ntxt\ngcc\n"}, clean_first=True)
client.run("install .")
cmake = load(os.path.join(client.current_folder, "conanbuildinfo.cmake"))
txt = load(os.path.join(client.current_folder, "conanbuildinfo.txt"))
gcc = load(os.path.join(client.current_folder, "conanbuildinfo.gcc"))
self.assertIn("Pkg/0.1/user/stable/package/5ab84d6acfe1f23c4fae0ab88f26e3a396351ac9/include",
cmake)
self.assertIn("Pkg/0.1/user/stable/package/5ab84d6acfe1f23c4fae0ab88f26e3a396351ac9/include",
txt)
self.assertIn("Pkg/0.1/user/stable/package/5ab84d6acfe1f23c4fae0ab88f26e3a396351ac9/include",
gcc) Your issue might be related to some generator that is actually creating the folder? The package folder should be inmutable, that is why the cached value for the existence of |
It's the cmake generator, when it's generating If you look at self.include_paths = multiline(cpp_info.include_paths)
self.include_paths = multiline(cpp_info.includedirs) then we get the expected generated output. This is an indication that |
It is pointing to the
@property
def include_paths(self):
if self._include_paths is None:
self._include_paths = self._filter_paths(self.includedirs)
return self._include_paths It will returns Maybe there is something in the other generators you are using. Which are they? Can you check from the output in which order are they being used? Does it happen with any other generator? Just |
My generators are "cmake", "ycm". I'm going to investigate this further and create a test case to reproduce. Where did you place that test case? I want to use that as a starting point. |
My branch: https://github.com/memsharded/conan/tree/feature/test_regression_filter_directories -> conans/test/generators/generator_filter_error_test.py Let me know how it goes. Release 0.28 is tomorrow, branch already open, but if it indeed a bug, will try to include fix. Thanks! |
Hi @skizzay Any news on this? We are preparing 0.29, would be nice to know if something is failing here. Thanks! |
I have added a test for this: #2074 It looks good, so if it is failing in your case, please provide a bit more info. Thanks! |
Proposed performance boost and fixed tests, for #1711
Implements #1607