After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 761766 - Online account status shows "on" when credentials have expired
Online account status shows "on" when credentials have expired
Status: RESOLVED FIXED
Product: gnome-calendar
Classification: Applications
Component: General
3.19.x
Other Linux
: Normal normal
: 3.26
Assigned To: GNOME Calendar maintainers
GNOME Calendar maintainers
Depends on:
Blocks:
 
 
Reported: 2016-02-09 12:40 UTC by Allan Day
Modified: 2017-04-17 18:20 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
show "Attention needed" if account is inaccessible (1.59 KB, patch)
2017-01-30 20:18 UTC, Shubham Kumaram
needs-work Details | Review
gcal-source-dialog: Change label to "Expired" if account credentials expired (1.28 KB, patch)
2017-03-08 14:48 UTC, Yash
none Details | Review
source-dialog: Change label to "Expired" if account credentials expired (1.28 KB, patch)
2017-03-10 13:00 UTC, Yash
none Details | Review
source-dialog: change label to "Expired" if account credentials expire (1.28 KB, patch)
2017-03-12 16:21 UTC, Yash
committed Details | Review

Description Allan Day 2016-02-09 12:40:14 UTC
Testing 3.19.x with GNOME Continuous from four days ago:

I set up my Google account during initial setup. When I launched Calendar for the first time, I was surprised that it didn't show any events. When I checked the calendar settings, it showed my Google account as "On". I later checked the online account settings, which indicated that the credentials had expired for the account.

There are several bugs here. One of them is that Calendar should indicate if the credentials have expired for an online account.
Comment 1 Shubham Kumaram 2017-01-30 20:18:29 UTC
Created attachment 344579 [details] [review]
show "Attention needed" if account is inaccessible

This shows "Attention Needed" instead of "On"/"Off" if account credentials have expired and human interaction is needed.
Comment 2 Georges Basile Stavracas Neto 2017-02-20 11:39:44 UTC
Review of attachment 344579 [details] [review]:

The code is simple, and I like that. The commit message needs to be adjusted to reflect this review. Also, the commit title is not quite following GNOME Calendar's style. See [1] for reference.

[1] https://git.gnome.org/browse/gnome-calendar/log/?h=wip/gbsneto/quick-add-popover

::: src/gcal-source-dialog.c
@@ +2023,3 @@
   gtk_label_set_label (GTK_LABEL (account_label), goa_account_get_identity (account));
   gtk_label_set_label (GTK_LABEL (enabled_label),
+                       goa_account_get_attention_needed (account) ? _("Attention Needed") :

You should check if the account is expired, and show an "Expired" label instead.
Comment 3 Yash 2017-03-08 14:48:06 UTC
Created attachment 347489 [details] [review]
gcal-source-dialog: Change label to "Expired" if account credentials expired

Earlier Calendar showed an account as "on" even when the credentials had expired.
This patch fixes the issue and instead shows "Expired" label upon expiration
of credentials.
Comment 4 Yash 2017-03-10 12:54:14 UTC
Comment on attachment 347489 [details] [review]
gcal-source-dialog: Change label to "Expired" if account credentials expired

>From 6b9617a448e06db4135c81bb79df7a7fc4ec63c4 Mon Sep 17 00:00:00 2001
>From: Yash Singh <yashdev10p@gmail.com>
>Date: Wed, 8 Mar 2017 20:15:41 +0530
>Subject: [PATCH] source-dialog: Change label to "Expired" if account
> credentials expired
>
>Earlier Calendar showed an account as "on" even when the credentials had expired.
>This patch fixes the issue and instead shows "Expired" label upon expiration
>of credentials.
>
>https://bugzilla.gnome.org/show_bug.cgi?id=761766
>---
> src/gcal-source-dialog.c | 1 +
> 1 file changed, 1 insertion(+)
>
>diff --git a/src/gcal-source-dialog.c b/src/gcal-source-dialog.c
>index ad90f85..d48d0de 100644
>--- a/src/gcal-source-dialog.c
>+++ b/src/gcal-source-dialog.c
>@@ -2051,6 +2051,7 @@ add_goa_account (GcalSourceDialog *dialog,
>   gtk_label_set_label (GTK_LABEL (provider_label), goa_account_get_provider_name (account));
>   gtk_label_set_label (GTK_LABEL (account_label), goa_account_get_identity (account));
>   gtk_label_set_label (GTK_LABEL (enabled_label),
>+                       goa_account_get_attention_needed (account) ? _("Expired") :
>                        goa_account_get_calendar_disabled (account) ? _("Off") : _("On"));
>   gtk_image_set_from_icon_name (GTK_IMAGE (icon), icon_name, GTK_ICON_SIZE_DIALOG);
>   gtk_image_set_pixel_size (GTK_IMAGE (icon), 32);
>-- 
>2.9.3
Comment 5 Yash 2017-03-10 13:00:57 UTC
Created attachment 347627 [details] [review]
source-dialog: Change label to "Expired" if account credentials expired

Earlier Calendar showed an account as "on" even when the credentials had expired. This patch fixes the issue and instead shows "Expired" label upon expiration of credentials.
Comment 6 Yash 2017-03-12 16:21:18 UTC
Created attachment 347758 [details] [review]
source-dialog: change label to "Expired" if account credentials expire

Earlier Calendar showed an account as "on" even when the credentials had expired.

This patch fixes the issue and instead shows "Expired" label upon expiration of credentials.
Comment 7 Georges Basile Stavracas Neto 2017-03-15 00:32:25 UTC
Review of attachment 347758 [details] [review]:

Looks good.
Comment 8 Georges Basile Stavracas Neto 2017-03-27 12:11:38 UTC
Thanks for the patch.

Attachment 347758 [details] pushed as 7e68bfb - source-dialog: change label to "Expired" if account credentials expire