問題描述
SmugMug 的變化似乎炸毀了 pysmug (changes at SmugMug appear to have blown up pysmug)
還有其他人正在努力解決感恩節前一周在 SmugMug 進行的更改,這些更改導致在使用 pysmug 和 Django 時出現“無效用戶”錯誤?
有人建議他們現在需要 _su cookie,但在我看來,pysmug 中使用的 pycurl 應該可以正確處理。
登錄時不會發生錯誤,所以我假設錯誤消息“無效用戶”是假的。
## 參考解法 #### 方法 1:
For anyone else having pysmug trouble the following patch fixed the issue:
pysmug's implementation of pycurl does not set a cookie jar. To fix the problem, add the following two lines to smugmug.py at line number #143 and reinstall:
c.setopt(c.COOKIEFILE, 'cookies.txt')
c.setopt(c.COOKIEJAR, 'cookies.txt')
You may want to set an absolute path to cookies.txt to make sure it's getting written to a folder with the necessary permissions, i.e. /tmp/