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

Instance Uptime #884

Merged
merged 93 commits into from
Feb 16, 2024
Merged

Instance Uptime #884

merged 93 commits into from
Feb 16, 2024

Conversation

Sjmarf
Copy link
Contributor

@Sjmarf Sjmarf commented Jan 29, 2024

Adds an "Uptime" tab to instance pages. Uptime data is fetched from https://lemmy-status.org. Lemmy-status watches a set list of instances - if an instance isn't on that list, the tab won't be shown. I'm storing a list of supported instances as a static property within Mlem - if lemmy-status ever changes their list of supported instances, we'd have to update ours too.

The data refreshes automatically every 30 seconds.

When the instance page is opened, Mlem attempts to contact the instance for site information. If this request fails and the instance is supported by lemmy-status, it'll attempt to show the uptime view instead of ErrorView.

@Sjmarf Sjmarf mentioned this pull request Feb 4, 2024
@Sjmarf Sjmarf marked this pull request as ready for review February 11, 2024 16:20
Copy link
Member

@EricBAndrews EricBAndrews left a comment

Choose a reason for hiding this comment

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

Looks good! Super useful feature for a federated social media app.

Left a couple minor notes on design/wording.

Mlem/Views/Shared/Instance/InstanceUptimeView.swift Outdated Show resolved Hide resolved
Mlem/Views/Shared/Instance/InstanceUptimeView.swift Outdated Show resolved Hide resolved
Mlem/Views/Shared/Instance/InstanceUptimeView.swift Outdated Show resolved Hide resolved
Mlem/Icons.swift Outdated Show resolved Hide resolved
@EricBAndrews
Copy link
Member

Nice 👍

@Sjmarf Sjmarf enabled auto-merge (squash) February 16, 2024 13:34
@Sjmarf Sjmarf merged commit 38f632b into dev Feb 16, 2024
4 checks passed
@Sjmarf Sjmarf deleted the sjmarf/instance-uptime branch February 16, 2024 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request ui Related to UI Fixes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants