22 Commits

Author SHA1 Message Date
Alexey
172ce659b8
Use str_starts_with, str_ends_with and str_contains instead of strpos (#5485) 2022-12-31 13:02:23 +00:00
Dylan K. Taylor
d79e6354a0
Merge branch 'stable' into next-minor 2022-11-25 14:41:05 +00:00
Dylan K. Taylor
6562335120
CrashDump: fixed failure to generate crash report when error messages contain invalid characters
closes #2986
2022-11-15 22:00:20 +00:00
Dylan K. Taylor
7bcc663b60
Migrate core code to using symfony/filesystem
webmozart/path-util is retained for plugin compatibility, but is dropped in 5.0
2022-10-14 21:51:29 +01:00
Dylan K. Taylor
0e73ffe555
CrashDump: Added JIT mode to data
this is necessary for identifying JIT-specific bugs, which, unfortunately, are very common.
2022-08-25 17:39:40 +01:00
Dylan K. Taylor
38d6284671
Use PHP-CS-Fixer to enforce file header presence 2022-06-04 17:34:49 +01:00
Dylan K. Taylor
221c6b8570
Remove useless @var 2022-05-17 20:46:24 +01:00
Dylan K. Taylor
d11d77d328
Modernize private property declarations in src/crash 2022-05-17 20:35:24 +01:00
Dylan K. Taylor
c6374b79b0
Improve crashdump ergonomics
hopefully this will result in less people making useless pastes that don't contain backtraces ...
2022-03-24 19:46:11 +00:00
Dylan K. Taylor
4e956d5d1d
Replace remaining disallowed operators 2022-01-20 19:23:19 +00:00
Dylan K. Taylor
75fc7a2d1f
Merge branch 'stable' into next-minor 2022-01-07 20:16:35 +00:00
Dylan K. Taylor
6d249026cc
Merge branch 'legacy/pm3' into stable 2022-01-07 20:15:15 +00:00
Dylan K. Taylor
77a74d84e2
CrashDump: phpversion() could return false for a loaded extension
if the extension wrote NULL into the zend_module_entry->version field, phpversion() will return false.
2021-12-08 19:58:28 +00:00
Dylan K. Taylor
889d048ca3
Make use of Utils::assumeNotFalse() in a bunch of places
I've stuck to only doing this in the places where I'm sure we should never get false back. Other places I'm less sure of (and I found more bugs along the way).
2021-12-08 19:39:04 +00:00
Dylan K. Taylor
8b73549355
Use JSON_THROW_ON_ERROR for json_encode() and json_decode() 2021-12-08 19:14:07 +00:00
Dylan K. Taylor
533d3aae8b
Merge branch 'stable' 2021-11-26 22:41:18 +00:00
Dylan K. Taylor
020cd7b966
CrashDump: fixed encodedData being uninitialized before getEncodedData() is called 2021-11-22 22:31:07 +00:00
Dylan K. Taylor
c37c261c0f
Separate crashdump file generation from crashdump data collection
this allows CrashDump to be used just to generate data, which will come in useful for non-crash error reporting in the future (e.g. packet decoding errors).
2021-11-22 22:19:40 +00:00
Dylan K. Taylor
4599913034
Separate crashdump rendering from crashdump data collection
this allows this code to be reused for reproducing crashdumps based on the original data.
2021-11-18 00:58:20 +00:00
Dylan K. Taylor
269231c228
Ban foreach(arrayWithStringKeys as k => v)
this is not as good as phpstan/phpstan-src#769 (e.g. array_key_first()/array_key_last() aren't covered by this, nor is array_rand()) but it does eliminate the most infuriating cases where this usually crops up.
2021-11-15 22:52:05 +00:00
Dylan K. Taylor
84f8b3eb2d
Move CrashDump to pocketmine\crash namespace 2021-11-04 19:23:45 +00:00
Dylan K. Taylor
8ac999cbd4
Use object models for crashdump generation 2021-11-04 16:55:04 +00:00