Commit 50cb69e
PHP 8.1 > Compatibility
sfYamlInline, backport fix from Symfony1.
Doctrine_Hydrator_Graph fix array_map, rtrim(): Passing null to parameter #1 ($string) of type string is deprecated
I emmit the hypothese that this array_map was broken, because array_map result is not assigned.
Doctrine_Migration_Diff:333, str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated
Doctrine_Migration_Builder:78:, is_dir(): Passing null to parameter #1 ($filename) of type string is deprecated
Doctrine_Validator_Notblank, allow null value
HydrationListener, in HydrateTestCase.php, fix strtoupper(): Passing null to parameter #1 ($string) of type string is deprecated
internal_method_return_types
https://wiki.php.net/rfc/internal_method_return_types
see 2b2d173 for details
Doctrine_Collection_OnDemand
Doctrine_Validator_Exception
PHP 8.1 PDO stringify is now disable by default.
Activate it for Mysql + Sqlite
https://www.php.net/manual/en/migration81.incompatible.php#migration81.incompatible.pdo.mysql
PHP 8.1 Fix: Warning: strtotime() : Epoch doesn't fit in a PHP integer in Doctrine_Record.
This is only happening on 32bit system, because int 32bit could not map the whole strtotime date scope.
Example value: "0000-00-00 00:00:00"
Before 8.1 strtotime returns false, after it return false but also raise a Warning.
@ is slightly lowering performance, it should not trigger any unwanted error, as if format is invalid strtotime should return "false"
As this old project need BC for old system, seems the best fix.
PHP 8.1 > Automatic conversion of false to array is deprecated
Fix Doctrine_Record _invokedSaveHooks cannot assign array value to boolean
Declaration to array instead of boolean
PHP 8.1 > Serializable Phase Out
https://wiki.php.net/rfc/phase_out_serializable
PHP 7.4 add a new Serialize mecanism
PHP 8.1 made old method, "Serializable implementation" deprecated
PHP 9.0 (no release date at this moment) will drop the support.
Temporary Fix: Adding both method serialize/unserialize and __serialize/__unserialize
In order to be compatible with future PHP 9.0, once it will be release, we will have to drop the support to PHP Version before 7.4.
Currently a lot of Unix distribution in LTS are running a PHP Version older than 7.4 so moving to the final solution of "add return type" should break a lot of setup for the moment.
PHP 8.1 > internal_method_return_types
https://wiki.php.net/rfc/internal_method_return_types
PHP 8.0 added return type for abstract methods on Iterator, ArrayAccess, Countable, IteratorAggregate
PHP 8.1 made non implementation as a Deprecated Warning
PHP 9.0 (no release date at this moment) will drop the support.
Temporary Fix : adding this Attribute
#[\ReturnTypeWillChange]
Will drop the Deprecated warning.
Adding return type will break compatibility before PHP 7.4,
Return type has been added on PHP 7.0, but "mixed" special type is required, and it has been added on PHP 7.4.
In order to be compatible with future PHP 9.0, once it will be release, we will have to drop the support to PHP Version before 7.4
Currently a lot of Unix distribution in LTS are running a PHP Version older than 7.4 so moving to the final solution of "add return type" should break a lot of setup for the moment.
Update Travis to PHP up to 8.1
PHP 8.0 > Doctrine_Query:36, uncaught TypeError: Unsupported operand types: string % int
Doctrine_Parser_Xml:89, htmlspecialchars(): Passing null to parameter #1 ($string) of type string is deprecated
https://wiki.php.net/rfc/internal_method_return_types for
Doctrine_Node
Doctrine_Adapter_Mock
Doctrine_EventListener_TestLogger
Doctrine_Parser_Xml
Doctrine_Ticket_1254_TestCase, replace stftime() by date() with format adaptation.1 parent 27943d7 commit 50cb69e
File tree
29 files changed
+243
-70
lines changed- lib/Doctrine
- Adapter
- Collection
- Connection
- Hydrator
- Migration
- Parser
- sfYaml
- Record
- Table
- Validator
- tests
- Ticket
29 files changed
+243
-70
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
7 | | - | |
8 | | - | |
9 | | - | |
10 | 6 | | |
| 7 | + | |
| 8 | + | |
11 | 9 | | |
12 | 10 | | |
13 | 11 | | |
| |||
18 | 16 | | |
19 | 17 | | |
20 | 18 | | |
| 19 | + | |
21 | 20 | | |
22 | 21 | | |
23 | 22 | | |
24 | 23 | | |
25 | | - | |
| 24 | + | |
26 | 25 | | |
27 | 26 | | |
28 | 27 | | |
29 | 28 | | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
30 | 38 | | |
31 | 39 | | |
32 | 40 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
| 92 | + | |
92 | 93 | | |
93 | 94 | | |
94 | 95 | | |
| |||
100 | 101 | | |
101 | 102 | | |
102 | 103 | | |
| 104 | + | |
103 | 105 | | |
104 | 106 | | |
105 | 107 | | |
| |||
112 | 114 | | |
113 | 115 | | |
114 | 116 | | |
| 117 | + | |
115 | 118 | | |
116 | 119 | | |
117 | 120 | | |
| |||
131 | 134 | | |
132 | 135 | | |
133 | 136 | | |
| 137 | + | |
134 | 138 | | |
135 | 139 | | |
136 | 140 | | |
| |||
146 | 150 | | |
147 | 151 | | |
148 | 152 | | |
| 153 | + | |
149 | 154 | | |
150 | 155 | | |
151 | 156 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
238 | 238 | | |
239 | 239 | | |
240 | 240 | | |
| 241 | + | |
241 | 242 | | |
242 | 243 | | |
243 | 244 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
| 145 | + | |
145 | 146 | | |
146 | 147 | | |
147 | 148 | | |
148 | | - | |
| 149 | + | |
149 | 150 | | |
150 | 151 | | |
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 | + | |
152 | 177 | | |
153 | 178 | | |
154 | 179 | | |
| |||
160 | 185 | | |
161 | 186 | | |
162 | 187 | | |
163 | | - | |
| 188 | + | |
164 | 189 | | |
165 | 190 | | |
166 | 191 | | |
167 | | - | |
| 192 | + | |
168 | 193 | | |
169 | | - | |
| 194 | + | |
170 | 195 | | |
171 | | - | |
| 196 | + | |
172 | 197 | | |
173 | 198 | | |
174 | 199 | | |
175 | 200 | | |
176 | | - | |
177 | 201 | | |
178 | | - | |
| 202 | + | |
179 | 203 | | |
180 | 204 | | |
181 | 205 | | |
| |||
432 | 456 | | |
433 | 457 | | |
434 | 458 | | |
| 459 | + | |
435 | 460 | | |
436 | 461 | | |
437 | 462 | | |
| |||
1036 | 1061 | | |
1037 | 1062 | | |
1038 | 1063 | | |
| 1064 | + | |
1039 | 1065 | | |
1040 | 1066 | | |
1041 | 1067 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
| 67 | + | |
67 | 68 | | |
68 | 69 | | |
69 | 70 | | |
| |||
73 | 74 | | |
74 | 75 | | |
75 | 76 | | |
| 77 | + | |
76 | 78 | | |
77 | 79 | | |
78 | 80 | | |
79 | 81 | | |
80 | 82 | | |
| 83 | + | |
81 | 84 | | |
82 | 85 | | |
83 | 86 | | |
84 | 87 | | |
85 | 88 | | |
| 89 | + | |
86 | 90 | | |
87 | 91 | | |
88 | 92 | | |
89 | 93 | | |
90 | 94 | | |
91 | 95 | | |
92 | 96 | | |
| 97 | + | |
93 | 98 | | |
94 | 99 | | |
95 | 100 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1178 | 1178 | | |
1179 | 1179 | | |
1180 | 1180 | | |
| 1181 | + | |
1181 | 1182 | | |
1182 | 1183 | | |
1183 | 1184 | | |
| |||
1188 | 1189 | | |
1189 | 1190 | | |
1190 | 1191 | | |
| 1192 | + | |
1191 | 1193 | | |
1192 | 1194 | | |
1193 | 1195 | | |
| |||
1606 | 1608 | | |
1607 | 1609 | | |
1608 | 1610 | | |
| 1611 | + | |
1609 | 1612 | | |
1610 | 1613 | | |
1611 | 1614 | | |
1612 | 1615 | | |
1613 | 1616 | | |
1614 | 1617 | | |
1615 | 1618 | | |
1616 | | - | |
1617 | | - | |
1618 | | - | |
| 1619 | + | |
| 1620 | + | |
1619 | 1621 | | |
1620 | 1622 | | |
1621 | 1623 | | |
| |||
1629 | 1631 | | |
1630 | 1632 | | |
1631 | 1633 | | |
1632 | | - | |
| 1634 | + | |
| 1635 | + | |
| 1636 | + | |
| 1637 | + | |
| 1638 | + | |
| 1639 | + | |
| 1640 | + | |
| 1641 | + | |
| 1642 | + | |
| 1643 | + | |
| 1644 | + | |
| 1645 | + | |
| 1646 | + | |
| 1647 | + | |
| 1648 | + | |
| 1649 | + | |
| 1650 | + | |
| 1651 | + | |
| 1652 | + | |
| 1653 | + | |
| 1654 | + | |
| 1655 | + | |
| 1656 | + | |
| 1657 | + | |
| 1658 | + | |
| 1659 | + | |
1633 | 1660 | | |
1634 | 1661 | | |
1635 | 1662 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
88 | 93 | | |
89 | 94 | | |
90 | 95 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
71 | | - | |
72 | | - | |
| 71 | + | |
| 72 | + | |
73 | 73 | | |
74 | 74 | | |
75 | 75 | | |
| |||
109 | 109 | | |
110 | 110 | | |
111 | 111 | | |
112 | | - | |
| 112 | + | |
113 | 113 | | |
114 | 114 | | |
115 | 115 | | |
| |||
123 | 123 | | |
124 | 124 | | |
125 | 125 | | |
126 | | - | |
| 126 | + | |
127 | 127 | | |
128 | 128 | | |
129 | 129 | | |
| |||
134 | 134 | | |
135 | 135 | | |
136 | 136 | | |
| 137 | + | |
137 | 138 | | |
138 | 139 | | |
139 | 140 | | |
140 | 141 | | |
141 | 142 | | |
142 | 143 | | |
143 | 144 | | |
144 | | - | |
| 145 | + | |
145 | 146 | | |
146 | 147 | | |
147 | | - | |
| 148 | + | |
| 149 | + | |
148 | 150 | | |
149 | 151 | | |
150 | 152 | | |
| |||
154 | 156 | | |
155 | 157 | | |
156 | 158 | | |
157 | | - | |
| 159 | + | |
158 | 160 | | |
159 | 161 | | |
160 | 162 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
68 | | - | |
| 68 | + | |
69 | 69 | | |
70 | 70 | | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
71 | 77 | | |
72 | 78 | | |
73 | 79 | | |
| |||
87 | 93 | | |
88 | 94 | | |
89 | 95 | | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
90 | 99 | | |
91 | 100 | | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
92 | 108 | | |
93 | 109 | | |
94 | 110 | | |
| |||
0 commit comments