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

[ignition-msgs*] Fix flaky CI tests for ignition-msgs* ports #14464

Closed

Conversation

traversaro
Copy link
Contributor

We fix the flaky CI tests by not adding anymore the bin and debug/bin directories to the PATH, but rather by making sure that VCPKG_APPLOCAL_DEPS option is correctly propagated.

Describe the pull request

cc @BillyONeal

We fix the flaky CI tests by not adding anymore the bin and debug/bin
directories to the PATH, but rather by making sure that VCPKG_APPLOCAL_DEPS
option is correctly propagated.
@traversaro
Copy link
Contributor Author

As I needed to modify the vcpkg_configure_cmake script that is used by basically every CMake port, I imagine we will have the usual endless CI and spurious CI failures of those cases. :D

@JackBoosY
Copy link
Contributor

Nicole's PR #14399 also tried to fix this issue.

@traversaro
Copy link
Contributor Author

Nicole's PR #14399 also tried to fix this issue.

To clarify, this is a cleanup that should avoid problems of this kind also in the future.

@traversaro
Copy link
Contributor Author

traversaro commented Nov 9, 2020

The osgearth failure is due to this error:

D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarthDrivers\cache_leveldb\Tracker(23): fatal error C1083: Cannot open include file: 'osgEarth/ThreadingUtils': No such file or directory
[377/606] "C:\PROGRA~2\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64\cl.exe"   /TP -DCURL_STATICLIB -DOSGEARTH_HAVE_GEOS -DOSGEARTH_HAVE_MBTILES -DOSGEARTH_HAVE_MVT -DOSGEARTH_HAVE_SQLITE3 -DOSGEARTH_LIBRARY -DTIXML_USE_STL -D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -D__STDC_FORMAT_MACROS -DosgEarth_EXPORTS -Ibuild_include -ID:\installed\x64-windows\include -ID:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src -Isrc\osgEarth /nologo /DWIN32 /D_WINDOWS /W3 /utf-8 /GR /EHsc /MP  /D_DEBUG /MDd /Z7 /Ob0 /Od /RTC1 /showIncludes /Fosrc\osgEarth\CMakeFiles\osgEarth.dir\PlaceNode.cpp.obj /Fdsrc\osgEarth\CMakeFiles\osgEarth.dir\ /FS -c D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarth\PlaceNode.cpp
[378/606] "C:\PROGRA~2\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64\cl.exe"   /TP -DCURL_STATICLIB -DOSGEARTH_HAVE_GEOS -DOSGEARTH_HAVE_MBTILES -DOSGEARTH_HAVE_MVT -DOSGEARTH_HAVE_SQLITE3 -DOSGEARTH_LIBRARY -DTIXML_USE_STL -D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -D__STDC_FORMAT_MACROS -DosgEarth_EXPORTS -Ibuild_include -ID:\installed\x64-windows\include -ID:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src -Isrc\osgEarth /nologo /DWIN32 /D_WINDOWS /W3 /utf-8 /GR /EHsc /MP  /D_DEBUG /MDd /Z7 /Ob0 /Od /RTC1 /showIncludes /Fosrc\osgEarth\CMakeFiles\osgEarth.dir\LocalGeometryNode.cpp.obj /Fdsrc\osgEarth\CMakeFiles\osgEarth.dir\ /FS -c D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarth\LocalGeometryNode.cpp
[379/606] "C:\PROGRA~2\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64\cl.exe"   /TP -DOSGEARTH_HAVE_MBTILES -D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -Dosgdb_osgearth_cache_leveldb_EXPORTS -Ibuild_include -ID:\installed\x64-windows\include -ID:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src /nologo /DWIN32 /D_WINDOWS /W3 /utf-8 /GR /EHsc /MP  /D_DEBUG /MDd /Z7 /Ob0 /Od /RTC1 /showIncludes /Fosrc\osgEarthDrivers\cache_leveldb\CMakeFiles\osgdb_osgearth_cache_leveldb.dir\LevelDBCacheBin.cpp.obj /Fdsrc\osgEarthDrivers\cache_leveldb\CMakeFiles\osgdb_osgearth_cache_leveldb.dir\ /FS -c D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarthDrivers\cache_leveldb\LevelDBCacheBin.cpp
FAILED: src/osgEarthDrivers/cache_leveldb/CMakeFiles/osgdb_osgearth_cache_leveldb.dir/LevelDBCacheBin.cpp.obj 
"C:\PROGRA~2\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64\cl.exe"   /TP -DOSGEARTH_HAVE_MBTILES -D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -Dosgdb_osgearth_cache_leveldb_EXPORTS -Ibuild_include -ID:\installed\x64-windows\include -ID:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src /nologo /DWIN32 /D_WINDOWS /W3 /utf-8 /GR /EHsc /MP  /D_DEBUG /MDd /Z7 /Ob0 /Od /RTC1 /showIncludes /Fosrc\osgEarthDrivers\cache_leveldb\CMakeFiles\osgdb_osgearth_cache_leveldb.dir\LevelDBCacheBin.cpp.obj /Fdsrc\osgEarthDrivers\cache_leveldb\CMakeFiles\osgdb_osgearth_cache_leveldb.dir\ /FS -c D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarthDrivers\cache_leveldb\LevelDBCacheBin.cpp
D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarthDrivers\cache_leveldb\Tracker(23): fatal error C1083: Cannot open include file: 'osgEarth/ThreadingUtils': No such file or directory
[380/606] "C:\PROGRA~2\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64\cl.exe"   /TP -DCURL_STATICLIB -DOSGEARTH_HAVE_GEOS -DOSGEARTH_HAVE_MBTILES -DOSGEARTH_HAVE_MVT -DOSGEARTH_HAVE_SQLITE3 -DOSGEARTH_LIBRARY -DTIXML_USE_STL -D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -D__STDC_FORMAT_MACROS -DosgEarth_EXPORTS -Ibuild_include -ID:\installed\x64-windows\include -ID:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src -Isrc\osgEarth /nologo /DWIN32 /D_WINDOWS /W3 /utf-8 /GR /EHsc /MP  /D_DEBUG /MDd /Z7 /Ob0 /Od /RTC1 /showIncludes /Fosrc\osgEarth\CMakeFiles\osgEarth.dir\ModelNode.cpp.obj /Fdsrc\osgEarth\CMakeFiles\osgEarth.dir\ /FS -c D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarth\ModelNode.cpp
[381/606] "C:\PROGRA~2\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64\cl.exe"   /TP -DCURL_STATICLIB -DOSGEARTH_HAVE_GEOS -DOSGEARTH_HAVE_MBTILES -DOSGEARTH_HAVE_MVT -DOSGEARTH_HAVE_SQLITE3 -DOSGEARTH_LIBRARY -DTIXML_USE_STL -D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -D__STDC_FORMAT_MACROS -DosgEarth_EXPORTS -Ibuild_include -ID:\installed\x64-windows\include -ID:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src -Isrc\osgEarth /nologo /DWIN32 /D_WINDOWS /W3 /utf-8 /GR /EHsc /MP  /D_DEBUG /MDd /Z7 /Ob0 /Od /RTC1 /showIncludes /Fosrc\osgEarth\CMakeFiles\osgEarth.dir\FeatureNode.cpp.obj /Fdsrc\osgEarth\CMakeFiles\osgEarth.dir\ /FS -c D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarth\FeatureNode.cpp
[382/606] "C:\PROGRA~2\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64\cl.exe"   /TP -DOSGEARTH_HAVE_MBTILES -D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -Dosgdb_osgearth_cache_leveldb_EXPORTS -Ibuild_include -ID:\installed\x64-windows\include -ID:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src /nologo /DWIN32 /D_WINDOWS /W3 /utf-8 /GR /EHsc /MP  /D_DEBUG /MDd /Z7 /Ob0 /Od /RTC1 /showIncludes /Fosrc\osgEarthDrivers\cache_leveldb\CMakeFiles\osgdb_osgearth_cache_leveldb.dir\LevelDBCacheDriver.cpp.obj /Fdsrc\osgEarthDrivers\cache_leveldb\CMakeFiles\osgdb_osgearth_cache_leveldb.dir\ /FS -c D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarthDrivers\cache_leveldb\LevelDBCacheDriver.cpp
FAILED: src/osgEarthDrivers/cache_leveldb/CMakeFiles/osgdb_osgearth_cache_leveldb.dir/LevelDBCacheDriver.cpp.obj 
"C:\PROGRA~2\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64\cl.exe"   /TP -DOSGEARTH_HAVE_MBTILES -D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -Dosgdb_osgearth_cache_leveldb_EXPORTS -Ibuild_include -ID:\installed\x64-windows\include -ID:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src /nologo /DWIN32 /D_WINDOWS /W3 /utf-8 /GR /EHsc /MP  /D_DEBUG /MDd /Z7 /Ob0 /Od /RTC1 /showIncludes /Fosrc\osgEarthDrivers\cache_leveldb\CMakeFiles\osgdb_osgearth_cache_leveldb.dir\LevelDBCacheDriver.cpp.obj /Fdsrc\osgEarthDrivers\cache_leveldb\CMakeFiles\osgdb_osgearth_cache_leveldb.dir\ /FS -c D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarthDrivers\cache_leveldb\LevelDBCacheDriver.cpp
D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarthDrivers\cache_leveldb\Tracker(23): fatal error C1083: Cannot open include file: 'osgEarth/ThreadingUtils': No such file or directory

