analitics

Pages

Showing posts with label 2016 news. Show all posts
Showing posts with label 2016 news. Show all posts

Saturday, August 27, 2016

The python dizzy with clean instalation, is true !?

This will refer the python 2.7 working - but it can be extrapolated to other versions.
Many users have trouble installing python modules. The problem comes from old modules outdated or those who did not support.
I will present a few examples. I hope to come and support as necessary to remedy in time or exclusion through better solutions.
This is the main question for today: The python dizzy with clean instalation, is true !?
I don't think is a unwanted hacking of my python instalation using internet.
But I search and I saw many questions and erros over pip and Scripts folders.
I will deal just for this issue:
After I make one clean python 2.7 and all my python modules works well I used my windows to deal with some ssh software.
The next step I make it with python was to try to update with pip.
The strange think is with this files from Scripts folders:
12-Aug-16 06:41 PM 98,150 pyrsa-decrypt-bigfile.exe
12-Aug-16 06:41 PM 98,134 pyrsa-decrypt.exe
12-Aug-16 06:41 PM 98,150 pyrsa-encrypt-bigfile.exe
12-Aug-16 06:41 PM 98,134 pyrsa-encrypt.exe
12-Aug-16 06:41 PM 98,132 pyrsa-keygen.exe
12-Aug-16 06:41 PM 98,155 pyrsa-priv2pub.exe
12-Aug-16 06:41 PM 98,128 pyrsa-sign.exe
12-Aug-16 06:41 PM 98,132 pyrsa-verify.exe
and this file from same Script folder:
21-Jun-16 09:09 PM 0 python.exe
When I need to use pip I got errors.Then I try to fix with this:
pip install --upgrade ndg-httpsclient
and seem to be working now.
But I need to find from where come this file and why is this python file with:
C:\Python27\Scripts>python
Access is denied.
Maybe will be fix with a clean python instalation.
But the next step is and one of my concern is how to preserve this python instalation.
For example today the
pip update issue
come with many errors and this will be fixed.
Let's see how I fixed some of this.

First download Microsoft Visual C++ Compiler for Python 2.7.
This will fix this error:
error: Microsoft Visual C++ 9.0 is required. Get it from http://aka.ms/vcpython27
.

