Xdebug Update: August 2024
In this monthly update I explain what happened with Xdebug development
GitHub and Pro/Business supporters will get it earlier, around the first of each month.
On GitHub sponsors, I am currently 32% towards my $2,500 per month goal, which is set to allow continued maintenance of Xdebug. This is again less than last month.
If you are leading a team or company, then it is also possible to support Xdebug through a subscription.
In the last month, I spend around 8 hours on Xdebug, with 20 hours funded. I also spent 8.5 hours on the Native Path Mapping project.
PHP 8.4
The large change for the exit-as-a-function proposal has been merged into PHP, which means I had to spend some time finishing and tidying up a Pull Request that Tim Düsterhus had provided.
I also improved Xdebug's CI so that it can run as a separate user.
Right now, there don't seem to be any outstanding issues with PHP 8.4 so I will soon create another alpha (or beta) release so that you can try out Xdebug with the latest beta versions of PHP 8.4's.
Native Xdebug Path Mapping
I continued with the Native Xdebug Path Mapping project.
This is a separately funded project, I don't classify the hours that I worked on this in "Xdebug Hours". I also publish a separate report on the project page.
Again, I am including it here:
I continued with the parser to parse the path mapping files. The parsing is now finished, although I do still need to modify how the parsed information is stored. Right now, the data structures are not optimised to be able to do line mapping as well.
Because the parser parsers user input, it is important that the parser is rubust. It should be able to handle correctly formatted files, but also files with errors.
It is not always possible to come up with all the failure situations by thinking, and therefore a common technique is to use a fuzzer. For PHP there is Infection PHP for mutation testing for example. For C, and C++, a commonly used tool is AFL++. This provides a compiler wrapper and a run-time to fuzz the input to your application. You first provide a template, which it then modifies to try to break your code.
The template that I used in this case was a minimal map file:
remote_prefix: /usr/local/www local_prefix: /home/derick/project /projects/example.php:5-17 = /example.php:8 /example.php:5-17 = /example.php:8-20 /example.php:17 = /example.php:20 /projects/php-web/ = /php-web/
In addition to the template you also need to provide a shim — the program that in my case takes the argument given to it and then parses that as a file. The AFL++ tool's compiler wrapper adds some magic to it to be able to catch errors.
When you then run the fuzzer, such as with:
AFL_SKIP_CPUFREQ=1 afl-fuzz -b 7 -i fuzz-seeds -o fuzz-output -- ./afl-test @@
It then runs your program with your template files (in fuzz-seeds in my example). And then also with loads of variants.
The fuzzer found a few errors in my parser, which ended up crashing it. One such examples that I hadn't thought of is of a line starting with a =:
remote_prefix: /usr/local/www local_prefix: /home/derick/project =/example.php:42-5 = /example.php
You can find the other cases it found in a dedicated test file.
In September I hope to finish the parser (by storing things more efficiently internally) as well as creating APIs to do the mapping.
Xdebug Videos
I have created no new videos since last month, but you can see all the previous ones on my channel.
If you have any suggestions, feel free to reach out to me on Mastodon or via email.
Business Supporter Scheme and Funding
In the last month, no new business supporters signed up.
Besides business support, I also maintain a Patreon page, a profile on GitHub sponsors, as well as an OpenCollective organisation.
If you want to contribute to specific projects, you can find those on the Projects page.
Xdebug Cloud
Xdebug Cloud is the Proxy As A Service platform to allow for debugging in more scenarios, where it is hard, or impossible, to have Xdebug make a connection to the IDE. It is continuing to operate as Beta release.
Packages start at £49/month, and I have recently introduced a package for larger companies. This has a larger initial set of tokens, and discounted extra tokens.
If you want to be kept up to date with Xdebug Cloud, please sign up to the mailinglist, which I will use to send out an update not more than once a month.
Life Line
Hiding Away
This lovely creature was scurrying along the paths near the seawall at Purfleet, near RSPB Rainham Marshes.
I think it's a field mouse, but suggestions welcome.
#photography #wildlife #NaturePhotography #mouse #Mousetodon #london
Specify whether public transport stops have tactile paving
Specify whether traffic signals have sound signals
Specify whether traffic signals have a button for pedestrians
Specify whether traffic signals have tactile indications that it's safe to cross
Determine roads lane count
Specify what can be recycled in recycling containers
Survey opening hours
Survey if places still exist
Specify whether pedestrian crossings have islands
Specify road surfaces
Specify whether pedestrian crossings have markings
Specify parking types
Specify motorcycle parking fees
Determine the heights of kerbs at crossings
Specify whether crosswalks have tactile paving
Specify whether roads have lane markings
Specify whether there are cycleways
Specify whether roads have sidewalks
Specify path surfaces
Specify whether kerbs have tactile paving
I walked 6.9km in 1h19m34s
At The Top
This female Stonechat was precariously perched right at the top of this branch. The light was just right on it, and the slightly pastel coloured background frames it nicely.
#photography #Birds #BirdPhotography #BirdsOfFediverse #NaturePhotography #wildlife #RSPB #RainhamMarshes
Merge branch 'v2022'
Address new warning (-Werror=shadow) from newer GCC versions



Shortlink
This article has a short URL available: https://drck.me/xdebug-24aug-isq