Bug 271441 - Task couldn't be added to server if smart list is selected
Summary: Task couldn't be added to server if smart list is selected
Status: RESOLVED FIXED
Alias: None
Product: plasma4
Classification: Plasma
Component: widget-rememberthemilk (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-04-21 19:37 UTC by Alexey Chernov
Modified: 2011-04-21 20:17 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexey Chernov 2011-04-21 19:37:50 UTC
Version:           unspecified (using KDE 4.6.1) 
OS:                Linux

Several days ago Remember The Milk started to block rtm.tasks.add method with list_id of the list which is smart. Plasmoid throws the following message to its out:

plasmoidviewer(3606)/kio (KIOJob) KIO::TransferJob::slotFinished: KUrl("http://api.rememberthemilk.com/services/rest/?&api_key=631e881f0e5671d237c1a2a0a64d5b98&api_sig=dea5592f76f59dc9820b4c480f167add&auth_token=a5d0ac18709c16ffe8168c38f4b0805559dba6d0&list_id=12892448&method=rtm.tasks.add&name=test1&parse=1&timeline=496099973")
plasmoidviewer(3606)/kio (Scheduler) KIO::SchedulerPrivate::jobFinished: KIO::TransferJob(0x1d2de00) KIO::Slave(0x1bb5530)
plasmoidviewer(3606) RTM::TasksReader::readUnknownElement: Unknown Element:  "StartElement" "err" ""
plasmoidviewer(3606) RTM::TasksReader::readUnknownElement: Attributes:
plasmoidviewer(3606) RTM::TasksReader::readUnknownElement: "code" "4020"
plasmoidviewer(3606) RTM::TasksReader::readUnknownElement: "msg" "Cannot add task to a Smart List."
plasmoidviewer(3606) RTM::SessionPrivate::populateSmartList: Populating Smart List:  "Все задачи"

So we need to check if current list in plasmoid is smart and omit list_id attribute if so, RTM will add the task to default input list (e.g. Inbox in most cases)

Reproducible: Always

Steps to Reproduce:
1. Login and select the list which is smart list.
2. Enter a task command to add a task.
3. Notice that no task was added neither in plasmoid nor on web interface.
Comment 1 Alexey Chernov 2011-04-21 19:44:32 UTC
Git commit fcc8240f9e61fe7a8f0be6776b8a6a562c30386f by Alexey Chernov.
Committed on 21/04/2011 at 19:48.
Pushed by chernov into branch 'master'.

Fix adding a task to smart list

Fix adding a task to smart list if it is currently selected (add to default list in this case).

BUG:271441

M  +4    -1    libs/rtm/session.cpp     

http://commits.kde.org/kdeplasma-addons/fcc8240f9e61fe7a8f0be6776b8a6a562c30386f
Comment 2 Alexey Chernov 2011-04-21 20:16:50 UTC
Git commit 6acbf6b2b1d80357013e39624cf1336ed3e2ff72 by Alexey Chernov.
Committed on 21/04/2011 at 19:48.
Pushed by chernov into branch 'KDE/4.6'.

Fix adding a task to smart list

Fix adding a task to smart list if it is currently selected (add to default list in this case).

BUG:271441

M  +4    -1    libs/rtm/session.cpp     

http://commits.kde.org/kdeplasma-addons/6acbf6b2b1d80357013e39624cf1336ed3e2ff72
Comment 3 Alexey Chernov 2011-04-21 20:17:38 UTC
Git commit 5272bf2f6b549216567b4c15a3e5fa06ef889a42 by Alexey Chernov.
Committed on 21/04/2011 at 19:48.
Pushed by chernov into branch '4.6'.

Fix adding a task to smart list

Fix adding a task to smart list if it is currently selected (add to default list in this case).

BUG:271441

M  +4    -1    libs/rtm/session.cpp     

http://commits.kde.org/kdeplasma-addons/5272bf2f6b549216567b4c15a3e5fa06ef889a42