Skip to content

Commit 78d7185

Browse files
committed
fix: no fstrings yet
1 parent 9e98a43 commit 78d7185

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

nginx.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -454,47 +454,47 @@ def loads(data, conf=True):
454454
n = re.compile(r'(?!\B"[^"]*);(?![^"]*"\B)')
455455
m = re.compile(r'^\s*location\s+(.*?".*?".*?|.*?)\s*{').search(data[index:])
456456
if m and not n.search(m.group()):
457-
logging.debug(f"Open (Location) {m.group(1)}")
457+
logging.debug("Open (Location) {0}".format(m.group(1)))
458458
l = Location(m.group(1))
459459
lopen.insert(0, l)
460460
index += m.end()
461461
continue
462462

463463
m = re.compile(r'^\s*if\s+(.*?".*?".*?|.*?)\s*{').search(data[index:])
464464
if m and not n.search(m.group()):
465-
logging.debug(f"Open (If) {m.group(1)}")
465+
logging.debug("Open (If) {0}".format(m.group(1)))
466466
ifs = If(m.group(1))
467467
lopen.insert(0, ifs)
468468
index += m.end()
469469
continue
470470

471471
m = re.compile(r'^\s*upstream\s+(.*?)\s*{').search(data[index:])
472472
if m and not n.search(m.group()):
473-
logging.debug(f"Open (Upstream) {m.group(1)}")
473+
logging.debug("Open (Upstream) {0}".format(m.group(1)))
474474
u = Upstream(m.group(1))
475475
lopen.insert(0, u)
476476
index += m.end()
477477
continue
478478

479479
m = re.compile(r'^\s*geo\s+(.*?".*?".*?|.*?)\s*{').search(data[index:])
480480
if m and not n.search(m.group()):
481-
logging.debug(f"Open (Geo) {m.group(1)}")
481+
logging.debug("Open (Geo) {0}".format(m.group(1)))
482482
g = Geo(m.group(1))
483483
lopen.insert(0, g)
484484
index += m.end()
485485
continue
486486

487487
m = re.compile(r'^\s*map\s+(.*?".*?".*?|.*?)\s*{').search(data[index:])
488488
if m and not n.search(m.group()):
489-
logging.debug(f"Open (Map) {m.group(1)}")
489+
logging.debug("Open (Map) {0}".format(m.group(1)))
490490
g = Map(m.group(1))
491491
lopen.insert(0, g)
492492
index += m.end()
493493
continue
494494

495495
m = re.compile(r'^\s*limit_except\s+(.*?".*?".*?|.*?)\s*{').search(data[index:])
496496
if m and not n.search(m.group()):
497-
logging.debug(f"Open (LimitExcept) {m.group(1)}")
497+
logging.debug("Open (LimitExcept) {0}".format(m.group(1)))
498498
l = LimitExcept(m.group(1))
499499
lopen.insert(0, l)
500500
index += m.end()
@@ -510,7 +510,7 @@ def loads(data, conf=True):
510510

511511
m = re.compile(r'^(\s*)#[ \r\t\f]*(.*?)\n').search(data[index:])
512512
if m:
513-
logging.debug(f"Comment ({m.group(2)})")
513+
logging.debug("Comment ({0})".format(m.group(2)))
514514
c = Comment(m.group(2), inline='\n' not in m.group(1))
515515
if lopen and isinstance(lopen[0], Container):
516516
lopen[0].add(c)
@@ -544,7 +544,7 @@ def loads(data, conf=True):
544544
s = r'^\s*({})\s*((?:{})+);'.format(s1, s1)
545545
m = re.compile(s).search(data[index:])
546546
if m:
547-
logging.debug(f"Key {m.group(1)} {m.group(2)}")
547+
logging.debug("Key {0} {1}".format(m.group(1), m.group(2)))
548548
k = Key(m.group(1), m.group(2))
549549
if lopen and isinstance(lopen[0], (Container, Server)):
550550
lopen[0].add(k)
@@ -555,7 +555,7 @@ def loads(data, conf=True):
555555

556556
m = re.compile(r'^\s*(\S+);').search(data[index:])
557557
if m:
558-
logging.debug(f"Key {m.group(1)}")
558+
logging.debug("Key {0}".format(m.group(1)))
559559
k = Key(m.group(1), '')
560560
if lopen and isinstance(lopen[0], (Container, Server)):
561561
lopen[0].add(k)

0 commit comments

Comments
 (0)