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

  • SEARCH
  • Home
  • 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 7061675
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T04:30:10+00:00 2026-05-28T04:30:10+00:00

Sometimes I get errors that I suspect are the result of my Django app

  • 0

Sometimes I get errors that I suspect are the result of my Django app using globally installed Python modules/Django apps instead of those within its virtualenv.

Is there a way to check whether my app’s virtualenv was created with ‘–no-site-packages’ without having to delete it, then re-create it as follows?

deactivate
rmvirtualenv my_env
mkvirtualenv my_env --no-site-packages
workon my_env
pip install -r requirements.txt

Surely there must be a better way! Thanks.

  • 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-28T04:30:11+00:00Added an answer on May 28, 2026 at 4:30 am

    There’s a file in <env>/lib/pythonX.X/ called no-global-site-packages.txt when you create a virtual environment with --no-site-packages.

    Just tried this with virtualenv 1.7:

    % virtualenv --no-site-packages env.without
    % virtualenv --system-site-packages env.with
    
    % find env.without | sed 's/env.without//' > files.without
    % find env.with | sed 's/env.with//' > files.with
    
    % diff files.with*
    230a231
    > /lib/python3.2/no-global-site-packages.txt
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Sometimes when copying stuff into PostgreSQL I get errors that there's invalid byte sequences.
I noticed that sometimes I get errors in my R scripts when I forget
We have some applications that sometimes get into a bad state, but only in
After a server restart I sometimes get random CompilationException errors like this: CompilationException: CS0006:
I have noticed that with Delphi 2009, I often get strange errors when compiling,
I'm doing some imports with python and sometimes I do not have that package
Over the course of programming I get errors that give a resource number like
im using xcode4 and box2d/cocos2d. Im having some strange difficulties with runtime errors that
Sometimes, while coding in PHP we get parse or syntax errors like those: Parse
When running my application I sometimes get an error about too many files open

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.