Posts

Showing posts from 2017

React native Undefined is not an object issues

Image
In react native recently many people facing the undefined object issue related to " PropTypes.bool " and " createClass " . This kind of issue ruining the more development time now a days.  Today we are going to look at the exact problem and the solution for this kind of errors Problem Description: As of now we are going to see the  React native Undefined is not an object (evaluating'_react2.default.PropTypes.bool')  . In this issue we cant do the property check for the element using the react native. Screen shot : Root Cause:  The problem arise because of outdated package using in the application. Which  means the react version being in higher/upgraded and the other packages not updated and used old only.  May be the react and react native latest version they deprecated the functionalities which you using in application Solution: The above problem is arrived because of second root cause point. So we have to make sure the up ...

Connect VPN via Python

Here we are going to connect the VPN services through the python. After connect the VPN we can crawl the blocked website and so on. The script going to use the free VPN services provided by VPNGate . The VPN based on the user input countries. Prerequired Open vpn must be available in your system. Use the below command to install open vpn in your linux machine, 1 apt-get install openvpn easy-rsa further more details for the installation , Please follow the link install openvpn Usage Run the script by providing the desired output country like given below, 1 python script.py IN Instead of giving country short name we can use the full name like given below, 1 python script.py India further supported country information list available in that link. Please click me to see the details The connection script is given below, Here we are checked the ip address instance after connected through the vpn. 1 2 3 4 5 6 7 8 9 10 11 12 13 ...

Send Push Notification to iPhone via Python

Image
Notification is the big picture of current day to day applications. So today we are going to look into iPhone push notification. We already seen how to send email notification using python. The to hot topic we are going to deep is How to send push notification to iPhone's . Description     Here we are going to use the Apple push notification service. Through python code we have to send the notification to Apple service with device id . Once we send the notification to apple service, they will take care to deliver this notification to appropriate device. Pre-Requesting  We must enable APNS service. To follow this link to enable the APNS service. APNS will generate the certificate after enable the service. Sample code The below code snapshot will have the sample code for to send push notification to IOS device through the apple sandbox mode in testing purpose, 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 ...

Website crawl or scraping with selenium and python

Image
The amount of information on the Web grows exponentially, a flurry of applications (mobile, web, or otherwise) have come about that wish to harness it all. The methods for harnessing information on the web may be many, but one that’s seemingly the most ubiquitous is ‘scraping’. Scraping is what most search engines employ in some form or the other: the ‘spiders’ that crawl the web looking for metadata information embedded in websites, or price-comparison sites that allow users to make purchase decisions, and probably a gazillion other things that I cannot even imagine. How Scraping differs ? In this article we are going to look at the website crawling with python. The crawling work can be classified based on the HTML DOM modification and rendering.  Scraping Type 1: The DOM modification is done in server side and the html string append in frond end means we dont go with selenium. We can achieve through python and tool for parsing html code.  Scrapi...

Twitter Sentiment Analyser with Stanford NLP

Image
This topic covers the sentiment analysis of any tweets collected from twitter and store the result in database What is sentiment analysis ?   Which means the analysis done through computational to determine the given statement is positive or negative . Where it will useful  ?  Marketing  - which find out the people feed back based product success of failure prediction Politics  People actions  Here we are going to do the sentiment analysis with twitter Pre required : 1. Java 1.8 - required for stanford nlp server to run 2. Tweepy - required to pull / crawl  data from the twitter  3. Pycorennlp - required to call stanford nlp server via python Please follow this url  https://stanfordnlp.github.io/CoreNLP/corenlp-server.html to install nlp server in your local system. We can also use third party library to find the sentiment analysis. The textblob is one of the library in python. Authentication : In o...