Skip to content

Conversation

@dean
Copy link
Contributor

@dean dean commented Aug 22, 2014

This removes (most of) our /vendor directory and replaces the files with requirements files installable via peep[1]. Existing requirement files were also updated to be peep compatible, so we can use it for all of our package installations. Everything seems to work fine in my dev environment and all tests pass, other than some DeprecationWarnings.

Finally, PIL was replaced with Pillow since we were already planning on switching and all these changes will need to be heavily tested on dev anyways. #1984

r?

@mythmon
Copy link
Contributor

mythmon commented Aug 22, 2014

You say "most of" vendor. What do you mean by that? Since the diff is so huge this time, it's hard to check for myself.

NB: Since we would be installing from peep/pip every deploy now, compiled packages should be easier. It might make deploys take longer though. Or we could keep doing what we do now and not actually use peep to install the compiled stuff anyways.

@dean
Copy link
Contributor Author

dean commented Aug 22, 2014

There's still a /vendor/tarballs package. It keeps ES/Redis and a couple other packages for installation. Additionally, I just realized I'll need to fix the deploy script before this hits dev I think.

@willkg
Copy link
Member

willkg commented Aug 22, 2014

One one nice thing about having vendor/ is that when you switch branches or go look at someone else's stuff, the dependencies follow you. when git submodules are out of date, it shows up as being out of date.

With the new system, there's nothing to tell you when your virtual environment is out of sync with regards to the requirements files.

With fjord, we added some code to tell you you're out of sync and it kicks off in manage.py. I think that works, but there are probably usage edge cases where it doesn't. For example, using scripts that import things from kitsune, but don't actually get run by manage.py.

Anyhow, the fjord code is here:

I'm definitely interested in better ways to do it.

Regarding compiling dependencies, that requires the requirements and a compiler be installed on the admin node that's used for deployemnt. If I was a betting man, I would bet that the admin node does not have these things. Definitely worth checking, plus it's worth making sure it's ok with IT that we switch to compiling our own dependencies on deployment.

@dean
Copy link
Contributor Author

dean commented Aug 22, 2014

Thanks for dropping those in here will, that's a nice addition! It might be worth throwing something like that into a library, as this is an issue everyone who uses a requirements file can run into. If I come up with a better way of doing it, I'll let you know too.

As for deployment, we should probably let IT know our intentions so everyone is on the same page.

@rlr
Copy link
Contributor

rlr commented Aug 26, 2014

travis fails. expected?

@mythmon
Copy link
Contributor

mythmon commented Aug 26, 2014

Ha. That's definitely a problem.

OSError: [Errno 2] No such file or directory: '/home/travis/virtualenv/python2.6.9/lib/python2.6/site-packages/product_details/json'

@dean: It looks like it's using the upstream django-mozilla-product-details. Did your patch land on that?

@rlr
Copy link
Contributor

rlr commented Aug 29, 2014

I assume this is on stage now? All cron jobs are erroring out with:

Unknown command: 'cron'
Type 'manage.py help' for usage.

@mythmon
Copy link
Contributor

mythmon commented Aug 29, 2014

Yes, this is on stage. That is the kind of thing we wanted to check. It's probably a problem with virtualenv. We'll have to tweak the crontab to account for that.

@dean
Copy link
Contributor Author

dean commented Sep 3, 2014

requirements/requirements_src.txt temporarily refers to a repo of mine, since the PR to fix jingo-minify is not currently merged. This needs to be fixed when the following PR is merged:
jsocol/jingo-minify#41

@dean
Copy link
Contributor Author

dean commented Sep 3, 2014

Oh, all tests pass now too.

@dean dean force-pushed the peep-1035319 branch 3 times, most recently from 82494e1 to 172bd05 Compare September 9, 2014 18:47
@dean dean force-pushed the peep-1035319 branch 2 times, most recently from 785ef4c to ed15d1e Compare September 18, 2014 23:19
@dean
Copy link
Contributor Author

dean commented Sep 18, 2014

Landed on master:
096f968
6c975ae
1c08bef
ed15d1e

@dean dean closed this Sep 18, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants