Pip: After pip install of lark the __init__.py file is empty

Created on 12 May 2020  ·  3Comments  ·  Source: pypa/pip

Environment

  • pip version: 18.1
  • Python version: 3.7.3
  • OS: Windows 10, Raspbian 10

Description
I freshly downloaded the pip and python to my Windows, installed lark (pip install lark). After running the source which uses lark modules it gave me errors about missing modules from lark. I found out that in the downloaded site-packages/lark/ folder the _ _ init _ _.py file is empty. I have to download and add the file content manually from github in order to use the package. This issue happens only after the fresh installation of the pip, when upgrading an existing one, the case works well, the package is downloaded and the file content is correct.

Expected behavior
The lark package can be used on a freshly set up computer

How to Reproduce

  1. Install latest pip on a computer where it was never installed before
  2. Execute 'pip install lark'
  3. Check the site-packages/lark/_ _ init _ _.py file, the file has no content

We were able to reproduce this on 3 different machines (1xWindows, 2xRaspberryPi's). The issue never happens when upgrading pip instead of a fresh installation.

support

Most helpful comment

Is the lark package mentioned in the ticket https://github.com/voidfiles/lark ? I see that it's __init__.py is indeed empty and the associate PyPi Package also points to the same repo.

The package details when I installed lark in a fresh virtualenv were as follows. That's where I found out the github repo

$ pip show lark
Name: lark
Version: 0.0.4
Summary: Lark is a RESTy interface for python
Home-page: http://github.com/voidfiles/lark
Author: Alex Kessinger
Author-email: [email protected]
License: MIT
Location: /Users/devesh/Desktop/venv/lib/python3.8/site-packages
Requires: Flask, colander, redis, iso8601
Required-by: 

I am guessing you wanted to instead install https://github.com/lark-parser/lark ? For which you need to run pip install lark-parser as per it's docs.

All 3 comments

Is the lark package mentioned in the ticket https://github.com/voidfiles/lark ? I see that it's __init__.py is indeed empty and the associate PyPi Package also points to the same repo.

The package details when I installed lark in a fresh virtualenv were as follows. That's where I found out the github repo

$ pip show lark
Name: lark
Version: 0.0.4
Summary: Lark is a RESTy interface for python
Home-page: http://github.com/voidfiles/lark
Author: Alex Kessinger
Author-email: [email protected]
License: MIT
Location: /Users/devesh/Desktop/venv/lib/python3.8/site-packages
Requires: Flask, colander, redis, iso8601
Required-by: 

I am guessing you wanted to instead install https://github.com/lark-parser/lark ? For which you need to run pip install lark-parser as per it's docs.

Hi deveshks,

Thanks for the hint, yes, it looks like the installed package is from voidfiles. I will take a look what was the initial idea behind installing lark first, then lark-parser in the source what I have to setup.

That's great. Looks like your issue is about mis-identifying the package which was installed, and not related to pip as such. In that case, you can go ahead and close the issue.

Was this page helpful?
0 / 5 - 0 ratings