for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
# -*- coding: utf-8 -*-
The coding style of this project requires that you add a docstring to this code element. Below, you find an example for methods:
class SomeClass: def some_method(self): """Do x and return foo."""
If you would like to know more about docstrings, we recommend to read PEP-257: Docstring Conventions.
import re
from bs4 import BeautifulSoup
def get_tip(html):
''' 获取页面提示信息 '''
tips = re.findall(r">alert\(\'(.*?)\'", html)
if tips:
return tips[0]
def get_view_state_from_html(html):
''' 获取 __VIEWSTATE 值 '''
pre_soup = BeautifulSoup(html, "html.parser")
view_state = pre_soup.find(
attrs={"name": "__VIEWSTATE"})['value']
return view_state
The coding style of this project requires that you add a docstring to this code element. Below, you find an example for methods:
If you would like to know more about docstrings, we recommend to read PEP-257: Docstring Conventions.