[Debichem-devel] Bug#1085364: bkchem: Python SyntaxWarning

Graham Inggs ginggs at debian.org
Fri Oct 18 17:31:09 BST 2024


Source: bkchem
Version: 0.14.0~pre4+git20211228-4
User: debian-python at lists.debian.org
Usertags: syntaxwarning

Hi Maintainer

The SyntaxWarning below were emitted when this package was tested with
pipuarts[1].

Regards
Graham


[1] https://piuparts.debian.org/sid/source/b/bkchem.html


  Setting up python3 (3.12.5-1) ...
  /usr/share/bkchem/bkchem/arrow.py:431: SyntaxWarning: invalid escape
sequence '\ '
    """arrow head at 2
  /usr/share/bkchem/bkchem/dom_extensions.py:81: SyntaxWarning:
invalid escape sequence '\s'
    empty = re.compile('^\s*$')
  /usr/share/bkchem/bkchem/edit_pool.py:152: SyntaxWarning: invalid
escape sequence '\d'
    self._setText( re.sub( "\d+", '<sub>\g<0></sub>', self.editPool.get()))
  /usr/share/bkchem/bkchem/edit_pool.py:152: SyntaxWarning: invalid
escape sequence '\g'
    self._setText( re.sub( "\d+", '<sub>\g<0></sub>', self.editPool.get()))
  /usr/share/bkchem/bkchem/group.py:132: SyntaxWarning: invalid escape
sequence '\d'
    x = re.sub( "\d+", '<sub>\g<0></sub>', self.symbol)
  /usr/share/bkchem/bkchem/group.py:132: SyntaxWarning: invalid escape
sequence '\g'
    x = re.sub( "\d+", '<sub>\g<0></sub>', self.symbol)
  /usr/share/bkchem/bkchem/group.py:133: SyntaxWarning: invalid escape
sequence '\g'
    x = re.sub( "[+-]", '<sup>\g<0></sup>', x)
  /usr/share/bkchem/bkchem/misc.py:104: SyntaxWarning: invalid escape
sequence '\d'
    cutter = re.compile( "([+-]?\d*\.?\d*)\s*([a-zA-Z]*)")
  /usr/share/bkchem/bkchem/oasa/oasa/coords_generator.py:532:
SyntaxWarning: invalid escape sequence '\O'
    sm = "C/C(Cl)=C(\O)C"
  /usr/share/bkchem/bkchem/oasa/oasa/dom_extensions.py:80:
SyntaxWarning: invalid escape sequence '\s'
    empty = re.compile('^\s*$')
  /usr/share/bkchem/bkchem/oasa/oasa/inchi.py:282: SyntaxWarning:
invalid escape sequence '\('
    re_for_brackets = "\([H\d,\-]+?\)"
  /usr/share/bkchem/bkchem/oasa/oasa/inchi.py:299: SyntaxWarning:
invalid escape sequence '\('
    re_for_brackets = "\([H\d,\-]+?\)"
  /usr/share/bkchem/bkchem/oasa/oasa/inchi.py:498: SyntaxWarning:
invalid escape sequence '\d'
    for a1,a2,sign in re.findall( "(\d+)-(\d+)([-+?u])", layer):
  /usr/share/bkchem/bkchem/oasa/oasa/inchi.py:536: SyntaxWarning:
invalid escape sequence '\('
    re_for_brackets = "\([H\d,\-]+?\)"
  /usr/share/bkchem/bkchem/oasa/oasa/inchi_key.py:1278: SyntaxWarning:
invalid escape sequence '\d'
    m = re.match( "(\d)(S)?", parts[0])
  /usr/share/bkchem/bkchem/oasa/oasa/misc.py:115: SyntaxWarning:
invalid escape sequence '\d'
    cutter = re.compile( "([+-]?\d*\.?\d*)\s*([a-zA-Z]*)")
  /usr/share/bkchem/bkchem/oasa/oasa/molfile.py:101: SyntaxWarning:
invalid escape sequence '\s'
    m = re.match( "M\s+RAD\s+(\d+)(.*)", prop)
  /usr/share/bkchem/bkchem/oasa/oasa/molfile.py:103: SyntaxWarning:
invalid escape sequence '\d'
    for at,rad in re.findall( "(\d+)\s+(\d+)", m.group( 2)):
  /usr/share/bkchem/bkchem/oasa/oasa/molfile.py:107: SyntaxWarning:
invalid escape sequence '\s'
    m = re.match( "M\s+CHG\s+(\d+)(.*)", prop)
  /usr/share/bkchem/bkchem/oasa/oasa/molfile.py:109: SyntaxWarning:
invalid escape sequence '\d'
    for at,chg in re.findall( "(\d+)\s+(-?\d+)", m.group( 2)):
  /usr/share/bkchem/bkchem/oasa/oasa/periodic_table.py:347:
SyntaxWarning: invalid escape sequence '\d'
    a = re.match( '^([a-z]{1,2})(h)(\d*)$', text.lower())
  /usr/share/bkchem/bkchem/oasa/oasa/periodic_table.py:352:
SyntaxWarning: invalid escape sequence '\d'
    a = re.match( '^(h)(\d*)([a-z]{1,2})$', text.lower())
  /usr/share/bkchem/bkchem/oasa/oasa/query_atom.py:111: SyntaxWarning:
invalid escape sequence '\['
    matcher = re.compile( "\[([A-Z][a-z]?,)*[A-Z][a-z]?\]")
  /usr/share/bkchem/bkchem/oasa/oasa/smiles.py:97: SyntaxWarning:
invalid escape sequence '\['
    chunks = re.split( "(\[.*?\]|[A-Z][a-z]?|%[0-9]{1,2}|[^A-Z]|[a-z])", text)
  /usr/share/bkchem/bkchem/oasa/oasa/smiles.py:193: SyntaxWarning:
invalid escape sequence '\['
    bracketed_atom = re.compile("^\[(\d*)([A-z][a-z]?)(.*?)\]")
  /usr/share/bkchem/bkchem/oasa/oasa/smiles.py:206: SyntaxWarning:
invalid escape sequence '\d'
    _hydrogens = re.search( "H(\d*)", rest)
  /usr/share/bkchem/bkchem/oasa/oasa/smiles.py:224: SyntaxWarning:
invalid escape sequence '\d'
    _charge = re.search( "([-+])(\d?)", rest)
  /usr/share/bkchem/bkchem/oasa/oasa/structure_database.py:166:
SyntaxWarning: invalid escape sequence '\['
    if re.search( "\[\d", smile):
  /usr/share/bkchem/bkchem/oasa/test.py:19: SyntaxWarning: invalid
escape sequence '\C'
    mol = oasa.smiles.text_to_mol( "c1ccccc1\C=C/CC")
  /usr/share/bkchem/bkchem/plugins/piddle/pdfgen.py:173:
SyntaxWarning: invalid escape sequence '\('
    s = string.replace(s, '(','\(')
  /usr/share/bkchem/bkchem/plugins/piddle/pdfgen.py:174:
SyntaxWarning: invalid escape sequence '\)'
    s = string.replace(s, ')','\)')
  /usr/share/bkchem/bkchem/plugins/piddle/pdfutils.py:57:
SyntaxWarning: invalid escape sequence '\m'
    """accepts either a filespec ('C:\mydir\*.jpg') or a list
  /usr/share/bkchem/bkchem/plugins/piddle/pdfutils.py:101:
