jw.pkg.App: Remove .debug() and friends

Replace the jw.pkg.App.debug(), .warn() and .err() methods by the global log() function. There's no obvious benefit in having App know what's logged.

Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
Jan Lindemann 2026-01-25 15:18:27 +01:00
commit 95fa2f0d06
8 changed files with 39 additions and 41 deletions

View file

@ -2,6 +2,7 @@
from argparse import Namespace, ArgumentParser
from ...lib.log import *
from ..Cmd import Cmd
class CmdCheck(Cmd): # export
@ -22,10 +23,10 @@ class CmdCheck(Cmd): # export
temp = set()
while len(unvisited) != 0:
m = unvisited[0]
self.app.debug('Checking circular dependency of', m)
log(DEBUG, 'Checking circular dependency of', m)
last = self.app.check_circular_deps(m, args.flavour, self.app.flip_graph(graph), unvisited, temp, path)
if last is not None:
self.app.debug('Found circular dependency below', m, ', last is', last)
log(DEBUG, 'Found circular dependency below', m, ', last is', last)
print('Found circular dependency in flavour', args.flavour, ':', ' -> '.join(path))
exit(1)
print('No circular dependency found for flavour', args.flavour, ' in modules:',