Status

Firefox Build System
General
ASSIGNED
10 months ago
4 months ago

People

(Reporter: jhford, Assigned: jhford)

Tracking

(Blocks: 1 bug)

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

We should vendor the mohawk library in tree
Created attachment 8901761 [details] [diff] [review]
vendor-mohawk.diff

This is an extracted copy of the https://pypi.python.org/packages/6e/bf/38a79e76501c5648797fb8193e1e62996b99fc531fb38835ce4741d43217/mohawk-0.3.4-py2-none-any.whl#md5=49723647fb95d4712ed5049f280b45c0 wheel into the vendoring directory.  No changes to the code were made and I verified that ./mach python did allow me to import mohawk correctly.

$ ./mach python
Python 2.7.13 (default, Jul 18 2017, 09:17:00)
[GCC 4.2.1 Compatible Apple LLVM 8.1.0 (clang-802.0.42)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import mohawk
>>> mohawk.__file__
'/Users/jhford/taskcluster/mozilla-central/third_party/python/mohawk/mohawk/__init__.py'
Assignee: nobody → jhford
Status: NEW → ASSIGNED
Attachment #8901761 - Flags: review?(gps)

Comment 2

10 months ago
Comment on attachment 8901761 [details] [diff] [review]
vendor-mohawk.diff

Review of attachment 8901761 [details] [diff] [review]:
-----------------------------------------------------------------

Please use the .tar.gz archive for importing. Specifically, we should have a setup.py for every package.

Otherwise, this import looks fine.
Attachment #8901761 - Flags: review?(gps) → review-

Comment 3

10 months ago
Oh, the egg-info directory can also be removed as part of the import. Its contents are derived from packaging.
(In reply to Gregory Szorc [:gps] from comment #2)
> Comment on attachment 8901761 [details] [diff] [review]
> vendor-mohawk.diff
> 
> Review of attachment 8901761 [details] [diff] [review]:
> -----------------------------------------------------------------
> 
> Please use the .tar.gz archive for importing. Specifically, we should have a
> setup.py for every package.
> 
> Otherwise, this import looks fine.

Do we automatically invoke setup.py?  I didn't see that happening somewhere, so I thought the committed files were the result of having done the build

Comment 5

10 months ago
We don't usually invoke setup.py. However, it is nice to have around in case we need to.

The reason we don't generally invoke setup.py today is because we resort to sys.path and .pth hacks to populate virtualenvs. We may not always do this. Python 3 support may force our hand into using proper virtualenvs. And that requires setup.py files.

Updated

4 months ago
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.