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 9062869
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T15:50:43+00:00 2026-06-16T15:50:43+00:00

I recently ran into an issue on my development box. I can run my

  • 0

I recently ran into an issue on my development box. I can run my script line by line fine within the interactive shell, but it fails as soon as it tries to import a module when running the script from the command line.

Specifically, I’m trying to use: from flask import Flask

and the error I get is:

from flask import Flask
ImportError: cannot import name Flask

It was working perfectly fine a couple days ago and I didn’t make any changes to the system (that I can recall) so I can’t figure out if this is an issue with my python shell or flask.

Things I’ve checked/tried:

  • deleting/reinstalling flask via pip
  • confirming C:\Python27\lib\site-packages is in my system path
  • clearing and re-adding the directories in my PATH environment variable
  • uninstalling/reinstalling Python 2.7.3
  • successfully running the following script to test my python shell:

    from time import gmtime, strftime
    print strftime("%a, %d %b %Y %H:%M:%S +0000", gmtime())
    

I’m open to any new troubleshooting suggestions.

  • 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-06-16T15:50:44+00:00Added an answer on June 16, 2026 at 3:50 pm

    I had originally called the file flask.py and there was an old compiled flask.pyc in the same directory. It worked fine as soon as I moved it to another directory and also when removing the old flask.pyc.

    Thanks for the quick comments timc and BrenBarn!

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

Sidebar

Related Questions

I recently ran into an issue where a query was causing a full table
I recently ran into an issue that could easily be solved using modulus division,
I recently ran into an issue at work in which, at least according to
Recently I ran into a very strange issue: touching the screen of the iPhone
I recently ran into an odd issue where I'd get a const_iterator instead of
I recently wanted to update my gem bundle but ran into installation problems with
I ran into an issue recently where the following toy example compiles cleanly using
Hey guys i've just recently been getting a hang of sockets but ran into
I recently ran into an issue where I used a property that was introduced
I have recently ran into this strange issue, I was trying to reference parent

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.