Saravanan666/pypi-org huggingface dataset:
Package: majime
/ma-ji-me/nounan earnest, reliable person who can get things donedead simple API Unit TestingWhat does it do?majime runs test cases on API endpointstest cases are defined in YAML filesmajime can generate test cases from Swagger specsInstallpip install majimein a Python3 environmentOr get the binaries forMacOS|Linux| WindowsPackage on PypiUsageUsage:

 -f Load and run tests from YAML file
    Example: majime -f test.yaml
 -g Generate test suite (YAML) from Swagger document
    Example: majime -g http://api.example.com/swagger.json

Switches:

 -j JSON output
 -d Dry-Run, do not execute tests - good for testing your YAML fileExampleGenerate Test Cases from Swaggermajime -g http://backend.yoisho.dob.jp/fx/swaggerTitle: Yoisho Currency Exchange
Host: backend.yoisho.dob.jp
Base Path: /fx
Scheme: http
Path: /currency
	Method: GET
	Description: Get the FX rate for desired currency
	Query Parameters: ['currency']
	Expected Response: 200Generated Output FileBase: "http://backend.yoisho.dob.jp/fx"
Tests:
 # GET - Get the FX rate for desired currency
 - path: "/currency?currency=USD"
   method: "GET"
   headers: ""
   expect-response: "200"
   expect-body: "json"Run Test CasesModify the parameters so they make sense, in this case XXX-> USD.majime -f Yoisho_Currency_Exchange-*.yamlGET http://backend.yoisho.dob.jp/fx/currency?currency=USD
