Error while Installing Django on Visual Studio - django

I install Django on Visual studio but I have these errors enter image description here
enter image description here
Downloading virtualenv-20.17.1-py3-none-any.whl (8.8 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 8.8/8.8 MB 4.5 MB/s eta 0:00:00Collecting platformdirs<3,>=2.4
Downloading platformdirs-2.6.2-py3-none-any.whl (14 kB)
Collecting filelock<4,>=3.4.1
Downloading filelock-3.9.0-py3-none-any.whl (9.7 kB)
Collecting distlib<1,>=0.3.6
Downloading distlib-0.3.6-py2.py3-none-any.whl (468 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 468.5/468.5 KB 9.8 MB/s eta 0:00:00Installing collected packages: distlib, platformdirs, filelock, virtualenv
WARNING: The script virtualenv.exe is installed in 'C:\Users\bienh\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\Scripts' which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
Successfully installed distlib-0.3.6 filelock-3.9.0 platformdirs-2.6.2 virtualenv-20.17.1WARNING: You are using pip version 22.0.4; however, version 22.3.1 is available.
You should consider upgrading via the 'C:\Users\bienh\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\python.exe -m pip install --upgrade pip' command.
PS C:\Users\bienh\OneDrive\Documents\Django>
virtualenv env
virtualenv : The term 'virtualenv' is not recognized as the name of a cmdlet, function, script file, or
operable program. Check the spelling of the name, or if a path was included, verify that the path is correct
and try again.
At line:1 char:1
+ virtualenv env
+ ~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (virtualenv:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundExceptiontype here
How to do this: "Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location." Could you please help me to fix them? Thank you very much

Related

Pip2 error: Could not find a version that satisfies the requirement tensorboard<1.15.0,>=1.14.0

I am having .whl file for tensorflow 1.14.0 to be installed on Raspberry Pi 3B board. When I run the following command,
sudo pip2 install tensorflow-1.14.0-cp27-none-linux_armv7l.whl
I get the following error:
Could not find a version that satisfies the requirement tensorboard<1.15.0,>=1.14.0 (from tensorflow==1.14.0) (from versions: )
No matching distribution found for tensorboard<1.15.0,>=1.14.0 (from tensorflow==1.14.0)
I tried to do some other hacks like:
sudo pip2 install --ignore-installed --upgrade Downloads/tensorflow-1.14.0-cp27-none-linux_armv7l.whl
and even this:
curl http://bootstrap.pypa.io/get-pip.py | python
but the error remains the same.
Does anyone have any idea about this because I ran the same command on another RPI of same model and the command worked.

Can't install php imap extension on centos 7

Running command
sudo yum install php56w-imap
gives me the output:
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirrors.163.com
* extras: mirrors.163.com
* updates: mirrors.163.com
* webtatic: uk.repo.webtatic.com
Resolving Dependencies
--> Running transaction check
---> Package php56w-imap.x86_64 0:5.6.22-1.w7 will be installed
--> Processing Dependency: libc-client.so.2007()(64bit) for package: php56w-imap-5.6.22-1.w7.x86_64
--> Finished Dependency Resolution
Error: Package: php56w-imap-5.6.22-1.w7.x86_64 (webtatic)
**Requires: libc-client.so.2007()(64bit)**
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
I'm avoiding any compilation, so the --libdir=/usr/lib64 option for compiling php is not what I'm looking for.
Also, I couldn't find any valid download link for this library.
Please help!
I found it:
https://www.rpmfind.net/linux/rpm2html/search.php?query=libc-client.so.2007()(64bit)
What I tried to install is libc-client-devel but it failed for dependency. with this libc-client, everything works well
just install first with command:
yum install php-imap*
I was getting an SE_UID not found error.
I just stumbled on https://centos.pkgs.org/7/ius-x86_64/php72u-imap-7.2.17-1.ius.centos7.x86_64.rpm.html
and then I ran:
yum install php72u-imap
I also created a php file with echo phpinfo() and saw that IMAP now shows up as a separate section in the display.

nltk module installation in pip through cmd

When I tried to run this command:
c:\python27\scripts\pip install nltk-3.2.1-py2.py3-none-any
I am getting the error:
no matching distribution found
Although i have installed nltk from
http://www.lfd.uci.edu/~gohlke/pythonlibs/#nltk
Kindly help.
I am working on Windows 8 64-bit Version
Installing new modules can be a nightmare if you are new to Python.First delete any old versions of NLTK if already installed. Open cmd navigate to C:\Users\user\AppData\Local\Programs\Python\Python35-32\Scripts, the default directory, using the command cd path_name_comes_here. Otherwise goto the path where you have installed python and goto the Scripts subfolder and use this path here onwards. Now the most preferred way is to use pip install module_you_want_to_install for anything in python. Pip automatically fetches everything it needs to install said module.
Simply use pip install nltk.
Another method is to use easy_install requirement_or_URL.
Some rare occasions its best to download the wheel from http://www.lfd.uci.edu/~gohlke/pythonlibs and from there you can simply use pip install downloaded_wheel_name again. But make sure to copy the name of the wheel EXACTLY.
Post installation make sure that your package is accessible from C:\Users\user\AppData\Local\Programs\Python\Python35-32\Lib\site-packages or a similar path depending on where you installed python.
Try Anaconda - Instead . Always works
C:\Users\sanan>conda install -c anaconda nltk
Fetching package metadata .............
Solving package specifications: .
Package plan for installation in environment C:\Users\sanan\Miniconda3:
The following NEW packages will be INSTALLED:
nltk: 3.2.4-py36_0 anaconda
The following packages will be UPDATED:
conda: 4.3.23-py36_0 --> 4.3.25-py36_0 anaconda
The following packages will be SUPERSEDED by a higher-priority channel:
conda-env: 2.6.0-0 --> 2.6.0-0 anaconda
Proceed ([y]/n)? y
conda-env-2.6. 100% |###############################| Time: 0:00:00 22.84 kB/s
nltk-3.2.4-py3 100% |###############################| Time: 0:00:02 774.24 kB/s
conda-4.3.25-p 100% |###############################| Time: 0:00:00 578.90 kB/s
After installation is complete .
import nltk
print(nltk.__version__)
C:\Public\Code\textnorm>python attempt1.py
3.2.4

No matching distribution found for 'package' in python wheel

I have written a python package called lyrico and uploaded the source dist and wheel to testpypi site.
lyrico
But when I try to install it from there using following command it gives errors:
pip install -i https://testpypi.python.org/pypi lyrico
Error logged in cmd-prompt:
Collecting lyrico
Using cached https://testpypi.python.org/packages/py2/l/lyrico/lyrico-0.2.5-py2-none-any.whl
Collecting mutagen (from lyrico)
Could not find a version that satisfies the requirement mutagen (from lyrico) (from versions: )
No matching distribution found for mutagen (from lyrico)
It is unable to find the dependency mutagen in wheel I uploaded. I have included dependencies in my setup.py:
install_requires = [
'mutagen',
'glob2',
'beautifulsoup4',
'win-unicode-console >= 0.4'
],
Weird thing is that if go to testPyPi page and manually download and install the wheel using (after cd to the containing dir):
pip install lyrico-0.2.5-py2-none-any.whl
it works and installs all the dependencies as well.
I am using Python 2.7.11 on a Windows7 system. Can someone please tell what is wrong or if the error is reproduce-able?

Installing Camomile via opam fails due to missing patch file. How can I fix this?

While installing utop via opam on my ArchLinux laptop, I got the following message:
$ opam install utop
The following actions will be performed:
- install camomile.0.8.5 [required by utop]
- install zed.1.3 [required by utop]
- install lambda-term.1.6 [required by utop]
- install utop.1.14
4 to install | 0 to reinstall | 0 to upgrade | 0 to downgrade | 0 to remove
Do you want to continue ? [Y/n]
=-=-= Installing camomile.0.8.5 =-=-=
Applying cmxs.patch.
[ERROR] Due to some errors while processing camomile.0.8.5, the following actions will NOT proceed:
- install utop.1.14
- install lambda-term.1.6
- install zed.1.3
===== ERROR while installing camomile.0.8.5 =====
Could not get the source for camomile.0.8.5:
# opam-version 1.1.1
# os linux
Patch file "/home/sinan/.opam/system/build/camomile.0.8.5/cmxs.patch" not found.
'opam install utop' failed.
Trying to install camomile by itself also gives the same error. This seems to be related to commit 672e44e which carried over to the opam repository as cmxs.patch. I am not sure where things break so that opam tries to build without the patch file.
I tried downloading, and putting cmxs.patch in the reported location, but, of course, that directory gets clobbered the next time I try to install via opam.
How should I proceed?
I would have preferred to have been able to fix the underlying problem, but, in the end, downloading the contents of the cmxs.patch file, adding it to the already downloaded ~/.opam/archives/camomile.0.8.5+opam.tar.gz archive, and then issuing
$ opam install camomile
worked.
After that, opam install utop went without a hitch as well.
For your reference, I have:
$ opam --version
1.1.1
$ cat .opam/repo/default/repo
upstream: "https://github.com/ocaml/opam-repository/tree/master/"
browse: "https://opam.ocaml.org/pkg/"