1.json import json dump, load 2.import pickle https://www.cnblogs.com/buildydream/p/10171938.html http://www.75271.com/11505.html 3. byte<-->str import sys encode, decoce 4.url encode/decode import urllib.parse https://www.cnblogs.com/caicaihong/p/5687522.html urllib.parse.quote(s) urllib.parse.unquote(s) urllib.parse.urlencode(values) 5.webdriver https://selenium-python.readthedocs.io/ pip install selenium #################################### from selenium import webdriver from selenium.webdriver.common.keys import Keys browser = webdriver.Firefox() browser.get('http://www.yahoo.com') assert 'Yahoo' in browser.title elem = browser.find_element_by_name('p') # Find the search box elem.send_keys('seleniumhq' + Keys.RETURN) browser.quit() #################################### https://pypi.org/project/selenium/ https://qiita.com/kinpira/items/383b0fbee6bf229ea03d 6.获取cookie # 获取cookie列表 browser = webdriver.Chrome() browser.get("http://xxxxxx") cookie_list = browser.get_cookies() # 格式化打印cookie for cookie in cookie_list: val=cookie['value'] print(cookie['name'], "--", urllib.parse.unquote(val)) ########################################## https://www.cnblogs.com/lizm166/p/10008634.html