Commit d6c0081
Support changes to CLR code when domain reloads
* Adds test cases for member changes during a domain reload
* Rework the serialization of reflected types
Serialization of System.Type, MemberInfo and MethodBase is now string
based. At deserialization, use reflection to attempt to recreate the
object, which may fail safely instead of throwing a
SerializaitonException during the deserialization of the whoie data
stream. Appropriate Exceptions will now be raised when the Maybe*'s
Value property.
ClassBase objects are now de-initialized and re-initialized in Reload
mode so that it's tp_dict picks up newly added members and removed
members no longer linger.
ModuleObject clears it's cache and remove cached members from it's
tp_dict.
Minor refactoring and modernization of MethodObject and MethodBinder
* Call PyType_Modified after modifying the type
Changing a type's attribute causes problem with it's cache. Force the
type to refresh itself when modifying it.
* Refactor the member binding logic of ClassManager
So that we can use that same logic when deserializing Maybe* types
* Include info about why deserialization failed in Maybe*
* Remove TestClassReference
The test case is covered in test_domain_relaod
Co-authored-by: Benedikt Reinartz <filmor@gmail.com>
Co-authored-by: Victor Milovanov <lost@losttech.software>1 parent 0c41273 commit d6c0081
File tree
29 files changed
+2033
-235
lines changed- src
- domain_tests
- embed_tests
- runtime
- StateSerialization
29 files changed
+2033
-235
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
| 18 | + | |
17 | 19 | | |
18 | 20 | | |
19 | 21 | | |
| |||
131 | 133 | | |
132 | 134 | | |
133 | 135 | | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
134 | 148 | | |
135 | 149 | | |
136 | 150 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
0 commit comments