Skip to content

Instantly share code, notes, and snippets.

@pga-odoo
Created May 16, 2018 06:24
Show Gist options
  • Select an option

  • Save pga-odoo/8902c561e2fb0cd7edc91b737bc93772 to your computer and use it in GitHub Desktop.

Select an option

Save pga-odoo/8902c561e2fb0cd7edc91b737bc93772 to your computer and use it in GitHub Desktop.
# -*- coding: utf-8 -*-
def _replace_local_links(self, html, base_url=None):
""" replace the links in style
"""
url = "http://www.example.com"
html = re.sub(r"""(<[^>]+\bstyle="[^"]+\burl\('?)(/[^/'][^'")]+)""", url, html)
return html
def _garbage_collect_attachments(self):
""" Test doc string wrong colors
'this' is doc string
"""
test = 'hello workld'
return test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment