Skip to content

Commit f935788

Browse files
committed
Merge branch 'master' into ci/updating-wheelbuilders
2 parents 01be81b + 216ebe2 commit f935788

File tree

466 files changed

+31448
-22758
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

466 files changed

+31448
-22758
lines changed

.github/workflows/ci.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ jobs:
246246
247247
248248
windows:
249-
runs-on: windows-2019
249+
runs-on: windows-2022
250250
needs: changed-files
251251
env:
252252
KRATOS_BUILD_TYPE: Custom
@@ -462,7 +462,7 @@ jobs:
462462
463463
464464
windows-core-without-unity:
465-
runs-on: windows-2019
465+
runs-on: windows-2022
466466
needs: changed-files
467467
env:
468468
KRATOS_BUILD_TYPE: Custom
@@ -496,7 +496,7 @@ jobs:
496496
- name: Build
497497
shell: cmd
498498
run: |
499-
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64 || goto :error
499+
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64 || goto :error
500500
501501
set CC=cl.exe
502502
set CXX=cl.exe
@@ -512,7 +512,7 @@ jobs:
512512
del /F /Q "%KRATOS_BUILD%\%KRATOS_BUILD_TYPE%\CMakeFiles"
513513
514514
cmake ^
515-
-G"Visual Studio 16 2019" ^
515+
-G"Visual Studio 17 2022" ^
516516
-H"%KRATOS_SOURCE%" ^
517517
-B"%KRATOS_BUILD%\%KRATOS_BUILD_TYPE%" ^
518518
-DBOOST_ROOT="%TEMP%\boost" ^

.github/workflows/configure.cmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64 || goto :error
1+
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64 || goto :error
22

33
set CC=cl.exe
44
set CXX=cl.exe
@@ -43,7 +43,7 @@ del /F /Q "%KRATOS_BUILD%\%KRATOS_BUILD_TYPE%\CMakeCache.txt"
4343
del /F /Q "%KRATOS_BUILD%\%KRATOS_BUILD_TYPE%\CMakeFiles"
4444

4545
cmake ^
46-
-G"Visual Studio 16 2019" ^
46+
-G"Visual Studio 17 2022" ^
4747
-H"%KRATOS_SOURCE%" ^
4848
-B"%KRATOS_BUILD%\%KRATOS_BUILD_TYPE%" ^
4949
-DBOOST_ROOT="%TEMP%\boost" ^

.github/workflows/nightly_build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ jobs:
175175
176176
177177
windows-nightly:
178-
runs-on: windows-2019
178+
runs-on: windows-2022
179179
env:
180180
KRATOS_BUILD_TYPE: Custom
181181

CMakeLists.txt

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -285,8 +285,8 @@ endif(${MSVC})
285285
# Common flags for MSVC
286286
if(${MSVC})
287287
message(STATUS "Detected compiler as MSVC")
288-
SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /W1 /bigobj /EHsc -DBOOST_ALL_NO_LIB -D_SCL_SECURE_NO_WARNINGS")
289-
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /W1 /bigobj /EHsc /Zc:__cplusplus -DBOOST_ALL_NO_LIB -D_SCL_SECURE_NO_WARNINGS")
288+
SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /W1 /bigobj /EHsc /DNOMINMAX -DBOOST_ALL_NO_LIB -D_SCL_SECURE_NO_WARNINGS")
289+
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /W1 /bigobj /EHsc /DNOMINMAX /Zc:__cplusplus -DBOOST_ALL_NO_LIB -D_SCL_SECURE_NO_WARNINGS")
290290
string( REPLACE "/W3" "" CMAKE_C_FLAGS ${CMAKE_C_FLAGS} )
291291
string( REPLACE "/W3" "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS} )
292292
# CMake does not select the correct runtime library for FullDebug now, no idea why
@@ -344,7 +344,7 @@ if(KRATOS_BUILD_TESTING MATCHES ON)
344344

345345
# restore the current directory's old `COMPILE_OPTIONS`
346346
set_directory_properties(PROPERTIES COMPILE_OPTIONS "${kratos_root_compile_options}")
347-
endif(KRATOS_BUILD_TESTING MATCHES ON)
347+
endif(KRATOS_BUILD_TESTING MATCHES ON)
348348

349349
# Benchmarking
350350
if(KRATOS_BUILD_BENCHMARK MATCHES ON)
@@ -690,6 +690,7 @@ message("\t Model 'CreateModelPart' behavior change (no error thrown if model pa
690690
message("\t Make GetIntegrationMethod method of Condition const: https://github.com/KratosMultiphysics/Kratos/pull/9769")
691691
message("\t Behavior change of ModelPart.GetProperties (MeshIndex removed): https://github.com/KratosMultiphysics/Kratos/pull/9774")
692692
message("\t Behavior change of Testing. Please ensure you use KRATOS_EXPECT for testing instead of KRATOS_CHECK")
693+
message("\t Removal of misused EXTENDED_GAUSS integration rules and unification across geometries: https://github.com/KratosMultiphysics/Kratos/pull/13444")
693694

694695
# Compiling the clipper library
695696
add_subdirectory(${KRATOS_SOURCE_DIR}/external_libraries/clipper)

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ Some users of the technologies developed in Kratos are:
144144
## In Kratos Core:
145145
- [Boost](http://www.boost.org/) for uBLAS
146146
- [pybind11](https://github.com/pybind/pybind11) for exposing C++ to python
147-
- [GidPost](https://www.gidhome.com/gid-plus/tools/476/gidpost/) providing output to [GiD](https://www.gidhome.com/)
147+
- [GidPost]([https://www.gidhome.com/gid-plus/tools/476/gidpost/](https://www.gidsimulation.com/downloads/gidpost-2-11-library-to-write-postprocess-results-for-gid-in-ascii-binary-or-hdf5-format/)) providing output to [GiD](https://www.gidsimulation.com/)
148148
- [AMGCL](https://github.com/ddemidov/amgcl) for its highly scalable multigrid solver
149149
- [JSON](https://github.com/nlohmann/json) JSON for Modern C++
150150
- [ZLib](https://zlib.net/) The compression library

applications/CSharpWrapperApplication/tests/cpp_tests/test_calculate.cpp

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@
88
// |_| |_| |_| |_| |_|
99
//
1010
//
11-
// License: BSD License
12-
// license: CSharpWrapperApplication/license.txt
11+
// License: BSD License
12+
// license: CSharpWrapperApplication/license.txt
1313
//
14-
// Main authors: Vicente Mataix Ferrandiz
14+
// Main authors: Vicente Mataix Ferrandiz
1515
//
1616

1717
// System includes
@@ -28,10 +28,10 @@ namespace Kratos {
2828
namespace Testing {
2929
void CreateMDPAFile() {
3030
std::filebuf buffer;
31-
buffer.open(FilesystemExtensions::JoinPaths({FilesystemExtensions::CurrentWorkingDirectory(), "file.mdpa"}), std::ios::out);
31+
std::filesystem::path file_path = std::filesystem::current_path() / "file.mdpa";
32+
buffer.open(file_path.string().c_str(), std::ios::out);
3233
std::ostream os(&buffer);
33-
os
34-
<< "Begin ModelPartData\nEnd ModelPartData\n\nBegin Properties 0\n DENSITY 2700.000000\n YOUNG_MODULUS 7000000.000000\n POISSON_RATIO 0.300000\n BODY_FORCE [3] (0.000000,0.000000,0.000000)\n THICKNESS 1.000000\nEnd Properties\n\nBegin Nodes\n 1 0.0 0.0 0.0\n 2 0.0 0.0 1.0\n 3 1.0 0.0 0.0\n 4 1.0 1.0 0.0\nEnd Nodes\n\nBegin Elements SmallDisplacementElement3D4N\n 1 0 1 2 3 4\nEnd Elements\n\nBegin SubModelPart BasePart // Note that this would be a sub sub modelpart\n Begin SubModelPartNodes\n 1\n 2\n End SubModelPartNodes\n Begin SubModelPart inner_part\n Begin SubModelPartNodes\n 1\n End SubModelPartNodes\n End SubModelPart\nEnd SubModelPart";
34+
os << "Begin ModelPartData\nEnd ModelPartData\n\nBegin Properties 0\n DENSITY 2700.000000\n YOUNG_MODULUS 7000000.000000\n POISSON_RATIO 0.300000\n BODY_FORCE [3] (0.000000,0.000000,0.000000)\n THICKNESS 1.000000\nEnd Properties\n\nBegin Nodes\n 1 0.0 0.0 0.0\n 2 0.0 0.0 1.0\n 3 1.0 0.0 0.0\n 4 1.0 1.0 0.0\nEnd Nodes\n\nBegin Elements SmallDisplacementElement3D4N\n 1 0 1 2 3 4\nEnd Elements\n\nBegin SubModelPart BasePart // Note that this would be a sub sub modelpart\n Begin SubModelPartNodes\n 1\n 2\n End SubModelPartNodes\n Begin SubModelPart inner_part\n Begin SubModelPartNodes\n 1\n End SubModelPartNodes\n End SubModelPart\nEnd SubModelPart";
3535
buffer.close();
3636
}
3737

@@ -86,7 +86,8 @@ namespace Kratos {
8686
})");
8787
const std::string &r_json_text = json_parameters.PrettyPrintJsonString();
8888
std::filebuf buffer;
89-
buffer.open(FilesystemExtensions::JoinPaths({FilesystemExtensions::CurrentWorkingDirectory(), "file.json"}), std::ios::out);
89+
std::filesystem::path file_path_json = std::filesystem::current_path() / "file.json";
90+
buffer.open(file_path_json.string().c_str(), std::ios::out);
9091
std::ostream os(&buffer);
9192
os << r_json_text;
9293
buffer.close();
@@ -102,9 +103,9 @@ namespace Kratos {
102103

103104
// Import mdpa
104105
CreateMDPAFile();
105-
const std::string file_name = FilesystemExtensions::JoinPaths({FilesystemExtensions::CurrentWorkingDirectory(), "file.mdpa"});
106+
std::filesystem::path file_path = std::filesystem::current_path() / "file.mdpa";
106107
CSharpKratosWrapper::KratosWrapper *wrapperInstance = new CSharpKratosWrapper::KratosWrapper();
107-
wrapperInstance->init(file_name.c_str());
108+
wrapperInstance->init(file_path.string().c_str());
108109
CSharpKratosWrapper::ModelPartWrapper *mainModelPart = wrapperInstance->getRootModelPartWrapper();
109110
// Get some API info
110111
mainModelPart->retrieveResults();
@@ -191,7 +192,7 @@ namespace Kratos {
191192
// KRATOS_EXPECT_NEAR(y[3], 1.0, float_epsilon);
192193
// KRATOS_EXPECT_NEAR(z[3], 0.0, float_epsilon);
193194

194-
Kratos::filesystem::remove((FilesystemExtensions::JoinPaths({FilesystemExtensions::CurrentWorkingDirectory(), "file.mdpa"})).c_str());
195+
std::filesystem::remove(file_path);
195196
}
196197

197198
/**
@@ -205,11 +206,11 @@ namespace Kratos {
205206
// Import mdpa
206207
CreateMDPAFile();
207208
CreateJSONFile();
208-
const std::string file_name = FilesystemExtensions::JoinPaths({FilesystemExtensions::CurrentWorkingDirectory(), "file.mdpa"});
209-
const std::string file_name_json = FilesystemExtensions::JoinPaths({FilesystemExtensions::CurrentWorkingDirectory(), "file.json"});
209+
std::filesystem::path file_path = std::filesystem::current_path() / "file.mdpa";
210+
std::filesystem::path file_path_json = std::filesystem::current_path() / "file.json";
210211
CSharpKratosWrapper::KratosWrapper *wrapperInstance = new CSharpKratosWrapper::KratosWrapper();
211212

212-
wrapperInstance->init(file_name.c_str(), file_name_json.c_str());
213+
wrapperInstance->init(file_path.string().c_str(), file_path_json.string().c_str());
213214
CSharpKratosWrapper::ModelPartWrapper *mainModelPart = wrapperInstance->getRootModelPartWrapper();
214215

215216
// Get some API info
@@ -297,8 +298,8 @@ namespace Kratos {
297298
// KRATOS_EXPECT_NEAR(y[3], 1.0, float_epsilon);
298299
// KRATOS_EXPECT_NEAR(z[3], 0.0, float_epsilon);
299300

300-
Kratos::filesystem::remove((FilesystemExtensions::JoinPaths({FilesystemExtensions::CurrentWorkingDirectory(), "file.mdpa"})).c_str());
301-
Kratos::filesystem::remove((FilesystemExtensions::JoinPaths({FilesystemExtensions::CurrentWorkingDirectory(), "file.json"})).c_str());
301+
std::filesystem::remove(file_path);
302+
std::filesystem::remove(file_path_json);
302303
}
303304

304305
} // namespace Testing

applications/CoSimulationApplication/tests/test_co_sim_io_py_exposure.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
import os
99
import subprocess
1010

11-
11+
@KratosUnittest.skipIf(os.name == 'nt', "This test is skipped in windows due to random errors in CI.")
1212
class TestCoSimIOPyExposure_aux_tests(KratosUnittest.TestCase):
1313

1414
def test_InfoFromParameters(self):
@@ -49,7 +49,7 @@ def test_InfoFromParameters(self):
4949
self.assertFalse(sub_info.GetBool("is_converged"))
5050
self.assertEqual(sub_info.GetInt("echo_lvl"), 5)
5151

52-
52+
@KratosUnittest.skipIf(os.name == 'nt', "This test is skipped in windows due to random errors in CI.")
5353
class TestCoSimIOPyExposure(KratosUnittest.TestCase):
5454

5555
def test_Connect_Disconnect(self):

applications/CoSimulationApplication/tests/test_kratos_co_sim_io.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
import os
99
import subprocess
1010

11-
11+
@KratosUnittest.skipIf(os.name == 'nt', "This test is skipped in windows due to random errors in CI.")
1212
class TestKratosCoSimIO(KratosUnittest.TestCase):
1313

1414
def test_Connect_Disconnect(self):

applications/ContactMechanicsApplication/custom_processes/build_contact_model_part_process.hpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
#include <iostream>
1717

1818
// External includes
19-
#include <boost/timer.hpp>
2019

2120
// Project includes
2221
#include "includes/model_part.h"

applications/ContactMechanicsApplication/custom_processes/generate_new_contact_conditions_mesher_process.hpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
#include <iostream>
1717

1818
// External includes
19-
#include <boost/timer.hpp>
2019

2120
// Project includes
2221
#include "includes/model_part.h"

0 commit comments

Comments
 (0)