It does not seem to be directly related to this modification. I started #14474 to check if the ports fails also in the current master.

@JackBoosY JackBoosY added the category:port-bug The issue is with a library, which is something the port should already support label Nov 9, 2020
@traversaro
Copy link
Contributor Author

I started #14474 to check if the ports fails also in the current master.

Unfortunately #14474 worked fine, so either the osqearth failure is non-deterministic, or it is actually related to the change of the PR. Another possibility is that the failure is due to the rebuild of one of osgeart dependencies.

@BillyONeal
Copy link
Member

osgearth has also been sporadically failing; I suspect they have some form of races in their build. As such I don't think we should block merging over that.

However, I have a concern with forcing VCPKG_APPLOCAL_DEPS on for the tree -- that's a huge waste of copying time for most ports since it triggers a copy into the buildtrees directory which is then immediately deleted.

@JackBoosY
Copy link
Contributor

JackBoosY commented Nov 10, 2020

D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarthDrivers\cache_leveldb\Tracker(23): fatal error C1083: Cannot open include file: 'osgEarth/ThreadingUtils': No such file or directory

command:

"C:\PROGRA~2\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64\cl.exe"   /TP -DOSGEARTH_HAVE_MBTILES -D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -Dosgdb_osgearth_cache_leveldb_EXPORTS -Ibuild_include -ID:\installed\x64-windows\include -ID:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src /nologo /DWIN32 /D_WINDOWS /W3 /utf-8 /GR /EHsc /MP  /D_DEBUG /MDd /Z7 /Ob0 /Od /RTC1 /showIncludes /Fosrc\osgEarthDrivers\cache_leveldb\CMakeFiles\osgdb_osgearth_cache_leveldb.dir\LevelDBCache.cpp.obj /Fdsrc\osgEarthDrivers\cache_leveldb\CMakeFiles\osgdb_osgearth_cache_leveldb.dir\ /FS -c D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarthDrivers\cache_leveldb\LevelDBCache.cpp

