import webbrowser
IEPath = r'C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe' # #例如我的:C:/Program Files/Internet Explorer/iexplore.exe
webbrowser.register('IE', None, webbrowser.BackgroundBrowser(IEPath)) # 这里的'IE'可以用其它任意名字,如IE11,这里将想打开的浏览器保存到'IE'
webbrowser.get('IE').open('https://www.csdn.net/', new=1, autoraise=True)