Skip to content

Forum in maintenance, we will back soon 🙂

Getting False In Pl...
 
Notifications
Clear all

Getting False In Plagrisim Checker

7 Posts
3 Users
5 Reactions
67 Views
(@thoufeeq87)
Posts: 6
Member Registered
Topic starter
 

Hi !
I am getting False when i enter the text "But the problem is that there are very few legit ways to make a professional email address for free"
i have written code as posted in the learning resources. Kindly Help and state what is the reason for getting False.
here is below code:

from selenium import webdriver
from selenium_stealth import stealth
from bs4 import BeautifulSoup
from urllib.parse import urlparse
import urllib
import difflib
import html2text
from selenium.webdriver.chrome.service import Service

def search_google(text):
options = webdriver.ChromeOptions()
options.add_argument("--headless")
options.add_experimental_option("excludeSwitches", ["enable-automation"])
options.add_experimental_option("useAutomationExtension", False)
executable_path = "/Users/mohamedthoufeeq/Downloads/chromedriver-mac-x64/chromedriver"
chrome_service = Service(executable_path=executable_path)
driver = webdriver.Chrome(service=chrome_service, options=options)

stealth(
driver,
languages=["en-US", "en"],
vendor="Google Inc.",
platform="mac-x64",
webgl_vendor="Intel Inc.",
renderer="Intel Iris OpenGL Engine",
fix_hairline=True,
)

text = "But the problem is that there are very few legit ways to make a professional email address for free"
query = text

n_pages = 2
results = []
counter = 0
for page in range(1, n_pages):
url = (
"http://www.google.com/search?q=" + query + "&start=" + str((page - 1) * 10)
)
driver.get(url)
soup = BeautifulSoup(driver.page_source, "html.parser")
search = soup.find_all("div", class_="yuRUbf")
for h in search:
counter = counter + 1
title = h.a.h3.text
link = h.a.get("href")
rank = counter
results.append(link)

driver.quit()
return results


def check_plagiarism(text):
results = search_google(text)
for result in results:
try:
print(result)
uf = urllib.request.urlopen(result)
html = uf.read()
soup = BeautifulSoup(html)
plain_html = soup.get_text()
if text in plain_html:
return True

except Exception as e:
print(e)
continue

return False
 
Posted : 05/25/2024 2:10 pm
(@thoufeeq87)
Posts: 6
Member Registered
Topic starter
 

Hi 
Also Refer the output received in during running the program
INFO: Started server process [52100]
INFO: Waiting for application startup.
INFO: Application startup complete.
INFO: Uvicorn running on http://0.0.0.0:8000 (Press CTRL+C to quit)
INFO: 127.0.0.1:59862 - "GET / HTTP/1.1" 404 Not Found
INFO: 127.0.0.1:59866 - "GET /cart.json HTTP/1.1" 404 Not Found
INFO: 127.0.0.1:59863 - "GET /docs HTTP/1.1" 200 OK
INFO: 127.0.0.1:59863 - "GET /openapi.json HTTP/1.1" 200 OK
INFO: 127.0.0.1:59868 - "GET /cart.json HTTP/1.1" 404 Not Found
https://www.isitwp.com/how-to-create-a-free-business-email/
HTTP Error 403: Forbidden
https://www.one.com/en/email/how-to-create-a-professional-business-email-address
/Users/mohamedthoufeeq/PycharmProjects/youtube_api/plagiarism.py:60: GuessedAtParserWarning: No parser was explicitly specified, so I'm using the best available HTML parser for this system ("html.parser"). This usually isn't a problem, but if you run this code on another system, or in a different virtual environment, it may use a different parser and behave differently.

The code that caused this warning is on line 60 of the file /Users/mohamedthoufeeq/PycharmProjects/youtube_api/plagiarism.py. To get rid of this warning, pass the additional argument 'features="html.parser"' to the BeautifulSoup constructor.

soup = BeautifulSoup(html)
https://blog.hubspot.com/marketing/free-email-accounts
https://nethunt.com/blog/how-to-choose-professional-email-address/
https://www.crazydomains.com/help/article/can-i-create-email-addresses-without-setting-up-a-website
HTTP Error 403: Forbidden
https://www.zoho.com/mail/how-to/create-business-email-address.html
https://www.neo.space/blog/how-to-create-free-professional-business-email-without-domain
https://www.wpbeginner.com/beginners-guide/how-to-create-a-free-business-email-address-in-5-minutes-step-by-step/
HTTP Error 403: Forbidden
https://blog.flock.com/free-personalized-email-address-without-domain-best-business-email-accounts
https://www.quora.com/What-are-some-tips-for-creating-a-professional-email-address
HTTP Error 403: Forbidden
https://www.mailbutler.io/blog/email/ideas-for-creating-professional-email-address/
https://www.rightinbox.com/blog/ideas-for-creating-a-professional-email-address
https://kinsta.com/blog/professional-email-address/
HTTP Error 403: Forbidden
INFO: 127.0.0.1:59871 - "POST /plagiarism/checker?text=But%20the%20problem%20is%20that%20there%20are%20very%20few%20legit%20ways%20to%20make%20a%20professional%20email%20address%20for%20free HTTP/1.1" 200 OK

Thank you

 

 
Posted : 05/25/2024 2:12 pm
Hasan Aboul Hasan
(@admin)
Posts: 1207
Member Admin
 

HI friend, first as menti0oned in the course, this is a prototype, and cant be user in production environment. for more in depth tutorial on building plagiarism checker, please check our blog posts:

https://learnwithhasan.com/how-to-build-a-plagiarism-detector-using-python/
https://learnwithhasan.com/how-to-build-a-semantic-plagiarism-detector/

anyway, please add breakpoints, and check there

plain_html = soup.get_text()
            if text in plain_html:
                return True

see if the text is fetched correctly or not

 
Posted : 05/25/2024 4:24 pm
(@thoufeeq87)
Posts: 6
Member Registered
Topic starter
 

@admin Okay I have noted will try again.
There is one more issue in Build and Sell API course when I click Create an API. 
The video is not playing. When I use Mobile the page keeps on going to first page and not opening.

Screenshot 2024 05 27 120931
 
Posted : 05/27/2024 8:12 am
(@husein)
Posts: 464
Member Moderator
 

@thoufeeq87 I just opened the same page and it opened, try to clear the cache, and refresh.

 
Posted : 05/28/2024 9:24 am
SSAdvisor reacted
Hasan Aboul Hasan
(@admin)
Posts: 1207
Member Admin
 

@thoufeeq87, in which country are you trying to access the website? can you try a VPN or so?

 
Posted : 05/28/2024 9:36 am
SSAdvisor reacted
(@thoufeeq87)
Posts: 6
Member Registered
Topic starter
 

@admin  It has worked... Thank you

 
Posted : 05/28/2024 2:53 pm
Share:
build ai agents ad