ec2instancespricing icon indicating copy to clipboard operation
ec2instancespricing copied to clipboard

ImportError: No module named 'prettytable'

Open apoorvup07 opened this issue 7 years ago • 14 comments

I have installed pretty table but it is showing this error.

ImportError: No module named 'prettytable'

apoorvup07 avatar Dec 01 '16 13:12 apoorvup07

prettytable might not be in your path. How did you install it?

Try running python without anything from the same path as ec2instancespricing.py and write import prettytable. If it fails, the Python interpreter can't find it.

erans avatar Dec 01 '16 13:12 erans

@erans Possible to replace PrettyTable with some other lib/package? I can confirm that there is some issue with prettytable. Attached the screenshot for your ref.

image

Dawny33 avatar Apr 17 '17 06:04 Dawny33

you should upgrade your pip.

$pip install PrettyTable
$python -m pip install --upgrade pip

and in your code just add : from prettytable import PrettyTable

L-KH avatar Sep 12 '19 13:09 L-KH

Thats not work for me

okanyesil avatar Dec 08 '20 12:12 okanyesil

With the following command the problem is solved (at least for me):

pip install prettytable

I launched the command inside a virtual environment with Python 3.8.

igarag avatar Feb 02 '21 14:02 igarag

I have installed pretty table but it is showing this error.

ImportError: No module named 'prettytable'

try to install using anaconda prompt it worked for me -- pip install prettytable

s1997himanshu avatar Feb 22 '21 07:02 s1997himanshu

pip3 install https://pypi.python.org/packages/source/P/PrettyTable/prettytable-0.7.2.tar.bz2

sujitrp avatar May 01 '21 19:05 sujitrp

try using Base Python env. I was trying inside an env even if it is installed sometimes does not work inside your own envs. just use Python3 in your kernel, do pip install prettytable then import it.

momado350 avatar Nov 25 '21 02:11 momado350

if you are using ubuntu

sudo apt update sudo apt install python3-prettytable

ahmedabdulwhhab avatar Jun 06 '22 22:06 ahmedabdulwhhab

iam already install pretty table but my terminal show this error:cannot import name 'PrettyTable' from partially initialized module 'prettytable' (most likely due to a circular import)

2masa avatar Jul 29 '22 05:07 2masa

Do you have prettytable installed anywhere else?

On Thu, Jul 28, 2022 at 10:51 PM 2masa @.***> wrote:

iam already install pretty table but my terminal show this error:cannot import name 'PrettyTable' from partially initialized module 'prettytable' (most likely due to a circular import)

— Reply to this email directly, view it on GitHub https://github.com/erans/ec2instancespricing/issues/49#issuecomment-1198905391, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAACUE6WOODZKFCH2PAXQ4TVWNWM7ANCNFSM4CYFTOIA . You are receiving this because you were mentioned.Message ID: @.***>

erans avatar Jul 29 '22 15:07 erans

Thanks for the. Solution

On Fri, 29 Jul, 2022, 9:27 PM Eran Sandler, @.***> wrote:

Do you have prettytable installed anywhere else?

On Thu, Jul 28, 2022 at 10:51 PM 2masa @.***> wrote:

iam already install pretty table but my terminal show this error:cannot import name 'PrettyTable' from partially initialized module 'prettytable' (most likely due to a circular import)

— Reply to this email directly, view it on GitHub < https://github.com/erans/ec2instancespricing/issues/49#issuecomment-1198905391 , or unsubscribe < https://github.com/notifications/unsubscribe-auth/AAACUE6WOODZKFCH2PAXQ4TVWNWM7ANCNFSM4CYFTOIA

. You are receiving this because you were mentioned.Message ID: @.***>

— Reply to this email directly, view it on GitHub https://github.com/erans/ec2instancespricing/issues/49#issuecomment-1199607968, or unsubscribe https://github.com/notifications/unsubscribe-auth/A2DD4FTNBH2FEKH5JUNDRJDVWP5PLANCNFSM4CYFTOIA . You are receiving this because you commented.Message ID: @.***>

2masa avatar Jul 30 '22 14:07 2masa

https://github.com/ahmedabdulwhhab/SDN-RYU-Mininet-Path/tree/main/A9khan_A_Whhab_Traffic_Classifier MAIN PACKAGES ARE sudo apt update sudo apt install python3-prettytable.

more data can be viewed under https://github.com/ahmedabdulwhhab/SDN-RYU-Mininet-Path/blob/main/A9khan_A_Whhab_Traffic_Classifier/README.md

ahmedabdulwhhab avatar Aug 09 '22 15:08 ahmedabdulwhhab

Thanks for the. Solution On Fri, 29 Jul, 2022, 9:27 PM Eran Sandler, @.> wrote: Do you have prettytable installed anywhere else? On Thu, Jul 28, 2022 at 10:51 PM 2masa @.> wrote: > iam already install pretty table but my terminal show this error:cannot > import name 'PrettyTable' from partially initialized module 'prettytable' > (most likely due to a circular import) > > — > Reply to this email directly, view it on GitHub > < #49 (comment) >, > or unsubscribe > < https://github.com/notifications/unsubscribe-auth/AAACUE6WOODZKFCH2PAXQ4TVWNWM7ANCNFSM4CYFTOIA > > . > You are receiving this because you were mentioned.Message ID: > @.> > — Reply to this email directly, view it on GitHub <#49 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/A2DD4FTNBH2FEKH5JUNDRJDVWP5PLANCNFSM4CYFTOIA . You are receiving this because you commented.Message ID: @.>

first of all , you should know where you are using prettytable if you are under ubuntu as my case , use sudo apt install prettytable

if you are under conda, use conda install prettytable

under python/pycharm pip install prettytable

ahmedabdulwhhab avatar Aug 09 '22 15:08 ahmedabdulwhhab