pysftp vs. Paramiko

梦想与她 提交于 2020-02-20 07:23:29

问题


I have a simple requirement to drop a file on an SFTP server. I have found pysftp and Paramiko libraries that seem to allow me to this and developed a simple application using Paramiko but I can't find a proper source that compares the two so I can decide which one I can/should use. What are the pros and cons for each?


回答1:


pysftp is a wrapper around Paramiko with a more Python-ish interface.

pysftp interface does not expose all of the features of Paramiko. On the other hand, pysftp implements more high-level features on top of Paramiko, notably recursive file transfers.


  • If you do not have any fancy low-level needs (like unusual methods of verifying host key, proxies, etc), use pysftp as it may be easier to work with.

  • If you need low-level features, use Paramiko.

  • If you need both, use Paramiko and check pysftp code for the high-level features.



来源:https://stackoverflow.com/questions/48434941/pysftp-vs-paramiko

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!