示例#1
0
文件: rss_feed_2.py 项目: jchen97/v1
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
示例#2
0
文件: rss_feed.py 项目: jchen97/v1
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
示例#3
0
文件: rss_feed_2.py 项目: jchen97/v1
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
示例#4
0
文件: rss_feed.py 项目: jchen97/v1
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
示例#5
0
文件: rss_feed.py 项目: jchen97/v1
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
示例#6
0
文件: rss_feed.py 项目: jchen97/v1
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
示例#7
0
文件: rss_feed.py 项目: jchen97/v1
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
示例#8
0
文件: rss_feed_2.py 项目: jchen97/v1
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
示例#9
0
文件: rss_feed.py 项目: jchen97/v1
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
示例#10
0
文件: rss_feed_2.py 项目: jchen97/v1
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
示例#11
0
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
示例#12
0
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
示例#13
0
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