无法安装scrapy-deltafetch

时间:2016-07-24 21:58:40

标签: python python-2.7 scrapy

我正在尝试使用pip(python 2.7上的v8.1.2)在ubuntu 14上安装scrapy-deltafetch。当我运行(sudo)pip install scrapy-deltafetch时,我收到以下错误:

更新

Complete output from command python setup.py egg_info:
Can't find a local Berkeley DB installation.
  Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-TVr3UZ/bsddb3/

有关如何解决此问题的任何想法?

我已经运行了以下内容:

sudo python ez_setup.py

pip install --upgrade setuptools

以及

sudo apt-get install python-setuptools

我在计算机上同时拥有python3和python 2.7。

我尝试过安装bsdb3,但这也不起作用。我将研究如何正确设置berkeley db并在此更新

更新: 安装berkeley DB并没有解决问题。

2 个答案:

答案 0 :(得分:1)

scrapy-deltafetch需要bsddb3

bsddb3本身,在Ubuntu Trusty上,depends on libdb5.3

您可以使用python-bsddb3安装apt-get,也可以apt-get install libdb5.3安装pip install scrapy-deltafetch- (void)viewWillAppear:(BOOL)animated { [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(keyboardWillShow:) name:UIKeyboardWillShowNotification object:nil]; [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(keyboardWillHide:) name:UIKeyboardWillHideNotification object:nil]; } - (void)viewWillDisappear:(BOOL)animated { [[NSNotificationCenter defaultCenter] removeObserver:self name:UIKeyboardWillShowNotification object:nil]; [[NSNotificationCenter defaultCenter] removeObserver:self name:UIKeyboardWillHideNotification object:nil]; } #pragma mark - keyboard movements - (void)keyboardWillShow:(NSNotification *)notification { CGSize keyboardSize = [[[notification userInfo] objectForKey:UIKeyboardFrameBeginUserInfoKey] CGRectValue].size; [UIView animateWithDuration:0.3 animations:^{ CGRect f = self.view.frame; f.origin.y = -keyboardSize.height; self.view.frame = f; }]; } -(void)keyboardWillHide:(NSNotification *)notification { [UIView animateWithDuration:0.3 animations:^{ CGRect f = self.view.frame; f.origin.y = 0.0f; self.view.frame = f; }]; } 应该在那之后工作。

答案 1 :(得分:1)

首先安装libbd-dev,

sudo apt-get install libdb-dev

然后安装deltafetch,

# for python2
sudo -H pip install scrapy-deltafetch
# for python3
sudo -H pip3 install scrapy-deltafetch