If you got this error: RuntimeError: Freetype library not found
C:\Python27>Scripts\pip install freetype-py
Collecting freetype-py
Downloading freetype-py-1.0.2.tar.gz (394kB)
100% |################################| 399kB 758kB/s
Building wheels for collected packages: freetype-py
Running setup.py bdist_wheel for freetype-py ... done
You can see also this freetype-py will not working:
C:\Python27>python.exe
Python 2.7.8 (default, Jun 30 2014, 16:08:48) [MSC v.1500 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import freetype
Traceback (most recent call last):
File "", line 1, in
File "C:\Python27\lib\site-packages\freetype\__init__.py", line 21, in
from freetype.raw import *
File "C:\Python27\lib\site-packages\freetype\raw.py", line 37, in
raise RuntimeError('Freetype library not found')
RuntimeError: Freetype library not found
Also some python module has into cloud dizzy stuff.
For example the pycryptodome come with many features and working great.
Also some alternative is a bad solution.
It is hard to find a solution to the problem of leaving all these modules.
Any solutions?

Thursday, August 11, 2016

The Python and antivirus Kaspersky antivirus.

The Kaspersky antivirus is very reserved versus python.
Even if the pip will try to install one module also any instance of numpy module has one replay over Kaspersky antivirus.
I try to start python shell and then import numpy after that I close the shell and I run it again. 
Update I try also help() / modules command under shell and more and randmon pyd file are blocked. This is strange because the pyd files are random.
See the result is how Kaspersky and python shell works together:
What do you think about that?


Thursday, May 19, 2016

News: The new python version 3.6.0.a1

I used the Windows x86-64 executable installer to install this version of python.
I set some settings and I start the install aplication.

I read all new changes and PEP 0498.
I take a look to see all python modules:
Please wait a moment while I gather a list of all available modules...

__future__          aifc                http                setuptools
_ast                antigravity         idlelib             shelve
_bisect             argparse            imaplib             shlex
_bootlocale         array               imghdr              shutil
_bz2                ast                 imp                 signal
_codecs             asynchat            importlib           site
_codecs_cn          asyncio             inspect             smtpd
_codecs_hk          asyncore            io                  smtplib
_codecs_iso2022     atexit              ipaddress           sndhdr
_codecs_jp          audioop             itertools           socket
_codecs_kr          base64              json                socketserver
_codecs_tw          bdb                 keyword             sqlite3
_collections        binascii            lib2to3             sre_compile
_collections_abc    binhex              linecache           sre_constants
_compat_pickle      bisect              locale              sre_parse
_compression        builtins            logging             ssl
_csv                bz2                 lzma                stat
_ctypes             cProfile            macpath             statistics
_ctypes_test        calendar            macurl2path         string
_datetime           cgi                 mailbox             stringprep
_decimal            cgitb               mailcap             struct
_dummy_thread       chunk               marshal             subprocess
_elementtree        cmath               math                sunau
_functools          cmd                 mimetypes           symbol
_hashlib            code                mmap                symtable
_heapq              codecs              modulefinder        sys
_imp                codeop              msilib              sysconfig
_io                 collections         msvcrt              tabnanny
_json               colorsys            multiprocessing     tarfile
_locale             compileall          netrc               telnetlib
_lsprof             concurrent          nntplib             tempfile
_lzma               configparser        nt                  test
_markupbase         contextlib          ntpath              textwrap
_md5                copy                nturl2path          this
_msi                copyreg             numbers             threading
_multibytecodec     crypt               opcode              time
_multiprocessing    csv                 operator            timeit
_opcode             ctypes              optparse            tkinter
_operator           curses              os                  token
_osx_support        datetime            parser              tokenize
_overlapped         dbm                 pathlib             trace
_pickle             decimal             pdb                 traceback
_pydecimal          difflib             pickle              tracemalloc
_pyio               dis                 pickletools         tty
_random             distutils           pip                 turtle
_sha1               doctest             pipes               turtledemo
_sha256             dummy_threading     pkg_resources       types
_sha512             easy_install        pkgutil             typing
_signal             email               platform            unicodedata
_sitebuiltins       encodings           plistlib            unittest
_socket             ensurepip           poplib              urllib
_sqlite3            enum                posixpath           uu
_sre                errno               pprint              uuid
_ssl                faulthandler        profile             venv
_stat               filecmp             pstats              warnings
_string             fileinput           pty                 wave
_strptime           fnmatch             py_compile          weakref
_struct             formatter           pyclbr              webbrowser
_symtable           fractions           pydoc               winreg
_testbuffer         ftplib              pydoc_data          winsound
_testcapi           functools           pyexpat             wsgiref
_testimportmultiple gc                  queue               xdrlib
_testmultiphase     genericpath         quopri              xml
_thread             getopt              random              xmlrpc
_threading_local    getpass             re                  xxsubtype
_tkinter            gettext             reprlib             zipapp
_tracemalloc        glob                rlcompleter         zipfile
_warnings           gzip                runpy               zipimport
_weakref            hashlib             sched               zlib
_weakrefset         heapq               secrets
_winapi             hmac                select
abc                 html                selectors
The new formatted string literals are a new kind of string literal, prefixed with 'f' this allow you to add contain replacement fields surrounded by curly braces.
I don't think the add Python start well, maybe need restart:
 >>> import crypt
Traceback (most recent call last):
  File "", line 1, in 
  File "C:\Python36\lib\crypt.py", line 3, in 
    import _crypt
ImportError: No module named '_crypt' 
Some of changes can be see at whatsnew.
You can read more and also download the new python released version 360a1 from here.
Very good work from development team, they make a great job.

Wednesday, April 20, 2016

News: New PyPy 5.1 released.

New features and bug fixes come with new PyPy 5.1 version.
The PyPy is a very compliant Python interpreter and supports x86 machines on most common operating systems.
Now we have full support for the IBM s390x and good optimizations.
Take a look here.

Saturday, March 19, 2016

Free ebook from O'Reilly - Functional Programming in Python.

You can download your free ebook from O'Reilly.
The Functional Programming in Python by David Mertz - publisher: O'Reilly - released: June 2015.
David Mertz is a director of the Python Software Foundation, and chair of its Trademarks and Outreach & Education Committees. He wrote the columns Charming Python and XML Matters for IBM developerWorks and the Addison-Wesley book Text Processing in Python. David has spoken at multiple OSCON and PyCon events.
This is the download link.

 

Thursday, February 4, 2016

The most short source code into Python 3.5.1 .

Just type this :

import antigravity

That will open your browser with one comics from xkcd website.
The antigravity module was added to Python 3.5.1. I'm not sure but seam working also with python 2.7 version.