- Notifications
You must be signed in to change notification settings - Fork35
Commite44aa98
authored
RemoteOperations::exec_command explicitly transfers LANG, LANGUAGE and LC_* envvars to the server side (#187)
* RemoteOperations::exec_command updated- Exact enumeration of supported 'cmd' types- Refactoring* RemoteOperations::exec_command explicitly transfers LANG, LANGUAGE and LC_* envvars to the server sideIt should help resolve a problem with replacing a LANG variable by ssh-server.History.On our internal tests we got a problem on the Debian 11 and PostgresPro STD-13.One test returned the error from initdb:initdb: error: collations with different collate and ctype values ("en_US.UTF-8" and "C.UTF-8" accordingly) are not supported by ICU- TestRunner set variable LANG="C"- Python set variable LC_CTYPE="C.UTF-8"- Test call inidb through command "ssh test@localhost inidb -D ...."- SSH-server replaces LANG with value "en_US.UTF-8" (from etc/default/locale)- initdb calculate collate through this value of LANG variable and get en_US.UTF-8So we have that:- ctype is C.UTF-8- collate is en_US.UTF-8ICU on the Debuan-11 (uconv v2.1 ICU 67.1) does not suppot this combination and inidb rturns the error.This patch generates a new command line for ssh:ssh test@localhost "LANG=\"...\";LC_xxx=\"...\";<command>"It resolves this problem with initdb and should help resolve other problems with execution of command through SSH.Amen.* New tests in TestgresRemoteTests are addedNew tests: - test_init__LANG_С - test_init__unk_LANG_and_LC_CTYPE* TestgresRemoteTests.test_init__unk_LANG_and_LC_CTYPE is updatedLet's test bad data with '\' and '"' symbols.* Static methods are marked with@staticmethod [thanks to Victoria Shepard]The following methods of RemoteOperations were corrected: - _make_exec_env_list - _does_put_envvar_into_exec_cmd - _quote_envvar* TestRemoteOperations::_quote_envvar is updated (typification)1 parent7fd2f07 commite44aa98
File tree
2 files changed
+124
-1
lines changed- testgres/operations
- tests
2 files changed
+124
-1
lines changedLines changed: 45 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
87 | 87 |
| |
88 | 88 |
| |
89 | 89 |
| |
90 |
| - | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
91 | 96 |
| |
92 | 97 |
| |
93 | 98 |
| |
| |||
510 | 515 |
| |
511 | 516 |
| |
512 | 517 |
| |
| 518 | + | |
| 519 | + | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
| 554 | + | |
| 555 | + | |
| 556 | + | |
513 | 557 |
| |
514 | 558 |
| |
515 | 559 |
| |
|
Lines changed: 79 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
119 | 119 |
| |
120 | 120 |
| |
121 | 121 |
| |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
122 | 195 |
| |
123 | 196 |
| |
124 | 197 |
| |
| |||
994 | 1067 |
| |
995 | 1068 |
| |
996 | 1069 |
| |
| 1070 | + | |
| 1071 | + | |
| 1072 | + | |
| 1073 | + | |
| 1074 | + | |
| 1075 | + | |
997 | 1076 |
| |
998 | 1077 |
| |
999 | 1078 |
| |
|
0 commit comments
Comments
(0)