HTTP 200Check out theexamples.
Package: majka
Native cPython binding to a C++ implementation of morphological analyser named Majka.Tags returned from the analyser are also transcribed into a native Python dictionary
to enable a much more Python-like experience without a need to study the documentation.Based on code of Pavel Smerk and Pavel Rychly, NLP group at MUNI, Czech Republic.Morphological automatons are distributed separately under different licences.
Seehttp://nlp.fi.muni.cz/ma/
Package: majocol
Pick major colors from imageDocumentation:Demo:MajoColRequirementsPython 3.6+Installation$pip3installmajocolExamplefrommajocolimportcolor,convert# Using Pillow (Open local image)fromPILimportImageimage=Image.open(<IMAGE_PATH>)image_ndarr=convert.pillow_to_rgb_ndarr(image)colors=color.pick(image_ndarr,3)# Using opencv-python (Open local image)importcv2image=cv2.imread(<IMAGE_PATH>)image_ndarr=cv2.cvtColor(image,cv2.COLOR_BGR2RGB)colors=color.pick(image_ndarr,3)# Using requests (Fetch web image)importrequestsresp=requests.get(<IMAGE_URL>)image_ndarr=convert.byte_to_rgb_ndarr(resp.content)colors=color.pick(image_ndarr,3)— 🪄 —MajoCol is licensed under the terms of theMIT license.
Package: majorapi-python-sdk
See the [MajorApi: QuickBooks REST API](https://majorapi.com/developers/quickbooks) for more information on how to use the MajorApi: QuickBooks REST API.## Installation`bash pip installmajorapi-python-sdk`## Quick GuideSetup`python from majorapi import MajorApiQuickbooks api =MajorApiQuickbooks('username','apikey') `Customers`python api.create_customer(customer) api.retrieve_customer(customer_name) `Orders`python api.create_invoice(order) api.create_sales_order(order) api.retrieve_invoice(ref_number) api.retrieve_sales_order(ref_number) `Items`python api.retrieve_item(item_name) `
Package: majordome
General utilities for scientific Python.ImportantThis package is its early stages of development and any interface might change
to keep compatibility with future versions. Please wait until it has reached a
minimum level of maturity to use it in your projects. Any contributions are
welcome.InstallationThis package is available onPyPi,
and the recommended way to install it is withpip install majordome.UsageSamples are provided for every available functionality undersamples/.Documentation coming soon atreadthedocs.io!
Package: majorityjudgement
This is an implementation of the Majority Judgement voting procedure, as
proposed by Michel Balinski and Rida Laraki inA theory of measuring, electing
, and rankingIt takes tallies of grades provided by voters and provides a python type to
wrap them which is ordered according to the majority judgement order.For example:x = MajorityJudgement([5, 5])
y = MajorityJudgement([3, 7])
assert x < yThe first is the grade for a candidate who has received 5 votes of 0 and 5 votes
of 1. The second is a candidate with 3 votes of 0 and 7 of 1. As a result the
majority judgement procedure ranks the first candidate as being worse than the
second candidate.In the event that you want more information about the details of the voting,
the MajorityJudgement objects behave like the corresponding lists of grades
assigned to them.So for example:assert list(MajorityJudgement([2,2])) == [0,1,0,1]The MajorityJudgement object can generally be used exactly like its
corresponding list of grades. In particular it supports all the container
methods in an efficient manner.Internally the implementation is rather different. It is encoded as a list of
repeating cycles. So the list[0, 0, 0, 1, 0, 1, 0, 1]is internally represented as[[[0], 3], [[1], 1], [[0, 1], 2]]The representation we choose only ever builds cycles of length one or two: A
cycle of length one is usually built when there is an unambiguous median, while
a cycle of length 2 will usually be built when the lower and upper medians are
different (this isn’t entirely true. e.g. the list of votes [1,1,1,1] will not
produce any cycles of length 2, but it’s a good rule of thumb)Rather than building the whole list and then compressing, entire cycles are
built at once by working how large a run can be popped from the remaining votes
and popping it all at once. This means that even very large populations of
voters may be efficiently worked with as the resulting lists are actually very
small.The comparisons too may be performed efficiently on this compressed
representation: Equality works straightforwardly in the sense that two equal
votes will produce two equal representations. Comparisons may be performed by
popping common prefixes first: So if two lists both start with [x, n] and [x,m]
then we may throw away min(m,n) entries immediately rather than having to
iterate through.It appears to be the case that all votes can be represented as a compressed
list of this form with very few cycles. I conjecture that it can be done in
O(log(voters)), but have not verified this. Certainly in practice it seems to
be the case.
Package: majorityvoteproba
majorityvoteprobaTable of ContentsInstallationUsageCommandsSupportContributingInstallationThemajorityvoteprobagit repois available asPyPi packagepip install majorityvoteprobaUsageCheck theexamplesfolder for notebooks.CommandsCheck syntax:flake8 --ignore=F401Run Unit Tests:python -W ignore -m unittest discoverRemove.pycfiles:find . -type f -name "*.pyc" | xargs rmRemove__pycache__folders:find . -type d -name "__pycache__" | xargs rm -rfUpload to PyPi:python setup.py sdist upload -r pypiUpload to PyPi with twine:python setup.py sdist && twine upload -r pypi dist/*DebuggingNotebooks to profile python code are in theprofilefolderSupportPleaseopen an issuefor support.ContributingPlease contribute usingGithub Flow. Create a branch, add commits, andopen a pull request.
Package: majorly-funny
majorly_funnysetupThings to add to .gitignore# Compiled python modules.
*.pyc

# Setuptools distribution folder.
/dist/

# Python egg metadata, regenerated from source files by setuptools.
/*.egg-infosetup env variablesTWINE_USERNAME
TWINE_PASSWORDdevelopment modepython setup.py developorpip install -e .update published packageafter making changes to the project (write new code, add resource files, etc...)remove old packagesrm dist/*bump the version in setup.pybuild new packagepython3 setup.py sdistcheck new packagetwine checktest publish new packagetwine upload --repository-url https://test.pypi.org/legacy/ dist/* --verbosepublish real packagetwine upload --repository-url https://upload.pypi.org/legacy/ dist/* --verbose
Package: majortom-gateway
Major Tom Gateway API PackagePython Package for interacting with Major Tom's Gateway API.The Gateway API functions are accessible under theGatewayAPIclass:frommajortom_gatewayimportGatewayAPIUse thehelp()function to see it's capability,
and check out ourdemo gatewayas an example of how to use it!Theconnectorconnect_with_retriesfunctions must be called before any messages can be passed.DevelopmentThe Gateway API Package is currently in Beta,
so pleasesubmit an issueorcome talk to usif you have any comments/questions/feedback.TestingTo run all tests, execute./dockertest.shor push a branch and let the CI system do it.
Package: majortom-scripting
Major Tom Script API PackagePython Package for interacting with Major Tom's Scripting API.The Package contains both ahigh-levelandlow-levelAPI.High-Level APIThis API is in alpha. Please use with caution.The new high-level API aims to make the user experience easier by providing canned methods and models for common operations. We trade both customizability and efficiency for ease-of-use. For example, to schedule a command on an upcoming pass, it is only a few lines of code:# Customize these to your missiontoken="your script token"host="your_instance.majortom.cloud"satellite_name="your already-created satellite"command_name="your already-created command"#-------------------------------------------------api=ModelingAPI(host=host,token=token)# Create the APIAQUA=api.satellite(name=satellite_name)# Get the satelliteaPass=AQUA.next_pass()# Get the next passdefinition=AQUA.get_command_definition(command_name)# Get a specific commandaPass.schedule_command(definition)# Schedule it on a passMore examples are available on in ourdemo repo.Low-Level APIThe low-level API provides direct access to the GraphQL query and mutation methods. Users will have to construct a GraphQL query and provide the correct variables in order to use the API. Although it requires more upfront work, the low-level API is the most efficient and customizable way to interact with Major Tom.Here is an example of retrieving all TLEs from all satellites whose name includes the string "v2" from within a particular mission.# Customize these to your missiontoken="your script token"host="your_instance.majortom.cloud"mission_id=1#-------------------------------------------------api=ScriptingAPI(host=host,token=token)graphql="""query GetSystems ($missionId: ID!,$systemFilters: SystemFilter,) {mission(id: $missionId) {idsystems(filters: $systemFilters, orderBy: { sort: NAME, direction: ASC }) {edges {node {idtle}}}}}"""response=api.query(graphql,variables={'missionId':mission_id,'systemFilters':{"type":"Satellite","nameSubstring":"v2"}},path='data.mission.systems.edges')print(response)The GraphQL schema and documentation can be found inside Major Tom on the same page where a Script Token is available. Look for the button labelled "GraphQL Playground".ExamplesExample scripts can be found in ourdemo repo.DevelopmentThe Scripting API Package is currently in Beta, so pleasegive us feedbackorcome talk to us!TestingTo run all tests, execute./bin/docker_testw.sh.
Package: makana-model
makana_modelMakana Model.RequirementsJupyterLab >= 3.0InstallTo install the extension, execute:pipinstallmakana_modelUninstallTo remove the extension, execute:pipuninstallmakana_modelContributingDevelopment installNote: You will need NodeJS to build the extension package.Thejlpmcommand is JupyterLab's pinned version ofyarnthat is installed with JupyterLab. You may useyarnornpmin lieu ofjlpmbelow.# Clone the repo to your local environment# Change directory to the makana_model directory# Install package in development modepipinstall-e.# Link your development version of the extension with JupyterLabjupyterlabextensiondevelop.--overwrite# Rebuild extension Typescript source after making changesjlpmbuildYou can watch the source directory and run JupyterLab at the same time in different terminals to watch for changes in the extension's source and automatically rebuild the extension.# Watch the source directory in one terminal, automatically rebuilding when neededjlpmwatch# Run JupyterLab in another terminaljupyterlabWith the watch command running, every saved change will immediately be built locally and available in your running JupyterLab. Refresh JupyterLab to load the change in your browser (you may need to wait several seconds for the extension to be rebuilt).By default, thejlpm buildcommand generates the source maps for this extension to make it easier to debug using the browser dev tools. To also generate source maps for the JupyterLab core extensions, you can run the following command:jupyterlabbuild--minimize=FalseDevelopment uninstallpipuninstallmakana_modelIn development mode, you will also need to remove the symlink created byjupyter labextension developcommand. To find its location, you can runjupyter labextension listto figure out where thelabextensionsfolder is located. Then you can remove the symlink namedmakana_modelwithin that folder.Packaging the extensionSeeRELEASE
Package: makana-service
makana_serviceMakana ServiceRequirementsJupyterLab >= 3.0InstallTo install the extension, execute:pipinstallmakana_serviceUninstallTo remove the extension, execute:pipuninstallmakana_serviceContributingDevelopment installNote: You will need NodeJS to build the extension package.Thejlpmcommand is JupyterLab's pinned version ofyarnthat is installed with JupyterLab. You may useyarnornpmin lieu ofjlpmbelow.# Clone the repo to your local environment# Change directory to the makana_service directory# Install package in development modepipinstall-e.# Link your development version of the extension with JupyterLabjupyterlabextensiondevelop.--overwrite# Rebuild extension Typescript source after making changesjlpmbuildYou can watch the source directory and run JupyterLab at the same time in different terminals to watch for changes in the extension's source and automatically rebuild the extension.# Watch the source directory in one terminal, automatically rebuilding when neededjlpmwatch# Run JupyterLab in another terminaljupyterlabWith the watch command running, every saved change will immediately be built locally and available in your running JupyterLab. Refresh JupyterLab to load the change in your browser (you may need to wait several seconds for the extension to be rebuilt).By default, thejlpm buildcommand generates the source maps for this extension to make it easier to debug using the browser dev tools. To also generate source maps for the JupyterLab core extensions, you can run the following command:jupyterlabbuild--minimize=FalseDevelopment uninstallpipuninstallmakana_serviceIn development mode, you will also need to remove the symlink created byjupyter labextension developcommand. To find its location, you can runjupyter labextension listto figure out where thelabextensionsfolder is located. Then you can remove the symlink namedmakana_servicewithin that folder.Packaging the extensionSeeRELEASE
Package: makasuipatch
makasuipatchA patch to simple pro to make you activate it. Just used for learning.Installpip install makasuipatchHow to useopensettings.pyINSTALLED_APPS = [
    "simplepro",
    "simpleui",
    "import_export",
    "makasuipatch",
    ...issueTested compatible versions- 6.xPackage command# build
python -m build

# upload to testpypi repo 
twine upload --repository testpypi dist/*

# install from testpypi repo 
pip install -i https://test.pypi.org/simple/ --no-deps makasuipatch

# upload to product repo
twine upload dist/*

# install from testpypi repo 
pip install makasuipatch --no-cache-dir
Package: makavafal-django-watchfiles
Usewatchfilesin Django’s autoreloader.RequirementsPython 3.7 to 3.10 supported.Django 2.2 to 4.0 supported.InstallationInstall withpip:python-mpipinstalldjango-watchfilesAdd django-watchfiles to yourINSTALLED_APPS:INSTALLED_APPS=[...,"django_watchfiles",...,]That’s it! 😅Django doesn’t provide an official API for alternative autoreloader classes.
Therefore, django-watchfiles monkey-patchesdjango.utils.autoreloadto make its own reloader the only available class.
You can tell it is installed asrunserverwill listWatchfilesReloaderas in use:$./manage.pyrunserverWatchingforfilechangeswithWatchfilesReloader...Unlike Django’s built-inWatchmanReloader, there is no need for a fallback toStatReloader, sincewatchfilesimplements its own internal fallback to usingstat.
Package: make
Source Code:https://github.com/fholmer/makePyPI:https://pypi.org/project/make/License: BSD LicenseSummaryCreate project layout from jinja2 templates.Installation$pipinstallmakeor$pipinstall--usermakeUsageIn general:$python-mmakeprojectsource-pathWheresource-pathcan be a local path:$python-mmakeprojectexamples/ini_featuresA local zip file:$python-mmakeprojectexamples/ini_features.zipZip file over http or https:$python-mmakeproject-psimple-masterhttps://gitlab.com/fholmer/simple/-/archive/master/simple-master.zipShort url for Github:$python-mmakeprojectgh:fholmer/simpleAnd Gitlab:$python-mmakeprojectgl:fholmer/simpleSub dirs is also supported for Gitlab:$python-mmakeprojectgl:fholmer/templates/proj1Simple cookiecutter templates is also supported.We will use a popular cookiecutter template in this example:$python-mmakeprojectgh:kragniz/cookiecutter-pypackage-minimalHow to make your own project templateThesource-pathhave to contain a file namedproject.conforproject.json.  Choose the format you prefer.Format ofproject.conf:[project]name=Apppackage={{project.name.lower().replace(' ','_').replace('-', '_')}}include_tests=json::["none", "pytest"]include_docs=json::["none", "sphinx", "mkdocs"]# this is a comment.# section or keys starting with _ is non-interactive variables_test_dir={{ 'tests' if project.include_tests != 'none' else '' }}[_docs]dir={%%- if project.include_docs== 'sphinx' -%%}docs{%%- elif project.include_docs== 'mkdocs' -%%}docz{%%- else -%%}{%%- endif -%%}The ini-format allows for multi line values, but%have to be escaped.
Comments is allowed. Use the special prefixjson::to serialize subsequent
text as json.Format ofproject.json:{"project":{"name":"App","package":"{{project.name.lower().replace(' ','_').replace('-', '_')}}","include_tests":["none","pytest"],"include_docs":["none","sphinx","mkdocs"],"_test_dir":"{{ 'tests' if project.include_tests != 'none' else '' }}"},"_docs":{"dir":"{%- if project.include_docs == 'sphinx' -%}\ndocs\n{%- elif project.include_docs == 'mkdocs' -%}\ndocz\n{%- else -%}\n{%- endif -%}"}}The json-format do not have multi line but you can use multiple\nin one
line.The source directory could be something like this:/My-Project-Template
  /{{project.name}}
    /{{_docs.dir}}
      conf.py
    /{{project._test_dir}}
    /{{project.package}}
      __init__.py
    setup.py
    LICENSE
    README.rst
  project.conf{{project.name}}/setup.pymay look something like this:fromsetuptoolsimportsetup,find_packagesfrom{{project.package}}import__version__asapp_versionsetup(name="{{ project.name }}",version=app_version,packages=find_packages(include=['{{ project.package }}*']),)
Package: makeapi
makeapiA small package, that allows you to make an API.Exampleimportmakeapiapp=MakeAPI("localhost",8000)# localhost is your local computer@app.get("/main")defmain(request:makeapi.Request):returnmakeapi.PlainResponse("Hello!")app.run()# Go to http://localhost:8000/main in your browser and you should see Hello!Example with POST requestimportmakeapiapp=MakeAPI("localhost",8000)@app.post("/main")defparams_route(request:makeapi.Request):params=request.jsonreturnJsonResponse(params)app.run()# Make post request and include json data to http://localhost:8000/main and it should show your json dataEnjoy!
Package: makeapp
https://github.com/idlesign/makeappDescriptionSimplifies Python application rollout and publishing.Make a skeleton for your new application with one console command.Automatically create a VCS repository for your application.Automatically check whether the chosen application name is not already in use.Customize new application layouts with skeleton templates.Put some skeleton default settings into a configuration file not to mess with command line switches anymore.Easily add entries to your changelog.Publish your application to remotes (VCS, PyPI) with single command.Application scaffoldingScaffold a new application:$makeappnewmy_new_app/home/librarian/mynewapp/-d"My application."--author"The Librarian"This will create a decent application skeleton using the default skeleton template (setup.py, docs, tests, etc.)
and initialize Git repository.makeappalso bundles templates for commonly used application types:clickpowered apppytestpowered apppytestpluginDjangoappwebscaffproject (https://github.com/idlesign/webscaff)etc.Multiple templates can be used together. Complete list of featured templates can be found in the documentation.
User-made templates are also supported.Application publishingWhen you’re ready to publish issue the following command while in project directory (containingsetup.py):$makeapprelease;Bumpversionnumberpartmanually:major,minor,patch$makeapprelease--incrementmajorThis will automatically:bump up application version numbertag version in VCSpush sources to remote repositoryupload application package to PyPIAdding changesWhen you’re ready to add another entry to your changelog usechangecommand:$makeappchange"+ New 'change' command implemented"This will also stage and commit all changed files.Supported message prefixes:+- New feature / addition.Incrementsminorpart of version number onreleasecommand.!- Important change/improvement/fix.Increment:patchpart.-- Feature deprecation / removalIncrement:patch.*- Minor change/improvement/fix.*prefix is added by default if none of the above mentioned prefixes found.Increment:patch.Bash completionTo enable bash completion formakeappcommand append the following line into your.bashrc:eval"$(_MAKEAPP_COMPLETE=sourcemakeapp)"Documentationhttps://makeapp.readthedocs.org/
Package: makeasciiart
makeasciiartLet's make ascii artDependencypip install opencv-python
pip install numpyUsagepip install makeasciiartimportmakeasciiartimportnumpyasnpimportcv2img2ascii.pydefimg2ascii(filename,color_mode=True,fontsize=5):returnimg,newimg# img : original image, newimg : ascii art imageExample 1## Displayfilename='test.jfif'origin,newimg=makeasciiart.img2ascii(filename)iftype(newimg)==type(None):exit()cv2.imshow("origin",origin)cv2.imshow("res",newimg)cv2.waitKey()cv2.destroyAllWindows()
Package: make.bat
make.batRequirementsDocker for Windows:https://docs.docker.com/docker-for-windows/install/InstallationC:\Users\SamSepiol> pip install make.batUsageAs a standard GNU Make simply youC:\Users\SamSepiol\MrProject> makeDocumentationAlternative installationNodeJSRequirementsDocker for Windows:https://docs.docker.com/docker-for-windows/install/NodeJS for Windows:https://nodejs.org/en/download/InstallationC:\Users\SamSepiol> npm install -g make.batManual setup%USERPROFILE%\AppData\Local\Microsoft\WindowsAppsDevelopmentdockerrun-v/var/run/docker.sock:/var/run/docker.sock\-v/usr/bin/docker:/usr/bin/docker
Package: make_better
make_bettermake_better is a Python package designed to improve the quality of your code by providing preconfigured linters and a
code formatter. The package is built to make it easy for Python developers to maintain high standards in their code by
running a single command.FeaturesPreconfigured linters to check your code for potential issues without being too annoying.A preconfigured code formatter to ensure your code is formatted according to best practices.Easy to use: simply run a single command to check and format your code.Saves time by removing the routine of having to check and format code manually.InstallationYou can install make_better via pip:pipinstallmake_betterUsageTo check and format your code, simply navigate to the directory containing your Python files and run the following
command:make_better--autoformatThis will run the preconfigured linters and code formatter on your code. Any potential issues will be flagged, and your
code will be formatted according to best practices.Why line-length 90We use a line length of 90, so that people on laptops with a diagonal of 16 do not have problems during the review