Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 300845
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T06:57:05+00:00 2026-05-12T06:57:05+00:00

Can someone please explain to me what is going on with python in ubuntu

  • 0

Can someone please explain to me what is going on with python in ubuntu 9.04?

I’m trying to spin up virtualenv, and the --no-site-packages flag seems to do nothing with ubuntu. I installed virtualenv 1.3.3 with easy_install (which I’ve upgraded to setuptools 0.6c9) and everything seems to be installed to /usr/local/lib/python2.6/dist-packages

I assume that when installing a package using apt-get, it’s placed in /usr/lib/python2.6/dist-packages/ ?

The issue is, there is a /usr/local/lib/python2.6/site-packages as well that just sits there being empty. It would seem (by looking at the path in a virtualenv) that this is the folder virtualenv uses as backup. Thus even thought I omit --no-site-packages, I cant access my local systems packages from any of my virtualenv’s.

So my questions are:

  1. How do I get virtualenv to point to one of the dist-packages?
  2. Which dist-packages should I point it to? /usr/lib/python2.6/dist-packages or /usr/local/lib/python2.6/dist-packages/
  3. What is the point of /usr/lib/python2.6/site-packages? There’s nothing in there!
  4. Is it first come first serve on the path? If I have a newer version of package XYZ installed in /usr/local/lib/python2.6/dist-packages/ and and older one (from ubuntu repos/apt-get) in /usr/lib/python2.6/dist-packages, which one gets imported when I import xyz? I’m assuming this is based on the path list, yes?
  5. Why the hell is this so confusing? Is there something I’m missing here?
  6. Where is it defined that easy_install should install to /usr/local/lib/python2.6/dist-packages?
  7. Will this affect pip as well?

Thanks to anyone who can clear this up!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T06:57:05+00:00Added an answer on May 12, 2026 at 6:57 am

    I’d be tempted to hack it by making site-packages a link to dist-packages, but I guess this might affect other cases where you want to install some extension other than from the ubuntu dist. I can’t think of another answer to 1 except tweaking virtualenv’s sources (with both ubuntu and virtualenv being so popular I wouldn’t be surprised to find tweaked versions already exist).

    Re 2, if you’re using /usr/local/bin/python you should use the /usr/local version of the lib (including site-packages) and conversely if you’re using /usr/bin/python.

    Re 3, there will be something there if you ever install an extension for /usr/bin/python from sources (not via easy_install or from ubuntu’s distro).

    Re 4, yes, earlier entries on the path take precedence.

    Re 5, easy_install is easy only in its name — it does so much dark magic that it’s been carefully kept out of the standard python library despite its convenience because the consensus among us python committers is that deep dark magic for convenience is “easy” only on the surface.

    Re 6, I think that’s an ubuntu modification to easy_install — if that’s right then it’s defined wherever Canonical or other ubuntu maintainers make their collective decisions.

    Re 7, sorry, no idea — I have no reasonably recent ubuntu at hand to check.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 317k
  • Answers 317k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer The problem is rather straightforward to me. The webpage: http://localhost:49464/Seth-Duncan.com/Main.aspx… May 13, 2026 at 11:48 pm
  • Editorial Team
    Editorial Team added an answer the answer is ok, the solution is: PHP function retornamenu($tableInBd)… May 13, 2026 at 11:48 pm
  • Editorial Team
    Editorial Team added an answer Move the following code: btn_test.Attributes.Add("onclick", "window.open('New.aspx?ddlValue=" + val + "',… May 13, 2026 at 11:48 pm

Related Questions

I saw a java function that looked something like this- public static<T> foo() {...}
Ok, so I'm a little confused as to why I can't find this anywhere,
I'm developing a Flex 2 application, and I noticed that part of the library
I have an Intel Core 2 Duo CPU and i was reading 3 files

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.