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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T05:13:34+00:00 2026-06-05T05:13:34+00:00

My Python couldn’t figure out the submodules when I was trying to import reportlab.graphics.shapes

  • 0

My Python couldn’t figure out the submodules when I was trying to import reportlab.graphics.shapes like this:

>>> from reportlab.graphics.shapes import Drawing

Traceback (most recent call last):
  File "<pyshell#14>", line 1, in <module>
    from reportlab.graphics.shapes import Drawing
ImportError: No module named shapes

I have copied the reportlab package to /site-packages and I can import module reportlab.graphics successfully.

My Python version is 2.7.3.

Could anyone help me to fix this problem?

  • 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-05T05:13:35+00:00Added an answer on June 5, 2026 at 5:13 am

    As @dan-boa pointed out, you can add paths to the module search path, but since you can find the parent module, I doubt that this is your root problem.

    Do you have some left-over installation of the module at another path? You can check the path where it is finding the parent package (reportlab) by executing:

    import reportlab
    print reportlab.__file__
    

    If this is indeed the path you were expecting, then try this recursively with the the sub-modules, until you can see where the problem is. Perhaps, your package is corrupted? Try manually checking in the path returned if you can find the files/modules in question.

    If this is not the path you were expecting, clean-up the installation from this 2nd path and try again.

    Finally, in case you do find that it is a path problem, instead of adding the path each time using sys.path.append, you can add it to PYTHONPATH

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

Sidebar

Related Questions

I am trying to learn python and couldn't figure out how to translate the
I came across an exercise in "Think Python", and I couldn't figure out how
Some questions that I couldn't figure out from reading the docs and some other
In python 2.x I could do this: import sys, array a = array.array('B', range(100))
I couldn't understand why this is happening actually.. Take a look at this python
I am trying to get filtered list of all Text and Python file, like
I couldn't find out python equivalent to PHP $_SERVER. Is there any? Or, what
I am learning python atm, and was doing an exercise from this site --
I have an issue in Python I couldn't believe to find out. See the
I couldn't find a guide that would help me out in this area. So

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.