| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Ignore and print loader error and proceed with loading if possible.
PR requirements
|
Can you give an example and a testcase for this? If we fail to load types, I'd rather have clr.AddReference error out entirely, and it should certainly not write to stderr. |
Sorry, something went wrong.
There is no error in calling clr.AddReference(). |
Sorry, something went wrong.
|
Console is not a proper way to report errors. Either AddReference should throw or (if that can't be allowed due to backward compatibility concerns if it would fail too often) we should provide a generic DLL loading error handler (e.g. event OnLoadError). Dumping such errors to Debug.WriteLine or Python's warning module (undesirable due to new dependency) would also be acceptable, but a generic handler would still be needed. |
Sorry, something went wrong.
|
There are direct C-API functions to issue warnings: https://docs.python.org/3/c-api/exceptions.html#issuing-warnings |
Sorry, something went wrong.
|
A verbose flag to enable/disable warning/error console print would be an alternative |
Sorry, something went wrong.
updated to use Debug
|
Closing as the requested changes were not implemented. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
What does this implement/fix? Explain your changes.
Ignore and print loader error and proceed with loading if possible.
There are cases where
"import " in python failed even when clr.AddReference() succeeded, especially when loading "manipulated (probably protected/obfuscated)" C# DLL.
Does this close any currently open issues?
unknown
Any other comments?
Checklist
Check all those that are applicable and complete.