Saravanan666/pypi-org huggingface dataset:
Package: simplequi
simplequiv1.0.7Run codeskulptor.org programs on the desktop using Qt/PySide2To run an existing codeskulptor script on your local machine, simply import simplequi as simplegui:import simplequi as simplegui

# The rest of your script goes here unchangedNothing else should need changing!FeaturesRuns codeskulptor.org Python3 scripts using a Qt applicationThe API matches simplegui exactly, so you should be able to run your script exactly as on codeskulptor.org after importing simplequiInstallationGet simplequi from pip:pip install simplequiOr checkout the source code fromhttps://github.com/ArthurGW/simplequi, then run:pip install -r requirements.txtExamplesIncluded in simplequi/examples are various scripts to show simple usages.After installing simplequi, these can be run for example like this:python -m simplequi.examples.codeskulptor_defaultKnown IssuesOnly supports the simplegui part of the codeskulptor API.Does not support simplemap, simpleplot or other support  functions.Support for simplemap and simpleplot is planned in future.Execution happens by the simplequi Qt application running when the Python interpreter is ready to shutdownThis can cause problems with some debuggers, but is fine for normal use.Please report any issues you find with this!For now, only supports PySide2/qt-for-pythonSupport for PyQt will hopefully be added in future.ContributeIssue Tracker:https://github.com/ArthurGW/simplequi/issuesSource Code:https://github.com/ArthurGW/simplequiSupportIf you are having issues, please let us know.
The maintainers can be contacted atsimplequi.codeskulptor@gmail.comLicenseThe project is licensed under the GPLv3 license.OpenSSLThe distribution includes a couple of OpenSSL DLLs, which are necessary for getting images and sounds from HTTPS urls.  This
encryption may not be allowed in your country, please check local laws.  These DLLs may only work on Windows, so you
may have to install OpenSSL yourself on other systems.This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/).See simplequi/resources/ssllib/LICENSE.txt for the full OpenSSL licence details.
Package: simplerabbit
Atom Rabbit LibRabbit Lib is a Python library for sending and receiving messages using RabbitMQ. It includes two classes, RabbitSender and RabbitReceiver, that provide a simple interface for sending and receiving messages over a RabbitMQ broker.InstallationYou can install Rabbit Lib using pip:pipinstallrabbit_libRabbit Lib requires Python 3.6 or later, as well as the pika library (version 1.2.0)UsageHere's an example of how to use RabbitSender to send a message:fromrabbit_libimportRabbitSendersender=RabbitSender('amqp://guest:guest@localhost:5672/','my_queue')sender.send_message('Hello, world!')And here's an example of how to use RabbitReceiver to receive messages:fromrabbit_libimportRabbitReceiverreceiver=RabbitReceiver('amqp://guest:guest@localhost:5672/','my_queue')message=receiver.receive_message()print(message)LicenseRabbit Lib is licensed under the MIT License. See LICENSE for more information.ContributingContributions are welcome! Please open an issue or submit a pull request.
Package: simple-range
Weka-inspired index and range using human-readable 1-based indices and placeholders, e.g.: first-last, 1-10,12,20-lastChangelog0.0.3 (2023-10-19)addedPLACEHOLDERSlistadded class methodhelptoIndexandRangeclass for returning a short help string0.0.2 (2023-02-21)added “simple_range.Index” class for a single indexadded convenience methods “range_indices” and “index_value”0.0.1 (2023-02-21)initial release with “simple_range.Range” class
Package: simple-ratelimiter
Rate limiterCopyright (c) 2024 Tuyen PhanA simple python implementation of a general purpose rate limiter.Example:fromrate_limitimportRateLimiter,Bucket,PeriodasPer# Initialize.rate_of=Bucket.builder()limiter=RateLimiter(per_second=rate_of(3,Per.SECOND),per_minute=rate_of(10,Per.MINUTE))# Use limiter.iflimiter.reduce():print"There is still quota left, so we can send your request."else:print"Quota exhausted for",list(limiter.exhausted())# Display status.printlimiter.status()# Get remaining tokens for bucket.iflimiter.get("per_minute")<3:print"You are awfully close to exhausting your minute limits."There is also a cleaner way to utilize the rate limiter, by simply wrapping
the implementation:classClient(object):def__init__(self,limiter):self.send=limiter.wrap(self._send_impl)def_send_impl(self,req):print"Sending request (%s)"%json.dumps(req)# This is now a rate-limited call which throws when exceeding the limit.client.send("foo")
Package: simpler-devops-api
IntroductionA Simpler Way of Interacting with Azure Devops through PythonGetting StartedThis is a work in progress so functions are implemented as they are needed.Initially support is providede for getting information on projects, repositories, branches and for getting and setting branch policies.Authentication information is provided via two methods -##1 - via environment variablesDEVOPS_PAT : PAT for azure devops organisation that has the appropriate permissions for the org you are looking to talk to
DEVOPS_URL : The organisation URL for the organisation that you are looking to talk to.##2 - via configuration file.If the environment variables are not set then the package will look for.devops.iniin your home directory, ordevops.iniin the default user data directory (see appdirs for where this is likely to be on your OS)Config file formatExample config file[DEFAULT]
DEVOPS_PAT = your_long_pat_token
DEVOPS_URL = https://dev.azure.com/organisationFull method documentation available here:https://simplerdevopsapi.z6.web.core.windows.netPull Requests welcome.
Package: simplere
A simplified interface to Python’s regular expression (re) string
search. Eliminates steps and provides simpler access to results. As a bonus,
also provides compatible way to access Unix glob searches.UsagePython regular expressions are powerful, but the language’s lack
of anen passant(in passing) assignment requires a preparatory
motion and then a test:import re

