Skip to content

Commit 0316972

Browse files
PProfizirlagharafacanton
authored
Fix InProcess path update (#1449)
* update generated code * Revert correct licensing behavior * debug * Move one test to other file * update generated code * Temporary skip of remote_operator tests * revert * revert prints * revert CI * missing print * readd tests * Revert "missing print" This reverts commit ded2061. * Revert "Revert "missing print"" This reverts commit 77455f5. * Revert "readd tests" This reverts commit 4d56b19. * Fix 1 Signed-off-by: paul.profizi <[email protected]> * Remote Operators Fix2 Signed-off-by: paul.profizi <[email protected]> * Revert "Temporary skip of remote_operator tests" This reverts commit 777909b. * Remote Operators Fix3 Signed-off-by: paul.profizi <[email protected]> * Revert PATH fix for Linux Signed-off-by: paul.profizi <[email protected]> * Revert "Temporary skip of remote_operator tests" This reverts commit 777909b. * Get the right standalone suffix when PR on a "maint/update_code_for_*" branch Signed-off-by: paul.profizi <[email protected]> Get the right standalone suffix when PR on a "maint/update_code_for_*" branch Signed-off-by: paul.profizi <[email protected]> * Unskip test_remote_operator.py tests Signed-off-by: paul.profizi <[email protected]> * Fix code quality Signed-off-by: paul.profizi <[email protected]> * Fix code quality Signed-off-by: paul.profizi <[email protected]> * Fix code quality Signed-off-by: paul.profizi <[email protected]> --------- Signed-off-by: paul.profizi <[email protected]> Co-authored-by: rlagha <[email protected]> Co-authored-by: Rafael Canton <[email protected]> Co-authored-by: rafacanton <[email protected]>
1 parent 5770566 commit 0316972

File tree

3 files changed

+10
-3
lines changed

3 files changed

+10
-3
lines changed

.github/workflows/ci.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,10 @@ jobs:
5555
base_ref=${{ github.base_ref }}
5656
suffix=${ref_name/$sub[0-9][0-9][0-9]/''}
5757
suffix=${suffix/_on_$base_ref/''}
58+
elif [[ "${{ github.base_ref }}" == *"$sub"* ]]; then
59+
base_ref=${{ github.base_ref }}
60+
suffix=${base_ref/$sub[0-9][0-9][0-9]/''}
61+
suffix=${suffix/_on_*/''}
5862
fi
5963
echo "suffix=$suffix" >> "$GITHUB_OUTPUT"
6064
fi

src/ansys/dpf/core/server_types.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -925,6 +925,12 @@ def __init__(
925925
self._context = server_context.AvailableServerContexts.premium
926926
pass
927927
self.set_as_global(as_global=as_global)
928+
# Update the python os.environment
929+
if not os.name == "posix":
930+
new_path = subprocess.check_output(
931+
["python", "-c", r'import os; print(os.environ["PATH"])'], text=True
932+
) # pragma: no cover
933+
os.environ["PATH"] = new_path
928934

929935
@property
930936
def version(self):

tests/test_remote_operator.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
import pytest
77

88

9-
@pytest.mark.skip
109
@pytest.mark.skipif(
1110
not conftest.SERVERS_VERSION_GREATER_THAN_OR_EQUAL_TO_3_0,
1211
reason="Connecting data from different servers is " "supported starting server version 3.0",
@@ -21,7 +20,6 @@ def test_connect_remote_operators(simple_bar):
2120
assert np.allclose(fc[0].data, 2 * op1.outputs.fields_container()[0].data)
2221

2322

24-
@pytest.mark.skip
2523
@pytest.mark.skipif(
2624
not conftest.SERVERS_VERSION_GREATER_THAN_OR_EQUAL_TO_3_0,
2725
reason="Connecting data from different servers is " "supported starting server version 3.0",
@@ -36,7 +34,6 @@ def test_connect_3remote_operators(simple_bar):
3634
assert np.allclose(fc[0].data, 2 * op1.outputs.fields_container()[0].data)
3735

3836

39-
@pytest.mark.skip
4037
@pytest.mark.skipif(
4138
not conftest.SERVERS_VERSION_GREATER_THAN_OR_EQUAL_TO_4_0,
4239
reason="Connecting data from different servers is " "supported starting server version 4.0",

0 commit comments

Comments
 (0)