def ptab(): headlines = feedparser.parse( "https://developer.uspto.gov/ptab-feed/notifications.rss") try: new = headlines.entries[0].title if new not in urls.values(): ticker = ticker_finder.find_ticker(headlines.entries[0].author) search1 = "EMPTY" search2 = "EMPTY" # Detects relevant keywords. Returns a string that may or may not be modified> # new = keyword_search.detect(new) formatV1.rss_printout(headlines, ticker, 0) print("\t" + Color.YELLOW + headlines.entries[0].author + Color.END) print("\t" + headlines.entries[0].summary) urls[ "https://developer.uspto.gov/ptab-feed/notifications.rss"] = new if (search1 in headlines.entries[0].title) or ( search2 in headlines.entries[0].title): print("CORT") winsound.PlaySound( r'C:\Users\Trader\Documents\WavSounds\alarm_beep.wav', winsound.SND_FILENAME) except IndexError: pass
def ftcprl(): headlines = feedparser.parse("https://www.ftc.gov/feeds/press-release.xml") try: new = headlines.entries[0].title if new not in urls.values(): ticker = ticker_finder.find_ticker(new) formatV1.rss_printout(headlines, ticker, 0) print("\t") urls["https://www.ftc.gov/feeds/press-release.xml"] = new winsound.Beep(2020, 1000) except IndexError: pass
def cnnhealth(): headlines = feedparser.parse("http://rss.cnn.com/rss/cnn_health.rss") try: new = headlines.entries[0].title if new not in urls.values(): ticker = ticker_finder.find_ticker(new) # Detects relevant keywords. Returns a string that may or may not be modified> # new = keyword_search.detect(new) formatV1.rss_printout(headlines, ticker, 0) print("\t" + headlines.entries[0].summary) urls["http://rss.cnn.com/rss/cnn_health.rss"] = new winsound.Beep(2020, 1000) except IndexError: pass
def insideev(): headlines = feedparser.parse("https://insideevs.com/rss/news/all/") try: new = headlines.entries[0].title if new not in urls.values(): ticker = ticker_finder.find_ticker(new) formatV1.rss_printout(headlines, ticker, 0) print("\t" + headlines.entries[0].summary) urls["https://insideevs.com/rss/news/all/"] = new winsound.PlaySound( r'C:\Users\Trader\Documents\WavSounds\electricshock.wav', winsound.SND_FILENAME) except IndexError: pass
def nypmain(): headlines = feedparser.parse("https://nypost.com/feed/") try: new = headlines.entries[0].title if new not in urls.values(): ticker = ticker_finder.find_ticker(new) if headline_filter.filterit(new, ticker): formatV1.rss_printout(headlines, ticker, 0) print("\t" + Color.YELLOW + headlines.entries[0].author + Color.END) print("\t" + headlines.entries[0].summary) urls["https://nypost.com/feed/"] = new # winsound.PlaySound(r'C:\Users\Trader\Documents\WavSounds\blip.wav', winsound.SND_FILENAME) except IndexError: pass
def techcrunch(): headlines = feedparser.parse("https://techcrunch.com/feed/") try: new = headlines.entries[0].title if new not in urls.values(): ticker = ticker_finder.find_ticker(new) formatV1.rss_printout(headlines, ticker, 0) urls["https://techcrunch.com/feed/"] = new winsound.PlaySound( r'C:\Users\Trader\Documents\WavSounds\electricshock.wav', winsound.SND_FILENAME) except IndexError: pass
def fdaprl(): headlines = feedparser.parse( "https://www.fda.gov/about-fda/contact-fda/stay-informed/rss-feeds/press-releases/rss.xml" ) try: new = headlines.entries[0].title if new not in urls.values(): ticker = ticker_finder.find_ticker(new) formatV1.rss_printout(headlines, ticker, 0) print("\t" + headlines.entries[0].summary) urls[ "https://www.fda.gov/about-fda/contact-fda/stay-informed/rss-feeds/press-releases/rss.xml"] = new winsound.Beep(1997, 1000) except IndexError: pass
def statnews(): headlines = feedparser.parse("https://www.statnews.com/feed/") try: new = headlines.entries[0].title if new not in urls.values(): ticker = ticker_finder.find_ticker(new) # Detects relevant keywords. Returns a string that may or may not be modified> # new = keyword_search.detect(new) formatV1.rss_printout(headlines, ticker, 0) print("\t" + headlines.entries[0].summary) urls["https://www.statnews.com/feed/"] = new winsound.PlaySound( r'C:\Users\Trader\Documents\WavSounds\chewy_roar.wav', winsound.SND_FILENAME) except IndexError: pass
def zerotv(): headlines = feedparser.parse( "https://www.zer0es.tv/category/big-announcements/feed/") try: new = headlines.entries[0].title if new not in urls.values(): ticker = ticker_finder.find_ticker(new) formatV1.rss_printout(headlines, ticker, 0) print("\t" + headlines.entries[0].summary) urls[ "https://www.zer0es.tv/category/big-announcements/feed/"] = new winsound.PlaySound( r'C:\Users\Trader\Documents\WavSounds\gun_44mag_11.wav', winsound.SND_FILENAME) except IndexError: pass
def itc1(): headlines = feedparser.parse( "https://edis.usitc.gov/external/rss/render.rss/?criteria=CRITERIONINVDEL:4788:PHASE:Violation:CRITERIONANOTIFY:true" ) try: new = headlines.entries[0].title if new not in urls.values(): ticker = ticker_finder.find_ticker(new) # Detects relevant keywords. Returns a string that may or may not be modified> # new = keyword_search.detect(new) formatV1.rss_printout(headlines, ticker, 0) print("\t" + headlines.entries[0].summary) urls[ "https://edis.usitc.gov/external/rss/render.rss/?criteria=CRITERIONINVDEL:4788:PHASE:Violation:CRITERIONANOTIFY:true"] = new winsound.PlaySound( r'C:\Users\Trader\Documents\WavSounds\buzzer_SHORT', winsound.SND_FILENAME) except IndexError: pass
def verge(): headlines = feedparser.parse("https://www.theverge.com/rss/index.xml") try: global count new = headlines.entries[0].title if new not in articles.values(): ticker = ticker_finder.find_ticker(new) # Detects relevant keywords. Returns a string that may or may not be modified> # new = keyword_search.detect(new) formatV1.rss_printout(headlines, ticker, 0) articles[count] = new count += 1 print(count) winsound.PlaySound( r'C:\Users\Trader\Documents\WavSounds\pewpew.wav', winsound.SND_FILENAME) except IndexError: pass
def cnbcEU(): headlines = feedparser.parse( "https://www.cnbc.com/id/19832390/device/rss/rss.html") global count try: new = headlines.entries[0].title if new not in articles.values(): ticker = ticker_finder.find_ticker(new) # Detects relevant keywords. Returns a string that may or may not be modified> # new = keyword_search.detect(new) formatV1.rss_printout(headlines, ticker, 0) print("\t" + headlines.entries[0].summary) articles[count] = new count += 1 print(count) winsound.PlaySound(r'C:\Users\Trader\Documents\WavSounds\cnbcchime.wav', winsound.SND_FILENAME) except IndexError: pass
def courtB(): link = "https://ecf.ded.uscourts.gov/cgi-bin/rss_outside.pl" target = "Biogen" headlines = feedparser.parse(link) try: new = headlines.entries[0].title if new not in urls.values(): ticker = ticker_finder.find_ticker(new) # Detects relevant keywords. Returns a string that may or may not be modified> # new = keyword_search.detect(new) formatV1.rss_printout(headlines, ticker, 0) print("\t" + headlines.entries[0].summary) urls[link] = new if target in new: print("\t" + "!!!" + Color.LTRED + ("<BIOGEN>" * 10) + Color.END + "!!!") winsound.PlaySound(r'C:\Users\Trader\Documents\WavSounds\boxing_bell_multiple.wav', winsound.SND_FILENAME) else: winsound.PlaySound(r'C:\Users\Trader\Documents\WavSounds\bloop_x.wav', winsound.SND_FILENAME) except IndexError: pass