Include dirs:
-ID:\installed\x64-windows\include
-ID:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src

And some warnings:

D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarth\GeoMath.cpp(1): warning C4828: The file contains a character starting at offset 0x1892 that is illegal in the current source character set (codepage 65001).
D:\buildtrees\osgearth\src\18c0ed88a1-76bf0cae95.clean\src\osgEarth\GeoMath.cpp(1): warning C4828: The file contains a character starting at offset 0x18b1 that is illegal in the current source character set (codepage 65001).

@traversaro
Copy link
Contributor Author

osgearth has also been sporadically failing; I suspect they have some form of races in their build. As such I don't think we should block merging over that.

However, I have a concern with forcing VCPKG_APPLOCAL_DEPS on for the tree -- that's a huge waste of copying time for most ports since it triggers a copy into the buildtrees directory which is then immediately deleted.

That is the reason why it is enabled only for ignition-msgs* ports and not for all the ports.

Copy link
Member

@BillyONeal BillyONeal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is the reason why it is enabled only for ignition-msgs* ports and not for all the ports.

Ah, derp, I somehow read the default you set as backwards to what you actually set 🤣

@BillyONeal BillyONeal added the info:reviewed Pull Request changes follow basic guidelines label Nov 10, 2020
@traversaro
Copy link
Contributor Author

That is the reason why it is enabled only for ignition-msgs* ports and not for all the ports.

Ah, derp, I somehow read the default you set as backwards to what you actually set 🤣

No problem. I think that in general having an opt-in VCPKG_APPLOCAL_DEPS set to ON is a good idea for all the projects that need to run a code generator as part of their build.

@strega-nil
Copy link
Contributor

I'll merge after CI runs through.

@strega-nil
Copy link
Contributor

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@strega-nil
Copy link
Contributor

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@JackBoosY JackBoosY linked an issue Nov 16, 2020 that may be closed by this pull request
@strega-nil
Copy link
Contributor

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@Neumann-A
Copy link
Contributor

No problem. I think that in general having an opt-in VCPKG_APPLOCAL_DEPS set to ON is a good idea for all the projects that need to run a code generator as part of their build.

isn't that why ADD_BIN_TO_PATH exists?

@traversaro
Copy link
Contributor Author

traversaro commented Nov 17, 2020

No problem. I think that in general having an opt-in VCPKG_APPLOCAL_DEPS set to ON is a good idea for all the projects that need to run a code generator as part of their build.

isn't that why ADD_BIN_TO_PATH exists?

Good catch! Yes, I think that would also be sufficient, and will not require the crazy luck of being able to do a full re-build of all the cmake-based ports without any spurious failures, that is apparently really unlikely. I think I can use that one. Given that the path is modified only during the build phase, this should also avoid all the problems of finding the clang as the compiler during the configure phase.

@strega-nil strega-nil removed the info:reviewed Pull Request changes follow basic guidelines label Nov 18, 2020
@strega-nil
Copy link
Contributor

Waiting for the ADD_BIN_TO_PATH change.

@traversaro
Copy link
Contributor Author

Waiting for the ADD_BIN_TO_PATH change.

Done in #14730 .

@traversaro traversaro closed this Nov 23, 2020
@traversaro traversaro deleted the fix-flaky-tests-ignition-msgs branch November 23, 2020 19:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:port-bug The issue is with a library, which is something the port should already support
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[ignition-msgs1] cmake dev warning in portfile
5 participants