6

Im using Pycharm and installed boto3 package and tried to import boto3 and got attribute error. Python.exe file path is given in project interpreter

import boto3

s3 = boto3.resource('s3')

AttributeError: partially initialized module 'boto3' has no attribute 'resource' (most likely due to a circular import)

But the same code working in Python shell

Marcin
  • 215,873
  • 14
  • 235
  • 294
harsha kazama
  • 159
  • 2
  • 4
  • 18

1 Answers1

19

I guess its because of your file name when i tried, i got the same error when renamed the file name. I was able to run the file successfully

Abhinaya
  • 949
  • 1
  • 5
  • 12