From 34cce5f2baa28a5803823826eff72e1861885ad7 Mon Sep 17 00:00:00 2001 From: malkaroy-vrrp <82731753+malkaroy-vrrp@users.noreply.github.com> Date: Mon, 28 Jun 2021 21:53:42 -0700 Subject: [PATCH 1/2] Fix Output on errors Fixed output and made emojis more consistent. --- main.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/main.py b/main.py index 0cbe7f9..187105c 100644 --- a/main.py +++ b/main.py @@ -582,6 +582,7 @@ async def puplist(ctx): @client.command() async def fodl(ctx, *, username): message = ctx.message + clickerStr = "<:arrow_right:856238567713800222> Click here for: " #hard-coding mining channel in here for now. no one else should need this command... #could allow this in private message, but don't want to pollute the global with everyones chat id's if message.channel.id != 566268199210057728: # and not is_private(message.channel): @@ -643,7 +644,6 @@ async def fodl(ctx, *, username): await message.add_reaction('\U000026D4') if (isCorrect): - clickerStr = "<:arrow_right:856238567713800222> Click here for: " if "last" in banTeam: #might need to investigate further but sometimes fah api doesn't have data... output+="<:white_check_mark:835347973503451176> " + str(banTeam["last"])+" UTC : Last Completed Banano WU\n" output+="<:white_check_mark:835347973503451176> "+str(banTeam["wus"])+" work units completed so far.\n" @@ -666,14 +666,14 @@ async def fodl(ctx, *, username): progresso = True if cpu["active"]==1: bonus = True - output += "<:white_check_mark:835347973503451176> Passkey Bonus Active\n" + output += "<:closed_lock_with_key:856254383729016883> Passkey Bonus Active\n" await message.add_reaction('\U0001F510')#lock/key break if bonus ==False and progresso == True: #passkey in porgress - output += "<:grey_exclamation:835357988432642049> Passkey Bonus Not Active, but appears to be in progress\n"+clickerStr+ "[Passkey Bonus Info](https://foldingathome.org/support/faq/points/?lng=en-US#what-are-the-qualifications-for-the-qrb)\nPasskey Requires 10 work units completed after adding to client to activate." + output += "<:children_crossing:856246670193983528> Passkey Bonus Not Active, but appears to be in progress\n"+clickerStr+ "[Passkey Bonus Info](https://foldingathome.org/support/faq/points/?lng=en-US#what-are-the-qualifications-for-the-qrb)\nPasskey Requires 10 work units completed after adding to client to activate." await message.add_reaction('\U0001F6B8')#caution sign? elif bonus ==False: #if there is no bonus entries, passkey is not entered (the issue here is a timeout could happen and not be deteceted...) - output += "<:grey_exclamation:835357988432642049> Passkey Bonus Not Active and does not appear to be entered \n <:arrow_right:856238567713800222> Click here to: [Get a Passkey](https://apps.foldingathome.org/getpasskey)\n"+clickerStr+ "[Passkey Bonus Info](https://foldingathome.org/support/faq/points/?lng=en-US#what-are-the-qualifications-for-the-qrb)\nPasskey Requires 10 work units completed after adding to client to activate." + output += "<:grey_exclamation:856251287104782366> Passkey Bonus Not Active and does not appear to be entered \n <:arrow_right:856238567713800222> Click here to: [Get a Passkey](https://apps.foldingathome.org/getpasskey)\n"+clickerStr+ "[Passkey Bonus Info](https://foldingathome.org/support/faq/points/?lng=en-US#what-are-the-qualifications-for-the-qrb)\nPasskey Requires 10 work units completed after adding to client to activate." await message.add_reaction('\U00002755')#exclamation mark #add reaction to message #This is not explicitly an issue, but calling it out in summary may hep in identifying wrong team issues, calling out the date(s) might also be helpful? From e3766abe3660313f7e885a3ab7e794d9338a01d3 Mon Sep 17 00:00:00 2001 From: malkaroy-vrrp <82731753+malkaroy-vrrp@users.noreply.github.com> Date: Tue, 29 Jun 2021 21:02:13 -0700 Subject: [PATCH 2/2] Update main.py --- main.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/main.py b/main.py index 187105c..c8daa13 100644 --- a/main.py +++ b/main.py @@ -650,7 +650,7 @@ async def fodl(ctx, *, username): output+="<:white_check_mark:835347973503451176> "+str(banTeam["score"])+" points received so far.\n" await message.add_reaction('\U0001F6F0') if len(bMinerJSON["payments"]) == 0: - output+="<:grey_exclamation:835357988432642049> No payments sent yet. First payment is within 24-36 hours of completing first Work Unit as long as you complete at least 2 work units (progress bar going to 100%) with at least one in each 12 hour period.\n" + output+="<:grey_exclamation:859296229941968946> No payments sent yet. First payment is within 24-36 hours of completing first Work Unit as long as you complete at least 2 work units (progress bar going to 100%) with at least one in each 12 hour period.\n" output+="<:banana:838483242113957898>Work Units Pending Payment: "+str(banTeam["wus"])+"\n" output+="<:banana:838483242113957898>Points Pending Payment: "+str(banTeam["score"])+"\n" await message.add_reaction('\U0001F6F0') @@ -673,12 +673,12 @@ async def fodl(ctx, *, username): output += "<:children_crossing:856246670193983528> Passkey Bonus Not Active, but appears to be in progress\n"+clickerStr+ "[Passkey Bonus Info](https://foldingathome.org/support/faq/points/?lng=en-US#what-are-the-qualifications-for-the-qrb)\nPasskey Requires 10 work units completed after adding to client to activate." await message.add_reaction('\U0001F6B8')#caution sign? elif bonus ==False: #if there is no bonus entries, passkey is not entered (the issue here is a timeout could happen and not be deteceted...) - output += "<:grey_exclamation:856251287104782366> Passkey Bonus Not Active and does not appear to be entered \n <:arrow_right:856238567713800222> Click here to: [Get a Passkey](https://apps.foldingathome.org/getpasskey)\n"+clickerStr+ "[Passkey Bonus Info](https://foldingathome.org/support/faq/points/?lng=en-US#what-are-the-qualifications-for-the-qrb)\nPasskey Requires 10 work units completed after adding to client to activate." + output += "<:grey_exclamation:859296229941968946> Passkey Bonus Not Active and does not appear to be entered \n <:arrow_right:856238567713800222> Click here to: [Get a Passkey](https://apps.foldingathome.org/getpasskey)\n"+clickerStr+ "[Passkey Bonus Info](https://foldingathome.org/support/faq/points/?lng=en-US#what-are-the-qualifications-for-the-qrb)\nPasskey Requires 10 work units completed after adding to client to activate." await message.add_reaction('\U00002755')#exclamation mark #add reaction to message #This is not explicitly an issue, but calling it out in summary may hep in identifying wrong team issues, calling out the date(s) might also be helpful? if nonBanWU > 0: - output+="<:grey_exclamation:835357988432642049> "+username + " has completed "+ str(nonBanWU) + " number of Work Units for teams other than Banano\n" + output+="<:grey_exclamation:859296229941968946> "+username + " has completed "+ str(nonBanWU) + " number of Work Units for teams other than Banano\n" if (isCorrect==False): output+="\nPlease review above errors. After updating client and completing another Work Unit: this test can be ran again to verify your client is set up to track points correctly.\n"