Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Notification config value being ignored

See original GitHub issue

Hi, it seems that (at least using telegram notifications) the value for notify_xday_threshold is always considered to be True.

Also, to avoid spamming I think it would be much better if a notification was sent only if a loan offer was filled. Currently notify_xday_threshold sends a notification every time a loan offer is placed, and since the bot cancels and replaces all orders every minute or so, this can result in a lot of notifications being sent.

Granted, I am using a very large value for gaptop (20000%), so my bot almost always has an xday offer open.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

kryogeniccommented, Mar 29, 2017

Ok I went ahead and partially implemented this, it’s quite messy and just prints to console instead of actually sending the notifications but hopefully this gives you something to work off of!

All I did was add a little bit to the top of get_total_lends() in modules/

loans_provided = {}

def get_total_lended():
    global loans_provided
    crypto_lended = api.return_active_loans()
    if loans_provided == {}:
        loans_provided = crypto_lended['provided']
        new_loan_ids = set(map(lambda l: l['id'], crypto_lended['provided'])) - set(map(lambda l: l['id'], loans_provided))
        if new_loan_ids:
            print('new loans found: ', new_loan_ids)

This implementation does have some issues, it will report any new loans regardless of whether the bot placed the order, and will not report updates if orders are filled while the bot is offline. I think it’s a good start though.

kryogeniccommented, Apr 8, 2017

Closed #281

Read more comments on GitHub >

github_iconTop Results From Across the Web

Config value being ignored - Stack Overflow
Config value being ignored · 1 · @Ardman is on to something, if the application is "started", the Application_Start won't fire. · Though...
Read more >
Notification_config on alert rules are not ignored properly #7
Removing the notification config and creating an empty alert rule seems to work just fine. Tried multiple combinations, using data sources, ...
Read more >
Notification Settings Being Ignored - Gravity Support Forums
I've tried changing my notifications setting multiple times, it would appear that doing so does not take affect on my forms. I'm trying...
Read more >
Ignore bad data while PI Notifications trigger is True - PI Square
I've developed a "workaround" by doing an Analysis calculation prior to the Notification check (basically if BadVal is true don't do anything). This...
Read more >
End user notification intervals being ignored in
One of the related values "general_end_notice_first" is correctly loaded from the variable table and available for use. But the second one ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found