SyntaxWarning: invalid escape sequence '\('
    s = string.replace(s, '(','\(')
  /usr/share/bkchem/bkchem/plugins/piddle/pdfutils.py:102:
SyntaxWarning: invalid escape sequence '\)'
    s = string.replace(s, ')','\)')
  /usr/share/bkchem/bkchem/plugins/piddle/piddlePDF.py:257:
SyntaxWarning: invalid escape sequence '\('
    s = string.replace(s, '(','\(')
  /usr/share/bkchem/bkchem/plugins/piddle/piddlePDF.py:258:
SyntaxWarning: invalid escape sequence '\)'
    s = string.replace(s, ')','\)')
  /usr/share/bkchem/bkchem/plugins/piddle/piddlePS.py:562:
SyntaxWarning: invalid escape sequence '\('
    str = string.replace(str, '(', '\(' )
  /usr/share/bkchem/bkchem/plugins/piddle/piddlePS.py:563:
SyntaxWarning: invalid escape sequence '\)'
    str = string.replace(str, ')', '\)')
  /usr/share/bkchem/bkchem/widgets.py:487: SyntaxWarning: invalid
escape sequence '\d'
    self.text = re.sub( "\d+", '<sub>\g<0></sub>', self.text)
  /usr/share/bkchem/bkchem/widgets.py:487: SyntaxWarning: invalid
escape sequence '\g'
    self.text = re.sub( "\d+", '<sub>\g<0></sub>', self.text)
  /usr/share/bkchem/bkchem/widgets.py:491: SyntaxWarning: invalid
escape sequence '\+'
    self.text = re.sub( "(\+|\.|-)+", '<sup>\g<0></sup>', self.text)
  /usr/share/bkchem/bkchem/widgets.py:491: SyntaxWarning: invalid
escape sequence '\g'
    self.text = re.sub( "(\+|\.|-)+", '<sup>\g<0></sup>', self.text)
  /usr/share/bkchem/bkchem/widgets.py:526: SyntaxWarning: invalid
escape sequence '\d'
    if re.match( "^\d+$", input):



More information about the Debichem-devel mailing list