GothenburgBitFactory / bugwarrior

Pull github, bitbucket, and trac issues into taskwarrior
http://pypi.python.org/pypi/bugwarrior
GNU General Public License v3.0
736 stars 209 forks source link

Feature Request: create ability to load tasks from HTTP service #770

Open StephanMeijer opened 3 years ago

StephanMeijer commented 3 years ago

This'd be useful for me, because this'll enable me to grab tasks from my own HTTP services.

ryneeverett commented 3 years ago

I don't know what this means. Is it about using unencrypted services or a new service api?

StephanMeijer commented 3 years ago

What I am imagining is a service, to use simple HTTP requests in order to obtain new tasks.

For example my own HTTP endpoint:

GET /washingmachine

[
{
"description": "Washingmachine is now done. Clear out washingmachine",
"entry":"20201103T201940Z",
"modified":"20201103T202001Z",
"priority":"L",
"project":"Home",
"tags":["home","organize"]
}
]

So that automatically a task to clear out the washingmachine will be created if my washingmachine is done and not running.

ryneeverett commented 3 years ago

Great idea integrating taskwarrior with IOT. However I'm not sure how much value bugwarrior has when you're fetching data that's already in taskwarrior's expected format. Bugwarrior's main value is in translating from a variety of different data formats into taskwarrior's format. For your use case it seems like you'd be just as well off with (pseudo-code) curl /washingmachine | task import.

StephanMeijer commented 3 years ago

Good point, although I suspect it'd require me on my point to manage the completion of this task on my own. So i'd need to write a framework around it. And it would be a framework like Bugwarrior. So then we go full cycle.

ryneeverett commented 3 years ago

I'm not sure what aspects you're referring to as "framework". I wouldn't be opposed to this as long as bugwarrior is providing notable value beyond only-having-to-run-one-command-to-update-tasks.

Also, more generally, it might make sense to implement a plugin api so that people can use custom services without them having to be community maintained. On the other hand I'm not sure our current api is all that great and it might be inconvenient to have to consider backwards compatibility when refactoring.

StephanMeijer commented 3 years ago

@ryneeverett I thought of exactly that this month, but indeed: would be somewhat difficult but not impossible.

ryneeverett commented 3 years ago

I'm not sure what aspects you're referring to as "framework". I wouldn't be opposed to this as long as bugwarrior is providing notable value beyond only-having-to-run-one-command-to-update-tasks.

Any thoughts on this?

StephanMeijer commented 3 years ago

@ryneeverett Yep: a normal import does not keep track of the tasks already imported. Also Bugwarrior gives the ability to easily configure things

ryneeverett commented 3 years ago

a normal import does not keep track of the tasks already imported

If the uuid is the same, the existing task will be edited. What's the difference?

StephanMeijer commented 3 years ago

What if the remote returns an empty list? Then there won't be any task to import, so the task already imported won't be set to completed, right?

ryneeverett commented 3 years ago

What if the remote returns an empty list? Then there won't be any task to import, so the task already imported won't be set to completed, right?

True