<feed xmlns='http://www.w3.org/2005/Atom'>
<title>BNW/sourcecodes/input_validate.php, branch main</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<id>http://git.genenetwork.org/BNW/atom?h=main</id>
<link rel='self' href='http://git.genenetwork.org/BNW/atom?h=main'/>
<link rel='alternate' type='text/html' href='http://git.genenetwork.org/BNW/'/>
<updated>2026-08-17T19:52:48+00:00</updated>
<entry>
<title>Guard valid_keyval()/valid_input() against null input (PHP 8.1 deprecation)</title>
<updated>2026-08-17T19:52:48+00:00</updated>
<author>
<name>Claude Sonnet 5</name>
</author>
<published>2026-08-17T19:09:41+00:00</published>
<link rel='alternate' type='text/html' href='http://git.genenetwork.org/BNW/commit/?id=4825da8e49c302392fe6018862dfcdd6f91c6192'/>
<id>urn:sha1:4825da8e49c302392fe6018862dfcdd6f91c6192</id>
<content type='text'>
These two functions are the single most common entry point in the
codebase — ~30+ files call them as valid_keyval($_GET["My_key"]) or
valid_input($_POST[...]) with no isset() guard at the call site. When
the key is absent, PHP passes null straight into trim(), which is a
non-nullable string parameter. As of PHP 8.1 this triggers a
"Passing null to parameter #1 ($string) ... is deprecated" notice on
every one of those call sites, on every request missing the param.

Coalescing to '' inside the two functions themselves fixes this once,
for every caller, instead of patching every call site individually.

Verified empirically against PHP 8.3.28: valid_keyval(null) /
valid_input(null) no longer emit the trim() deprecation notice and
still return '' as before (same effective behavior as PHP 7.4).

Reviewed by: Frederick M Muriithi &lt;fredmanglis@gmail.com&gt;
</content>
</entry>
<entry>
<title>Jan 28 2019 update</title>
<updated>2019-01-28T22:31:54+00:00</updated>
<author>
<name>ziejd2</name>
</author>
<published>2019-01-28T22:31:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.genenetwork.org/BNW/commit/?id=bb9d93322abf825368dedaafc2376ef8fdfc1e2f'/>
<id>urn:sha1:bb9d93322abf825368dedaafc2376ef8fdfc1e2f</id>
<content type='text'>
</content>
</entry>
<entry>
<title>New parameter learning options</title>
<updated>2018-09-14T04:59:20+00:00</updated>
<author>
<name>ziejd2</name>
</author>
<published>2018-09-14T04:59:20+00:00</published>
<link rel='alternate' type='text/html' href='http://git.genenetwork.org/BNW/commit/?id=e3f7237ffcb19f19db3b68777b5a94b89e07f66a'/>
<id>urn:sha1:e3f7237ffcb19f19db3b68777b5a94b89e07f66a</id>
<content type='text'>
The main change here is in the parameter learning methods.  The parameters that are learned at first (i.e., if there is no evidence) are the distributions that are found directly in the data. I had to create or significantly modify several BNT files for this.

If there is evidence, the parameters are learned using a Dirichlet prior. This only required a couple of small changes to the BNW parameter learning files.
</content>
</entry>
</feed>
