~/talk

Review unknown code with static analysis

Talkat Dutch PHP Conference 2017 · 2017-06-29..07-01· [testing]
slides:none on file

Static analysis inspects a 3,000‑file PHP codebase and produces concrete findings: 3,000 files, 5,000+ warnings from tools like PHPStan/Phan and tokenizer/AST queries, plus php -l linting. Results show a web app with templates, file uploads, GD, XML, MySQL/PDO and mPDF, extensive duplication (translation function defined ~32 times), heavy use of old PHP 5.x patterns (no namespaces, array() syntax), many $model variables, nested ternaries and compatibility issues for PHP7, and pinpointed file/line fixes ready for triage.

AI-written summary · about

  1. 0:00Intro
  2. 1:14Review this code
  3. 2:09How to review code
  4. 4:00Source code is structured
  5. 16:43Application favorites
  6. 23:13Clean code for PHP
  7. 24:12Results by files Filename Overview
  8. 25:17Exakat : 350 analysis
  9. 28:49PHP 7.0 compatibility
  10. 29:51Automated code review
  11. 31:43Semantics and definitions
  12. 32:33AST diagram
  13. 33:35Flow Control Graph
  14. 34:17Data Dependency Graph
  15. 40:01PHP 7 helps static analysis
  16. 40:29PHP LINT - 7.0/1
  17. 42:23PHP LINT - 5.4/5/6 - 7.2
  18. 46:18What does this app do?
  19. 47:51Classes
  20. 51:16Variables
  21. 53:26Large application
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.