Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Thanksgiving Day app to dynamically calculate days till thanksgiving #2872

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

savdagod
Copy link

@savdagod savdagod commented Nov 9, 2024

Current logic is hard coded for 2024 and 2025. This update changes the logic to calculate the days indefinitely.

@tidbyt
Copy link

tidbyt bot commented Nov 9, 2024

⚠️ The automated review process is experimental and likely has bugs. Please bear with us as we iron out the kinks and enable you to ship changes at high velocity 🚀

Next Steps

Hello! Thank you so much for your change 🤜 🤛 . There are a few things you need to do:

  • Sign the CLA if you haven't already
  • Ensure your build is green! Any problem will display a proposed solution to try out
  • Get a review, either by Tidbyt Bot or by a Tidbyt engineer

Manual Review Required

Hang tight! A Tidbyt engineer will be by shortly to review your change. Here is what they will be looking for:

Test Details
App Dir All files are in a single app directory
Modules Only safe modules, without side-effects, are loaded
🟡 Original Author The original author (jalexcooney) does not match the PR author (savdagod)

@tidbyt-bot
Copy link

tidbyt-bot commented Nov 9, 2024

CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅

tidbyt[bot]
tidbyt bot previously approved these changes Nov 9, 2024
@savdagod
Copy link
Author

savdagod commented Nov 9, 2024

I have read the CLA Document and I hereby sign the CLA

@savdagod savdagod changed the title Dynamically calculate days till thanksgiving Update Thanksgiving Day app to dynamically calculate days till thanksgiving Nov 10, 2024
print(thanksgiving)
days_til_thanksgiving = math.ceil(time.parse_duration(thanksgiving - now).seconds / 86400)
print(days_til_thanksgiving)
timezone = config.get("timezone") or "America/New_York"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be timezone = config.get("$tz", "America/New_York")?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants