Saravanan666/pypi-org huggingface dataset:
Package: taskmg
Task-MgCopyright (c) 2015-2020 Jeremie DECOCK (http://www.jdhp.org)Web site:http://www.jdhp.org/projects_en.htmlSource code:https://github.com/jeremiedecock/taskmgIssue tracker:https://github.com/jeremiedecock/taskmg/issuesTask-Mg on PyPI:https://pypi.python.org/pypi/taskmgTask-Mg on Anaconda Cloud:https://anaconda.org/jdhp/taskmgDescriptionThis software is an open source task manager.WarningThis project is in beta stage.DependenciesPython >= 3.0Qt5 for PythonPandasInstallationGnu/LinuxYou can install, upgrade, uninstall Task-Mg with these commands (in a
terminal):pip install --pre taskmg
pip install --upgrade taskmg
pip uninstall taskmgOr, if you have downloaded the Task-Mg source code:python3 setup.py installWindowsYou can install, upgrade, uninstall Task-Mg with these commands (in acommand prompt):py -m pip install --pre taskmg
py -m pip install --upgrade taskmg
py -m pip uninstall taskmgOr, if you have downloaded the Task-Mg source code:py setup.py installMacOSXNote:The following installation procedure has been tested to work with Python
3.5 under MacOSX 10.9 (Mavericks).
It should also work with more recent MacOSX systems.You can install, upgrade, uninstall Task-Mg with these commands (in a
terminal):pip install --pre taskmg
pip install --upgrade taskmg
pip uninstall taskmgOr, if you have downloaded the Task-Mg source code:python3 setup.py installTask-Mg requires Qt5 and its Python 3 bindings plus few additional
libraries to run.Bug reportsTo search for bugs or report them, please use the Task-Mg Bug Tracker at:https://github.com/jeremiedecock/taskmg/issuesLicenseThis project is provided under the terms and conditions of theMIT License.
Package: task-multiprocess
run tasks in parallel,it can replace for loop to this way,easy and fasterfrom task_multiprocess.main import generate_queue,cpu_num,common_multiprocesscpu_num = 3
sample_list = list(range(100))[:] # [int,int,...] or [str,str,...] or ...
q, q_size, lock, public_list = generate_queue(sample_list,num=2) # num means how many public_list do you want,you can use index to use them like public_list[0] or othersdef add(ids):
index = ids[0]index = int(index)
fun(index) # fun is an function defined by yourselfcommon_multiprocess(add,1,cpu_num=cpu_num,q=q, q_size=q_size, lock=lock)new versionfrom task_multiprocess.main import TaskMultiprocess
TaskMultiprocess.cpu_num = 2
tm = TaskMultiprocess()
sample_list = list(range(1000))[:] # [int,int,...] or [str,str,...] or ...
q, q_size, lock, public_list = tm.generate_queue(sample_list,num=2) # num means how many public_list do you want,you can use index to use them like public_list[0] or othersdef add(ids):
index = ids[0]index = int(index)
fun(index) # fun is an function defined by yourselftm.common_multiprocess(add,q_num=1,q=q, cpu_num=tm.cpu_num,q_size=q_size, lock=lock)add is a function defined by yourself \q_num means how many variable do you want to get each timein this example only use index 0 to get one variable -> (index = ids[0]), you can also get 2,3 or more (a, b = ids[0],ids[1]), remember to replace 1 to the number you want
Package: task-object-storage
Transaction management for Robot Framework RPA using MongoDB.Included are two packages:tosandTOSLibrary.
The former is the actual task object storage implementation written in
pure Python, without any Robot Framework dependencies.TOSLibraryis
a Robot Framework keyword library built on top oftos. It is built as a
lightweight dynamic proxy library, so all the changes intosare immediately
available inTOSLibrarykeywords.Quickstart guideRequirementsMongoDB (version >4)Python (version >3.7)InstallationLatest stable version from PyPi withpip:pipinstalltask-object-storageLatest development version from PyPi:pipinstalltask-object-storage--preUsageYou can importTOSLibraryinto your Robot Framework suite with*** Settings ***LibraryTOSLibrary${db_server}:${db_port}  ${db_name}If you are using authentication in MongoDB, you can pass credentials:*** Settings ***LibraryTOSLibrary${db_server}:${db_port}  ${db_name}  ${db_user}  ${db_passw}You can also add prefix or suffix to the collection name:
By passing validcollection_suffixorcollection_prefixarguments toTOSLibrary,
you can create a collection with a nameyour_prefix.task_objects.your_suffixAdditional MongoClient options can be passed to the library as a dictionarymongo_client_options=.
For further details, see the PyMongo documentation:https://pymongo.readthedocs.io/en/4.3.3/api/pymongo/mongo_client.html*** Settings ***LibraryTOSLibrary${db_server}:${db_port}  ${db_name}  ${db_user}  ${db_passw}  ${collection_suffix}  ${collection_prefix}It is also possible to separate payloads of task objects to their own collection, and also optionally set a lifetime for them. See the full API documentation for further reference.After initialization, the keywords are callable from Robot Framework.This library instance can also be accessed inside Python keywords withfromrobot.libraries.BuiltInimportBuiltIntoslib=BuiltIn().get_library_instance("TOSLibrary")toslib.keyword_nameThe keywords can be also called with:BuiltIn().run_keyword("<keyword name>")To use task object storage in Python without any Robot Framework dependencies
you should usetospackage directly:fromtos.task_object_storageimportTaskObjectStoragetos=TaskObjectStorage(db_server=server,db_name=db_name,db_user=db_user,db_passw=db_passw,mongo_client_options=mongo_client_options,)Ifdb_useranddb_passware empty strings,TaskObjectStoragewill default
to using no authentication.Available keywordsSee the full API documentation.For developersRelease a new version by running:scripts/build.shreleaseYou can also install thewhlpackage found in thedistdirectory withpipinstall<package-name>.whlor put insiderequirements.txt:file:C:/path/to/<package-name>.whl  # on windows
file:/path/to/<package-name>.whl  # on linux
Package: taskotron-python-versions
This represents the automatic checks happening in the Fedora
infrastructure after any package is built.Currently the following checks are available:Whether a package does not require Python 2 and Python 3 at the same
time;Whether the package name follows the Python package naming scheme;Whether the package uses versioned Python prefix in requirements’ names;Whether only Python 2 version of the package contains the executables;Whether the package supports Python 3 upstream but not in the package;Whether the package requires/usr/bin/python(orpython-unversioned-command).RunningTo run this task locally, execute the following command as root (don’t do this
on a production machine!):$ ansible-playbook tests.yml -e taskotron_item=<nevr>wherenevris a Koji buildname-(epoch:)version-releaseidentifier.For example:$ ansible-playbook tests.yml -e taskotron_item=python-gear-0.11.0-1.fc27You can see the results in./artifacts/directory.You can also run the above in mock:$ mock -r ./mock.cfg --init
$ mock -r ./mock.cfg --copyin taskotron_python_versions *.py tests.yml /
$ mock -r ./mock.cfg --shell 'ansible-playbook tests.yml -e taskotron_item=python-gear-0.11.0-1.fc27'
$ mock -r ./mock.cfg --copyout artifacts artifactsTestsThis task is covered with functional and integration tests.
You can run them usingtox, but
you will needmock,python3-rpmandpython3-dnfinstalled.
For mock configuration seemock setupinstructions. Use the following command to run the test suite:$ toxThe integration tests may take a while to execute, as they are
running real tasks in mock. However, for development you may
speed them up by reusing the results of the previous test run.
This is useful if you modify the test itself, without changing the
implementation of task checks. Use the following command to run
integration tests in a fake mode:$ tox -e integration -- --fakeThe tests are also being executed onTravis
CI.
Since Travis CI runs on Ubuntu
and Ubuntu lacks the RPM Python bindings and mock,Dockeris used
to run the tests on Fedora. You can run the tests in Docker as well,
just use the commands from the.travis.ymlfile.LicenseThis code has been dedicated to the Public Domain, it is licensed withCC0 1.0 Universal Public Domain
Dedication,
full text of the license is available in the LICENSE file in this
repository.Please note that the RPM packages in this repository used for testing
have their own license terms and are not dedicated to the Public Domain.The sources of those packages can be found inKojiby searching the
package name and selecting the appropriate version.
Package: taskpackagelib
This is a simple example package. You can use
[Github-flavored Markdown](https://guides.github.com/features/mastering-markdown/)
to write your content.
Copyright (c) 2018 The Python Packaging AuthorityPermission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the “Software”), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Package: task-planner
TaskOverviewTaskis a task planning tool for the command line.Installationpython-mpipinstalltask-plannerCommand referenceusage: python -m task [] [order] [add] [priority] [do] [done]

View all tasks:
python -m task
python -m task order <task|priority|status>

Add a task:
python -m task add "<name>"
python -m task add "<name>" priority <priority>

Set the priority of an existing task:
python -m task priority <priority> for <task id>

Set a task to doing:
python -m task do <task id>

Delete a task:
python -m task done <task id>LicenseCopyright (c) 2019, Yannick Kirschen, All rights reserved.
Licensed under theMIT License.
Happy forking :)
Package: task-processing
Task ProcessingInterfaces and shared infrastructure for generic task processing (also known astaskproc) at Yelp.Developer SetupPre-requisitesDockerPython 3.8VirtualenvRunning exampleshello-world.pyis a very simple annotated example that launches a task to echohello world. From the root of the repository, run:docker-compose -f examples/cluster/docker-compose.yaml \
  run playground examples/hello-world.pyThis will bring up a single master, single agent Mesos cluster usingDocker Composeand launch a single task which will print "hello world" to the sandbox's stdout before terminating.Other examples available include:async.py
Example of theasynctask runner.dynamo_persistence.py
Example that shows how task events may be persisted toDynamoDBusing thestatefulplugin.file_persistence.py
Example that shows how task events may be persisted to disk using thestatefulplugin.promise.py
Example that shows how thepromise/futuretask runner (not yet implemented) may be used.subscription.py
Example of thesubscriptiontask runner.sync.py
Brief example using thesynctask runner.timeout.py
Example that shows how to timeout a task execution using thetimeoutplugin.retry.py
Example that shows how to retry a task on failure using theretryplugin.task_logging.py
Example that shows how to fetch task logs from Mesos agents using theloggingplugin.Running testsFrom the root of the repository, run:makeRepository Structure/interfacesEventRunnerTaskExecutor/pluginsPlugins can be chained to create a task execution pipeline with more than one property. Please refer to persistence/retry/timeout examples.mesosImplements all required interfaces to talk to Mesos deployment. This plugin usesPyMesosto communicate with Mesos.timeoutImplements an executor to timeout task execution.retryingImplements an executor to retry task execution upon failure.loggingImplements an executor to retrieve task logs from Mesos agents. Note that it has to be the immediate upstream executor of the mesos executor.Configuration optionsauthentication_principal Mesos principalcredential_secret_file path to file containing Mesos secretmesos_address host:port to connect to Mesos clusterevent_translator a fucntion that maps Mesos-specific events toEventobjectsstatefulTODO: documentation/runnersRunners provide specific concurrency semantics and are supposed to be
platform independent.SyncRunning a task is a blocking operation.syncrunners block until the running task has completed or astopevent is received.AsyncProvide callbacks for different events in tasks' lifecycle.asyncrunners allow tasks to specify one or more EventHandlers which consist of predicates and callbacks. Predicates are evaluated when an update is received from the task (e.g. that it has terminated and whether or not it has succeded) and if the predicate passes, the callback is called.Promise/FutureRunning a task returns future object.SubscriptionProvide a queue object and receive all events in there.
Package: task.py
task.pyRun your task asynchronously in the background and control/communicate with them.![Build Status](https://api.travis-ci.org/abhinavsingh/task.py.png)Installpip install task.pyUsageBasic use case oftask.pyis to run some unit of work asynchronously
(in a separate thread or process) while being able to control and
communicate with that unit of work. Example:Lets define asimple_taskthat:Expects some argumentsDoes some work (sleep) until signaled to stopreturn “done.” as final result` >>> def simple_task(t): # will receive a Task instance as first argument ...     assert t.args[0] == 'hello' ...     assertt.kwargs['world']== 'world' ...     while nott.stopped():...         time.sleep(0.1) ...     return 'done.' `Next, create aTaskinstance withsimple_taskas unit to work.
Additionally specify arguments expected by oursleep_task:` >>> t1 = Task(simple_task, 'hello',world='world')>>> >>> # start our task asynchronously >>> t1.start() >>> >>> # after 1 second signal our task to stop >>> time.sleep(1) >>> t1.stop() >>> >>> t1.done True >>> >>> t1.result 'done.' >>> >>> t1.exception == None True `Lets create a newTaskinstance, this time skipping the expected arguments:` >>> t2 = Task(simple_task) >>> >>> # start our task asynchronously >>> t2.start() >>> >>> t2.done True >>> >>> # No result found >>> t2.result == None True >>> >>> # our task raised an exception >>> t2.exceptionIndexError('tupleindex out ofrange',)`Communicating with TaskTaskprovide a communication queue over which external threads can send data
to the executing unit of work. Example:Lets define asleep_taskwhich will receive amount of time to sleep
over the communication queue:` >>> def sleep_task(t): ...     secs = t.recv() # recv API, default blocks until we have some data ...     time.sleep(int(secs)) ... >>> t3 = Task(sleep_task) >>> t3.start() >>> >>> # our task is waiting >>> t3.done False >>> >>> # send 1 sec sleep time >>> t3.send(1) >>> >>> # alright, done >>> t3.done True `Controllers[wait_until_done](https://github.com/abhinavsingh/task.py/blob/master/examples/wait_until_done_task.py)[redis_brpop](https://github.com/abhinavsingh/task.py/blob/master/examples/redis_brpop_task.py)[redis_pubsub](https://github.com/abhinavsingh/task.py/blob/master/examples/redis_pubsub_task.py)Task and Celery[celery_task](https://github.com/abhinavsingh/task.py/blob/master/examples/celery_task.py)
Package: taskq
Priority queue with task categorisation supportOverviewtaskqis a heap based priority queue that adds support to
partition tasks into categories for selective removal.The main driver for the project was work/task queueing where jobs
need to be distributed to workers with different capabilities and
non-uniform processing times (for calculating efficient prefetch).This library is not thread-safe and is not intended as a replacement
for python’squeue.Queueclass.Getting StartedInstall usingpip:pip install taskqBasic FIFO usage:>>> from taskq import Queue
>>> q = Queue()
>>> q.push('task1')
>>> q.push('task2')
>>> q.pop()
'task1'
>>> q.pop()
'task2'Task priorities (complex types that define __cmp__ are also supported):>>> from taskq import Queue
>>> q = Queue()
>>> q.push('task1', 2)
>>> q.push('task2', 1)
>>> q.pop()
'task2'
>>> q.pop()
'task1'Multi-pop:>>> from taskq import Queue
>>> q = Queue()
>>> q.push('task1')
>>> q.push('task2')
>>> q.push('task3')
>>> q.pop(2)
['task1', 'task2']Task categories:>>> from taskq import Queue
>>> q = Queue()
>>> q.push('task1', category='foo')
>>> q.push('task2', category='bar')
>>> q.push('task3', category='foo')
>>> q.pop(2, categories=['dog', 'foo'])
['task1', 'task2']Category ratios:>>> from taskq import Queue
>>> q = Queue()
>>> q.push('task1', category='foo')
>>> q.push('task2', category='bar')
>>> q.push('task3', category='foo')
>>> q.pop(2, categories=['bar', 'foo'], ratios=[1, 0.5])
['task1', 'task2', 'task3']The above example is useful when prefetching/distributing tasks that have
non-uniform processing durations.  If the category ratios represent
average duration in seconds, the count can be used to pull approximately
count seconds worth of the higest priority tasks from the queue.See source documentation for other feature examples.IssuesSource code fortaskqis hosted onGitHub. Any bug reports or feature
requests can be made using GitHub’sissues system.
Package: task-q
TaskQSimple CLI for multi user queue execution in Linux. TaskQ allows a single computer
to be used by different users concurrently. TaskQ allows each user to submit a
task to the same queue, which will be handled by the Task Handler Bot.1. Setup1.1. Installing ScreenThe Linux program Screen is a TaskQ's dependecy. In order to install it on Ubuntu,
run the commands:sudo apt-get update
sudo apt-get install screen1.2. Installing TaskQTaskQ needs to be installed in order to set its dependecies correctly.
In order to do that, it needs a folder to be the TaskQ home, where the app
will save its local files, and also an UID to define
the owner of TaskQ's queue. It is important to note that the TaskQ Bot
will run with the privileges of user that executed the installation step below.pip install task-q
sudo taskq install $HOME $(id -u $USER)1.3. Starting Task HandlerThe Task Handler is the bot that will execute the tasks in the TaskQ queue.
It is necessary to start it manually. It is important to note that only the
TaskQ queue owner has the priviliges to start or to stop the Task Handler.taskq startIn order to stop the queue, do:taskq stop2. Using the TaskQ2.1. Show the queueTo show the queue waiting list, run the command below:taskq show-queueIt is possible to filter the table with the options below:all: shows all the tasks in the queue, including the completed and failed ones.running: shows only the tasks that are running at the momentmine: shows only the tasks that belong to the userdone: shows only the tasks that are complete2.2. Add a task to the queueA task for TaskQ is basically a bash command that will be executed within the
queue owner context. To add a task to the queue, do:taskq add '<command string>'2.3. Abort a taskAborting a task will remove it out of the waiting list:taskq abort <task id>2.4. Reset a taskReseting a task will put it back into the waiting list:taskq reset <task id>For more information, excecutetaskq --help.
Package: taskquant
TaskQuantThis is a CLI application that helps Taskwarrior users quantify their productivity by tracking the 'score' attribute in their tasks.scoreis a customUser Defined Attributes. You will need to have that configured in your.taskrcfile. A sample configuration for this attribute would be:uda.score.type=numeric
uda.score.label=Score 🏆 
urgency.uda.score.coefficient=2TaskQuant will then compute the score(s) you have accumulated across the different tasks and return a scoresheet.TaskQuanthas no external dependenciesexcepttasklib, which is also bythe same organizationthat developed Taskwarrior.It is written entirely in Python, using standard library. It may have optional dependencies, but those are not required and a fallback option will always be used by default.For those reasons, TaskQuant is extremely lightweight. As it stands, it's only 6.8kb of code, and should install in under a second.InstallationTaskQuant is available onpypi.pip install taskquantUsageInstall the package and execute:tqIt supports an optional-p(path) argument to specify the path to your.taskfile.Especiallyhelpful if you changed the default location of your.taskfile.It supports an optional-v(verbose) argument to print out additional
information in its output.tq-p~/vaults/tasks-v# outputs:+------------+-------+------------+|Date|Score|Cumulative|+------------+-------+------------+|2022-03-09|0|0||2022-03-10|8|8||2022-03-11|1|9||2022-03-12|43|52||2022-03-13|4|56||2022-03-14|4|60||2022-03-15|7|67||2022-03-16|9|76||2022-03-17|4|80||2022-03-18|4|84||2022-03-19|3|87||2022-03-20|2|89||2022-03-21|5|94|+------------+-------+------------+
Totalcompletedtasks:48Activedates:13task_path:/home/samuel/vaults/tasksYou can also print a weekly (-w) version of the scoresheet:tq-w+-------+-------+------------+|Week#|Score|Cumulative|+-------+-------+------------+|10|56|56||11|33|89||12|26|115||13|12|127|+-------+-------+------------+The first column refers to the ISO week number of the year.To see all optional arguments, use the-h(help) argument.tq-hDependenciestasklib(Optional)tabulateTestingTests are written inunittestand stored in thetestsdirectory.To execute tests without arguments and automatic test discovery:python-munittestTo test a specific test file (-vfor verbose output):python-munittest-vtests/test_accum.py

test_create_combined_table(tests.test_accum.TestAccum)...ok
test_create_full_date...ok
test_create_table_auto(tests.test_accum.TestAccum)...ok
test_extract_tasks(tests.test_accum.TestAccum)...ok
test_fill_rolling_date(tests.test_accum.TestAccum)...ok
test_invalid_path_warning(tests.test_accum.TestAccum)...ok
test_task_to_dict(tests.test_accum.TestAccum)...ok

----------------------------------------------------------------------
Ran7testsin0.049s

OKRoadmapAdd terminal-based charts and graphsNew ways to visualize scores based on tags, projects or other attributesLinks to Tutorialsto be updated
Package: task-queue-checker
task-queue-checkerTool designed to simplify the management and monitoring of task queues in Python environmentsInstallingpip install task-queue-checkerTutorialimporttimeimportrandomfromtask_queue_checker.storageimportPersistQueueSQLitefromtask_queue_checker.typesimportTaskfromtask_queue_checkerimportTaskQueueCheckerstorage=PersistQueueSQLite()# add tasks to queuestorage.add([1,2,3,"Hola Mundo"])storage.add({"name":"Raùl","last_name":"Cobiellas"})storage.add("Task # 3")storage.add("Task # 4")defconsumer(task:Task):print(task.data)# task contentnumber=random.randint(1,3)ifnumber==1:print(f"task{task.id}done")task.done()elifnumber==2:print(f"task{task.id}canceled")task.cancel()elifnumber==3:print(f"task{task.id}put last")task.put_last()monitor=TaskQueueChecker(consumer=consumer,task_storage=storage)# run monitor in backgroundmonitor.start()# this code simulates the execution of your main programwhileTrue:try:time.sleep(10)exceptKeyboardInterrupt:break
Package: task-runner
taskrunner runs your methods until they stop failing.Motivationtaskrunner is a crude way to force your methods to complete. This is
particularly useful when functions can be expected to throw exceptions
but shouldn’t stop execution. Effectively, taskrunner catches all
exceptions and makes sure that the result is not in a list of excluded
return values.Installationtaskrunner is available via pip:$ pip install taskrunnerUsagefromtaskrunnerimportTaskRunnerdefsome_function_that_may_throw(some_argument,another_argument):# Do somethingtask_runner=TaskRunner()result=task_runner.run_until_complete(target=some_function_that_may_throw,args=('123','456'))print(result)# Hopefully something useful