Skip to content

Miniconda3. ImportError: Unable to import required dependencies... #6843

@PavelD0770

Description

@PavelD0770
When running the script in VS Code, an error is issued:

C:\Users\user>C:/Python/Miniconda3/envs/myenv/python.exe d:/Test/Test.py
Traceback (most recent call last):
File "d:/Test/Test.py", line 1, in import pandas
File "C:\Python\Miniconda3\envs\myenv\lib\site-ackages\pandas_init_.py", line 17, in "Unable to import required dependencies:\n" + "\n".join(missing_dependencies)
ImportError: Unable to import required dependencies:
numpy: DLL load failed: The specified module was not found.

What am I doing.
  1. Install Miniconda3

  2. I create myenv virtual environment in Miniconda3

  3. Download packages there: pandas, numpy, etc.

  4. Launch VS Code (Microsoft's Python extension installed)

  5. I create a Python script file with text (for example):
    import pandas
    print ('pass ..')

  6. I select the virtual environment myenv and run the script on
    performance.

  7. I observe the above error :(

    Works from the console (miniconda), works from Visual Studio 2019, works from Pycharm too. From VS Code, it only works when changing to the virtual environment (venv) of Python 3.7, in which the packages from p. 3 are also installed. Those. the only problem is a bunch of VS Code and Miniconda3.

    A similar problem with numpy, matplotlib, scipy. C, for example, sqlalchemy, requests and some other third-party packages are all OK.

    Previously, VS code worked with the Miniconda3 virtual environment without any problems. Perhaps the problem appeared after installing and then uninstalling Anaconda Extension Pack.

Python 3.7.4
Miniconda3 4.7.10 (Python 3.7.3)
Virtual env.: virtualenv (Python 3.7.4), conda envs. (Python 3.7.3)
VS Code version: Code 1.36.1 (2213894, 2019-07-08T22:59:35.033Z)
MS Python extension for Visual Studio Code 2019.6.24221
OS version: Windows_NT x64 10.0.17134

System Info
CPUs Intel(R) Core(TM) i3-7100U CPU @ 2.40GHz (4 x 2400)
GPU Status 2d_canvas: enabled
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: disabled_software
oop_rasterization: disabled_off
protected_video_decode: enabled
rasterization: enabled
skia_deferred_display_list: disabled_off
skia_renderer: disabled_off
surface_synchronization: enabled_on
video_decode: enabled
viz_display_compositor: disabled_off
webgl: enabled
webgl2: enabled
Load (avg) undefined
Memory (System) 5.89GB (0.37GB free)
Process Argv
Screen Reader no
VM 0%

Extensions (3):
vscode-language-pack-ru MS- 1.37.3
python ms- 2019.6.24221
material-icon-theme PKi 3.8.1

Metadata

Metadata

Labels

area-environmentsFeatures relating to handling interpreter environmentsbugIssue identified by VS Code Team member as probable buginfo-neededIssue requires more information from poster

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions