Error in visual studio python project RRS feed

  • Question

  • Hi, I have 2 questions. 

    1. I have created a new virtual env. How to get that activate?

    2. When I did this, i get below error - I right click on Project "SMS" -> selected "Python" -> selected "Migrate" 

    Executing manage.py migrate

    Traceback (most recent call last):

      File "D:\SMS\SMS\manage.py", line 24, in <module>


      File "D:\SMS\SMS\SMSenv\lib\site-packages\django\core\management\__init__.py", line 381, in execute_from_command_line


      File "D:\SMS\SMS\SMSenv\lib\site-packages\django\core\management\__init__.py", line 357, in execute


      File "D:\SMS\SMS\SMSenv\lib\site-packages\django\__init__.py", line 24, in setup


      File "D:\SMS\SMS\SMSenv\lib\site-packages\django\apps\registry.py", line 91, in populate

        app_config = AppConfig.create(entry)

      File "D:\SMS\SMS\SMSenv\lib\site-packages\django\apps\config.py", line 90, in create

        module = import_module(entry)

      File "C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python37_64\lib\importlib\__init__.py", line 127, in import_module

        return _bootstrap._gcd_import(name[level:], package, level)

      File "<frozen importlib._bootstrap>", line 1006, in _gcd_import

      File "<frozen importlib._bootstrap>", line 983, in _find_and_load

      File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked

      File "<frozen importlib._bootstrap>", line 677, in _load_unlocked

      File "<frozen importlib._bootstrap_external>", line 724, in exec_module

      File "<frozen importlib._bootstrap_external>", line 860, in get_code

      File "<frozen importlib._bootstrap_external>", line 791, in source_to_code

      File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed

      File ".\SMSApp\__init__.py", line 5

        class Admin(models.models1)


    SyntaxError: invalid syntax

    The interactive Python process has exited.

    The interactive Python process has exited.

    • Edited by kdinuk Saturday, June 20, 2020 4:47 PM
    Saturday, June 20, 2020 4:46 PM