Skip to content

fix(example): Inform user if no data yet#171

Open
tyeth wants to merge 1 commit intomasterfrom
digital-out-no-data-yet-159
Open

fix(example): Inform user if no data yet#171
tyeth wants to merge 1 commit intomasterfrom
digital-out-no-data-yet-159

Conversation

@tyeth
Copy link
Member

@tyeth tyeth commented Feb 12, 2026

Fixes #159

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the digital_out.py basic example to handle the “404 Not Found” scenario from Adafruit IO more gracefully by informing the user when the feed has no data yet (Issue #159).

Changes:

  • Refactors the feed lookup/create block formatting and normalizes string quotes.
  • Wraps aio.receive(...) in a try/except and attempts to detect the “no data yet” 404 case to print a helpful message + slow down polling.
  • Introduces a variable sleep duration to reduce request frequency when no data is present.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@tyeth tyeth force-pushed the digital-out-no-data-yet-159 branch from 742c645 to 739d6be Compare February 12, 2026 20:40
Copy link
Member

@brentru brentru left a comment

Choose a reason for hiding this comment

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

LGTM

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.

Adafruit_IO.errors.RequestError: Adafruit IO request failed: 404 Not Found - not found

2 participants

Comments