match = re.search(pattern, some_string)
if match:
    print match.group(1)Withsimplere, you can do it in fewer steps:from simplere import *

if match / re.search(pattern, some_string):
    print match[1]That’s particularly valuable in complex search-and-manipulate
code that requires multiple levels of searching along with
pre-conditions, error checking, and post-match cleanup, formatting,
and actions.As a bonus,simplerealso provides simple glob access.:if 'globtastic' in Glob('glob*'):
    print "Yes! It is!"
else:
    raise ValueError('OH YES IT IS!')It can also conveniently match against multiple glob
patterns, and/or do case-insensitive glob searches.SeeRead the Docsfor the full installation and usage documentation.
Package: simplereader
simplereaderReads data and manipulates data from CSV easily, also includes statistics functionsFree software: MIT licenseDocumentation:https://simplereader.readthedocs.io.FeaturesTODOCreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.0.4 (2022-04-25)First release on PyPI.
Package: simple-redis-helper
Little command-line library to send/receive data to/from a Redis backend.https://github.com/fracpete/redis_helperChangelog0.1.6 (2024-02-27)usingsrh-prefix in the argparser’sprogparameter nowaddedsrh-pingcommand to check server availability0.1.5 (2023-07-10)fixed password support when accessing environment variable0.1.4 (2023-07-07)fixed password support0.1.3 (2023-07-07)added support for supplying a password for connecting to the Redis server (–passwordor–password_env)0.1.2 (2021-10-01)listen.pynow supports output in a directory0.1.1 (2021-09-22)broadcast.pynow supports reading binary files and just using simple strings0.1.0 (2021-09-14)initial release
Package: simple-redis-lock
Installationpipinstallsimple-redis-lockUsagefromsimple_redis_lockimportget_simple_lockimportyour_redis_clientwithget_imple_lock(your_redis_client,'my_lock_name',ex=30)aslock:iflock:print('get the lock, and do something, finish release the lock')else:print('do not get lock, return')
Package: simpleregex
Simple RegExBrought with❤️byIntroductionReadability counts. Even in regex.Documentation|About|Installation|ContributingAboutThis tool is a wrapper for RegEx in python (import re), which introduces pattern
functions in place of unreadable text patterns.This tool is inspired by theMagic Regextool.In UseUsage example can be found
inunit tests.Installationpip install simpleregexReleaseTo bump a package version go tosetup.pyand
changeversionvariable.Create new release on GitHub and tag it with the same version as insetup.py.The release process totestpypiandpypiis manually triggered on CircleCi.
After successful merge to main and creation of new release tag, go toCircleCiand trigger new pipeline with
following boolean parameters:pypi_publish: true- this will push package topypitestpypi_publish: true- this will push package totestpypiSupportSupported python versions:3.113.103.93.8
Package: simpleregistry
simpleregistrySimple registries in Python.Right now supports only object registries, but class registries are coming in the future releases:importdataclassesimportsimpleregistrybook_registry=simpleregistry.Registry('books')@book_registry@dataclasses.dataclassclassBook:isbn:inttitle:strauthor:strdef__hash__(self)->int:returnhash(self.isbn)lord_of_the_rings=Book(123,'The Lord of the Rings','J. R. R. Tolkien')assertlord_of_the_ringsinbook_registryassertlen(book_registry)==1assertbook_registry.all()=={lord_of_the_rings}assertbook_registry.get(isbn=123)==lord_of_the_ringsassertbook_registry.filter(author='J. R. R. Tolkien')=={lord_of_the_rings}Works with custom types, standard-library dataclasses and Pydantic. See tests for examples.This project is currently in Alpha status. You are welcome to use it. Code should be stable, but the API may change.Registries and Type ConstraintsBy default, registries allow for limited polymorphism. This means that if you register one type with a registry,
any instances of its subclasses will also be registered:importsimpleregistrypublication_registry=simpleregistry.Registry('publications')@publication_registryclassBook:passclassMagazine(Book):passbook=Book()magazine=Magazine()assertbookinpublication_registryassertmagazineinpublication_registryIf this is not desired, you can use theallow_subclassesargument to theRegistryconstructor:importsimpleregistrypublication_registry=simpleregistry.Registry('publications',allow_subclasses=False)@publication_registryclassBook:passclassMagazine(Book):passbook=Book()magazine=Magazine()assertbookinpublication_registryassertmagazinenotinpublication_registryIf you want to be able to register multiple related or unrelated types,
you can use theallow_polymorphismargument to theRegistryconstructor:importsimpleregistrypublication_registry=simpleregistry.Registry('publications',allow_polymorphism=True)@publication_registryclassBook:pass@publication_registryclassMagazine:passbook=Book()magazine=Magazine()assertbookinpublication_registryassertmagazineinpublication_registryIf you want to further relax the type constraints, you can use thecheck_typeargument. This will allow you to force
any types of objects into the registry:importsimpleregistrypublication_registry=simpleregistry.Registry('publications',check_type=False)@publication_registryclassBook:passclassMagazine:pass# Book will be registered automaticallybook=Book()assertbookinpublication_registry# Magazine will not be registered automaticallymagazine=Magazine()assertmagazinenotinpublication_registry# You can, however, register it manuallypublication_registry.register(magazine)assertmagazineinpublication_registry
Package: simple-repository-browser
simple-repository-browserA web interface to browse and search packages inanysimple package repository (PEP-503), inspired by PyPI / warehouse.Built using FastAPI and thesimple-repositorycore library.UsageInstall from PyPI:python-mpipinstallsimple-repository-browserAnd run:simple-repository-browser(or alternativelypython -m simple_repository_browser)By default, this will use the repository at PyPI (https://pypi.org/simple/). You can point it to a custom
repository by passing the URL to the project list endpoint (the base URL according to PEP-503):simple-repository-browserhttps://my-custom-repository.example.com/foo/simple/Screenshots:Homepage:Search:Project page:Runtime detailssimple-repository-browserexposes a FastAPI application, and it runs the application in a singleuvicornworker.
Metadata that is computed will be cached in the$XDG_CACHE_DIR/simple-repository-browserdirectory. This cache is not
intended to be shared among different repository URLs, and is unlikely to work for multiplesimple-repository-browserversions. There is currently no intelligent cache invalidation for those cases.DevelopmentIn order to build thesimple-repository-browser, first:cdjavascript
npminstall--include=dev
npmrunbuildcd..And then the normal installation procedure applies:python-mpipinstall-e.The browser can be run with:python-msimple_repository_browserLicense and SupportThis code has been released under the MIT license.
It is an initial prototype which is developed in-house, andnotcurrently openly developed.It is hoped that the release of this prototype will trigger interest from other parties that have similar needs.
With sufficient collaborative interest there is the potential for the project to be openly
developed, and to power Python package repositories across many domains.Please get in touch athttps://github.com/orgs/simple-repository/discussionsto share how
this project may be useful to you. This will help us to gauge the level of interest and
provide valuable insight when deciding whether to commit future resources to the project.
Package: simple-repository-server
simple-repository-serverA tool for running a PEP-503 simple Python package repository, including features such as dist metadata (PEP-658) and JSON API (PEP-691)Installationpython-mpipinstallsimple-repository-serverUsageThesimple-repository-serveris designed to be used as a library, but also includes a convenient command line interface for running
a simple repository service:$simple-repository-server--help
usage:simple-repository-server[-h][--portPORT]repository-url[repository-url...]RunaSimpleRepositoryServer

positionalarguments:repository-url

options:-h,--helpshowthishelpmessageandexit--portPORTIf multiple repositories are provided, thePrioritySelectedProjectsRepositorycomponent will be used to
combine them together in a way that mitigates thedependency confusion attack.The server handles PEP-691 content negotiation to serve either HTML or JSON formats.
Per PEP-691, the default (fallback) content type is HTML, but a JSON response can
be previewed in the browser by adding the?format=application/vnd.pypi.simple.v1+jsonquerystring to any of the repository URLs.The server has been configured to include PEP-658 metadata, even if the upstream repository does
not include such metadata. This is done on the fly, and as a result the distribution will be
temporarily downloaded to the server in order to extract and serve the metadata.It is possible to use the resulting repository as input for thesimple-repository-browser, which
offers a web interface to browse and search packages in any simple package repository (PEP-503),
inspired by PyPI / warehouse.It is expected that as new features appear in the underlyingsimple-repositorylibrary, those
which make general sense to enable by default will be introduced into the CLI without providing a
mechanism to disable those features. For more control, please see the "Non CLI usage" section.Non CLI usageThis project provides a number of tools in order to build a repository service using FastAPI.
For cases when control of the repository configuration is required, and where details of the
ASGI environment need more precise control, it is expected thatsimple-repository-serveris used
as a library instead of a CLI.Currently the API for this functionality is under development, and will certainly change in the
future.License and SupportThis code has been released under the MIT license.
It is an initial prototype which is developed in-house, andnotcurrently openly developed.It is hoped that the release of this prototype will trigger interest from other parties that have similar needs.
With sufficient collaborative interest there is the potential for the project to be openly
developed, and to power Python package repositories across many domains.Please get in touch athttps://github.com/orgs/simple-repository/discussionsto share how
this project may be useful to you. This will help us to gauge the level of interest and
provide valuable insight when deciding whether to commit future resources to the project.
Package: simple-repr
Create string representations of classesThis module contains a class used to generate__repr__methods for your classes. This can be done either by inheriting from theSimpleReprclass, or by creating a__repr__function, and returingSimpleRepr.make_repr(self)Using the SimpleRepr classInheritanceThe easiest way to use this class is to inherit from it, as this saves you from defining a__repr__method altogether.fromsimple_reprimportSimpleReprclassUser(SimpleRepr):def__init__(self,name:str,age:int):self.name=nameself.age=ageuser=User('John',25)print(user)>>>"User(args[name='John', age=25])"Inheriting fromSimpleReprallows for the inclusion ofclassconstants.fromsimple_reprimportSimpleReprclassUser(SimpleRepr):COMPANY="Some Company"def__init__(self,name:str,age:int):self.name=nameself.age=ageuser=User('John',25)print(user)>>>"User(consts=[COMPANY='Some Company'], args[name='John', age=25])"Defining a functionIn case you don't want to inherit from theSimpleReprclass, or are already inheriting from another class, you can create a__repr__function and return the staticmethodmake_reprfrom the module.fromsimple_reprimportSimpleReprclassUser:def__init__(self,name:str,age:int):self.name=nameself.age=agedef__repr__(self)->str:returnSimpleRepr().make_repr(self)user=User('John',25)print(user)>>>"User(args=[name='John', age=25])"The downside to defining your own function is thatclassconstants are no longer accessible, and therefore will not be included in therepr.fromsimple_reprimportSimpleReprclassUser:COMPANY="Some Company"def__init__(self,name:str,age:int):self.name=nameself.age=agedef__repr__(self)->str:returnSimpleRepr().make_repr(self)user=User('John',25)print(user)>>>"User(args[name='John', age=25])"Creating an environmentCreate a virtual development environment by using thevirtualenvPython library. You can install this by executingpip install virtualenv.To create your environment, typevirtualenv venv --prompt "(your-env) ". Once created, you can activate it by usingsource venv/bin/activate. Once you are done developing, simply typedeactivatein your terminal.InstallationUsing the libraryInstall this library by runningpip install simple-repr.Import the library by addingfrom simple_repr import SimpleReprto your code.Developing for this libraryInstall the Python libraries required by runningpip install -r dev-requirements.txt.Before making any commits, ensure that allnoxsessions are passing.Please ensure to create your environment before you execute any of the installation commands
Package: simple-request-framework
SimpleRequestsFrameworkDescriptionThis is a simple will be used to request requests wrapped up response package is json at the same time the content will be stored locally api package . Support for GET and POST requests , while supporting multiple proxy protocols , you can preset the Header and other related information .Installationpipinstallsimple-requests-frameworkUsagefromSimpleRequestFrameworkimportSimpleRequestFrameworkcustom_headers={"User-Agent":"CustomUserAgent/1.0","Authorization":"Bearer YOUR_TOKEN"}# new a framework instance, and set the save directory, use proxy, proxy type, proxy address, and custom headersframework=SimpleRequestFramework(save_directory="output_files",use_proxy=True,proxy_type="http",proxy_address="http://127.0.0.1:8080",headers=custom_headers)# GET request exampleget_url="https://api.ip.sb/ip"params={"param1":"value1","param2":"value2"}framework.fetch_and_save(get_url,"output_get.json",method="GET",params=params)# POST request examplepost_url="https://httpbin.org/post"data={"data1":"value1","data2":"value2"}framework.fetch_and_save(post_url,"output_post.json",method="POST",data=data)Also supports configuration of framework instances as json filescreate a json file named config.json{"save_directory":"output_files","use_proxy":true,"proxy_type":"http","proxy_address":"http://127.0.0.1:8080","headers":{"User-Agent":"CustomUserAgent/1.0","Authorization":"Bearer YOUR_TOKEN"}}fromSimpleRequestFrameworkimportSimpleRequestFrameworkframework=SimpleRequestFramework(config_json="config.json")
Package: simple-requests
Simple-requests allows you to get the performance benefit of asynchronous
requests, without needing to use any asynchronous coding paradigms.Usagefromsimple_requestsimportRequests# Creates a session and thread poolrequests=Requests()# Sends one simple request; the response is returned synchronously.login_response=requests.one('http://cat-videos.net/login?user=fanatic&password=c4tl0v3r')# Cookies are maintained in this instance of Requests, so subsequent requests# will still be logged-in.profile_urls=['http://cat-videos.net/profile/mookie','http://cat-videos.net/profile/kenneth','http://cat-videos.net/profile/itchy']# Asynchronously send all the requests for profile pagesforprofile_responseinrequests.swarm(profile_urls):# Asynchronously send requests for each link found on the profile pages# These requests take precedence over those in the outer loop to minimize overall waiting# Order doesn't matter this time either, so turn that off for a performance gainforfriends_responseinrequests.swarm(profile_response.links,maintainOrder=False):# Do something intelligent with the responses, like using# regex to parse the HTML (see http://stackoverflow.com/a/1732454)friends_response.htmlRelease History1.1.1 (June 27, 2014)API ChangesbundleParamparameter added toRequests.one,Requests.swarm,Requests.each1.1.0 (May 01, 2014)API ChangesdefaultTimeoutparameter added toRequests.__init__Bug FixesNo more errors / warnings on exitFixes due to API changes in gevent 1.0Fixed a couple documentation errorsFeaturesAdded a patch class, with monkey patches of urllib3 (to reduce the likelihood of too many
open connections/files at once) and httplib (to disregard servers that incorrectly report the content-length)
Package: simpleresource
Simple Resource Limite Decorators For Python RuntimeDecorators:@set_runtime(seconds=0)RuntimeError, max runtime of the function in decorators@set_cpu_runtime(seconds=0)RuntimeError, max soft cpu runtime of the function in decorators@set_max_memory(size=0)max memory of the function in decorators@set_max_cpu(nproc=65535)max memory of the function in decoratorsset_max_cpu0(nproc=65535)max ncpu of the function in main process, can not be used for decoratorsUsage:@set_runtime(seconds=5)deftest():time.sleep(10)test()## RuntimeErrorInstallpip install simpleresource

or:

pip install git+https://github.com/yodeng/simpleresource.git