Skip to content

chore: remove Logtalk files and mentions - #697

Merged
hyperpolymath merged 2 commits into
mainfrom
claude/remove-logtalk
Nov 17, 2026
Merged

hyperpolymath merged 2 commits into
mainfrom
claude/remove-logtalk

Conversation

@hyperpolymath

@hyperpolymath hyperpolymath commented Nov 17, 2026 •

Copy link
Copy Markdown
Owner

Summary

Owner ruling: eliminate Logtalk completely, including the mention of it. This removes every Logtalk rule file and the generator, report and workflow code that wrote or read them, and records what the rules detected before they go.

What was deleted

  • bots/glambot/bot-integration/src/glambot_findings.lgt
  • shared-context/learning/approved-rules/{eval_usage,technical_debt,unsafe_without_doc}.lgt
  • shared-context/learning/approved-rules/{eval_usage,technical_debt,unsafe_without_doc}.lgt.meta (approval sidecars; the glob in the task did not match them, they are part of the same rules)
  • shared-context/learning/rule-proposals/{eval_usage,getexn_on_external_data,technical_debt,type_safety_bypass,unsafe_crash,unsafe_panic,unsafe_without_doc}.lgt
  • fleet-coordinator.sh: propose_new_rule() (generator with four rule templates) and create_rule_approval_pr() (cloned hypatia, pushed a branch, opened a PR, enabled auto-merge), plus the call sites in learn_from_findings() and generate_rules()
  • learning-monitor.sh: the "Rule Proposals" section and the two "next actions" hints that pointed at it
  • .github/workflows/learning-loop.yml: the "Upload rule proposals" step and the proposals block of the summary step
  • .gitignore: /exports/*.lgt

What was edited

  • fleet-coordinator.sh: header comment, usage() line for generate-rules, a comment in learn_from_findings().
  • Docs and audits reworded to drop the mention: docs/BOT-OPERATIONS.adoc, docs/archive/DOGFOODING-ANALYSIS.adoc, docs/archive/NEW-PATTERNS-DEPLOYMENT-2026-02-06.adoc, bots/finishingbot/ROADMAP.adoc, audits/directive-census-2026-09-26/REPORT.md, audits/fleet-wiring-2026-09-26.md, shared-context/findings/security-audit-20260125.md, shared-context/learning/{ECHIDNA-VALIDATION-SUMMARY,RULE-PROPOSALS-2026-02-06}.adoc. In the dated reports only the Logtalk wording and .lgt file names changed.
  • Three NEUROSYM.a2ml files (.machine_readable/descriptiles/, robot-repo-automaton/.machine_readable/6a2/, robot-repo-automaton/templates/skeleton/.machine_readable/descriptiles/): the line report-format = "logtalk" removed, nothing else. Each remains valid TOML. Nothing in this repo reads the key. (Hypatia's own ledger replaced the value with "json"; I did not add that, since the rule is never to add to an .a2ml.)
  • New: shared-context/learning/RETIRED-LOGTALK-RULES.adoc (plain AsciiDoc, CC-BY-SA-4.0), the record described below.

Trace: what read or wrote the rule files

Writers:

  1. fleet-coordinator.sh process_findings -> learn_from_findings -> propose_new_rule wrote rule-proposals/<type>.lgt once a pattern type reached 5 observations; in CI it then called create_rule_approval_pr (PR into hypatia, auto-merge).
  2. fleet-coordinator.sh generate-rules -> generate_rules called propose_new_rule per pattern type.
  3. The approved-rules/*.lgt files were hand-moved copies of three proposals; the .meta sidecars were approval notes.

Readers:

  1. learning-loop.yml: uploaded rule-proposals/*.lgt as an artifact and listed them in the step summary.
  2. learning-monitor.sh: counted proposals and compared them with a hypatia engine/rules/auto-learned/ directory that no longer exists.
  3. Nothing read approved-rules/*.lgt or glambot_findings.lgt. The deploy-approved-rules job is if: false, and the glambot file's JSON ingestion was a placeholder that returned nothing.

Entry points were already dead: process_findings, generate_rules and deploy_bots return 78 (BLOCKED) before any of this code, per docs/AUTOMATION-QUARANTINE.adoc. So no live behaviour is removed. Deleting the generator also removes the dormant PR-and-auto-merge path into hypatia.

Where each rule went

Hypatia (lib/rules/, read at 6f3f16f; I read the Elixir and did not run it):

Retired rule Hypatia rule Coverage
unsafe_without_doc code_safety.ex unsafe_block + reject_excused_unsafe covered; severity and accepted comment keywords differ
getexn_on_external_data (draft) code_safety.ex getexn_on_external covered
template unpinned_action cicd_rules.ex unpinned_action (canonical: WH004 in workflow_hardening.ex) covered
template missing_permissions cicd_rules.ex missing_permissions covered
template missing_spdx cicd_rules.ex missing_spdx covered
eval_usage code_safety.ex js_eval partial: direct eval( only
technical_debt honest_completion.ex (TODO and FIXME counts), baseline_health.ex BH002 partial: no HACK/XXX/BUG, no per-marker finding or priority

No equivalent, recorded in RETIRED-LOGTALK-RULES.adoc (name, pattern, what it flagged): eval_usage Function-constructor and string setTimeout/setInterval checks, the test/production severity split and the CSP suggestion; technical_debt HACK/XXX/BUG markers, priorities and the 50-marker threshold; the glambot findings bridge (presentation-debt, fleet-wide-pattern and related predicates). type_safety_bypass, unsafe_crash, unsafe_panic and the generic template were stubs whose detection clause ended in fail; there is nothing to port, and the record says so. I did not invent a new rule format.

Checks run

  • bash -n fleet-coordinator.sh learning-monitor.sh: OK.
  • shellcheck: fleet-coordinator.sh 105 -> 90 findings, learning-monitor.sh 1 -> 0. No new finding; the rest pre-date this change.
  • bash tests/automation-quarantine-test.sh: all PASS, including generate-rules exiting 78 with BLOCKED:.
  • actionlint: not installed, not run. yq parses the edited workflow.
  • git grep -n -i -I 'logtalk\|\.lgt\b' on the committed tree: empty.

Needs your decision (not guessed)

  • learning-loop.yml still runs process-findings and generate-rules. Both exit 78 by design, so the workflow already fails visibly; I left that alone. generate-rules now has no function behind it. Retire the command, the steps and the deploy-approved-rules job together if you want.
  • shared-context/learning/rule-deployment-status.json still lists the approved rules (a data record, no Logtalk text); left as is.
  • Hypatia itself still has logtalk_name fields in lib/rules/audit_prevention.ex (outside this change).

Kept, with reason

  • The file name shared-context/learning/RETIRED-LOGTALK-RULES.adoc: the name was specified by the task. Its content does not use the word or the extension, and no other file links to it by name, so the grep stays empty.

Generated by Claude Code

Summary by CodeRabbit

  • Changes
    • Automated rule-proposal generation and its approval workflow are retired. The learning summary continues to report observation counts.
    • Several previously available code-scanning rules and the Glambot findings bridge have been removed, reducing the checks and findings those features provided.
    • The generate-rules command is marked as retired and blocked.
  • Documentation
    • Guides and audit records now describe the retired rule-generation features and updated validation approach.

Delete the 11 rule files (.lgt), the 3 approval sidecars, and the
generator, report and workflow code that wrote or read them. Record what
each rule detected, and its Hypatia coverage, in
shared-context/learning/RETIRED-LOGTALK-RULES.adoc. Reword mentions in
docs and audits; drop the report-format key from three NEUROSYM files.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0165rGu3tsKmJtevmrdMVyfJ
@coderabbitai

coderabbitai Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

Caution

Review failed

The pull request is closed.

Walkthrough

The PR retires the Logtalk-based learning-rule proposal path. It removes proposal generation and reporting, deletes approved and proposed rule files and the Glambot findings bridge, removes Logtalk report-format settings, and updates related documentation. Recording observations for critical and high-severity findings remains.

Changes: Retire learning rules

Layer / File(s) Summary
Stop proposal generation and reporting
.github/workflows/learning-loop.yml, fleet-coordinator.sh, learning-monitor.sh, .gitignore
The coordinator no longer creates or publishes proposals. The workflow no longer uploads or lists them. The monitor no longer reports proposals or suggests proposal-related actions. Critical and high-severity observations are still recorded.
Remove rule implementations and Glambot bridge
shared-context/learning/approved-rules/*, shared-context/learning/rule-proposals/*, bots/glambot/bot-integration/src/glambot_findings.lgt
The approved and proposed Logtalk detectors, approved-rule metadata, and Glambot findings object are deleted.
Update configuration and retirement records
.machine_readable/descriptiles/NEUROSYM.a2ml, robot-repo-automaton/**/NEUROSYM.a2ml, audits/*, bots/finishingbot/ROADMAP.adoc, docs/*, shared-context/findings/*, shared-context/learning/*.adoc
Logtalk report-format settings are removed. Operational, audit, roadmap, and learning documents revise references to Logtalk rules. A new record describes the retired rules, generator, and Glambot bridge.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Change: Other

Possibly related issues

Merge Risk: Moderate · up to 11939

The learning-loop workflow edit leaves a stale entry in the actions lockfile, which fails the lockfile sync check until the lock is regenerated in this PR. A few docs still describe the retired rule generation and deployment flow as active. Fix the lockfile before merging.

- [ ] Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Copy link
Copy Markdown
Owner Author

CI triage, three groups.

Caused by this PR (needs a regenerated lockfile, not yet fixed): actions.lock is in sync with the workflow YAML and governance / Actions lockfile verify. This PR removed the proposals upload step from learning-loop.yml, so .github/workflows/actions.lock now carries a stale entry actions/upload-artifact@v7.0.2 under learning-loop.yml. Both checks name only that one error (main passes both: https://github.com/hyperpolymath/gitbot-fleet/actions/runs/44175712607 and https://github.com/hyperpolymath/gitbot-fleet/actions/runs/44175713618). The prescribed fix is gh actions-lock --no-migrate-local-actions followed by scripts/audit-lock-closure.sh. The gh actions-lock extension is not installed in this environment and installing it was refused, and the lockfile must not be hand-edited, so this is left for someone with the tool. The fix is a one-line prune of that entry.

Already red on main (not this PR's): Pinned source closure (FATAL SOURCE-ACTIVE-MISSING at "Authenticate pinned reusable sources") and E2E tests, which fails only because it requires the closure job to pass. Main run: https://github.com/hyperpolymath/gitbot-fleet/actions/runs/44175712601 (this PR's run: https://github.com/hyperpolymath/gitbot-fleet/actions/runs/44188653924). This PR does not touch scripts/lib/pinned-reusable-sources.json.

Also red: scorecard / Run Scorecard PR, which is one of the estate-wide failures; I did not compare it against main.


Generated by Claude Code

@hyperpolymath
hyperpolymath marked this pull request as ready for review November 17, 2026 22:54
@hyperpolymath
hyperpolymath enabled auto-merge (squash) November 17, 2026 22:54
@sonarqubecloud

Copy link
Copy Markdown

@hyperpolymath
hyperpolymath merged commit 00b83b9 into main Nov 17, 2026
67 of 73 checks passed
@hyperpolymath
hyperpolymath deleted the claude/remove-logtalk branch November 17, 2026 22:58
hyperpolymath pushed a commit that referenced this pull request Nov 18, 2026
…oop.yml

#697 removed the "Upload rule proposals" step from learning-loop.yml but
left actions/upload-artifact@v7.0.2 under that workflow's lock entry. Main
has been red since: check-lock-sync.sh fails on the stale entry and
audit-lock-closure.sh reports FATAL WF-ORPHAN, which fails Pinned source
closure and, through it, E2E tests.

Pruned with standards scripts/prune-stale.sh (the tool step of the lock
repair chain), not by hand. The dependencies: record stays: two other
workflows still use upload-artifact@v7.0.2.

Local, after: check-lock-sync.sh rc=0; audit-lock-closure.sh fatal=0
review=0 accepted=3; lock-closure-test 47 passed, 0 failed (45/2 before);
audit-pinned-reusable-sources.sh --fetch-sources findings=0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01J4QvDjqj5DHRRCrDiGeTmq
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants