Saravanan666/pypi-org huggingface dataset:
Package: docop-tasks-restricted
This package contains packaged tasks for Docop.The tasks use code that has fairly restrictive licensing for commercial use.In particular, this package may contain code licensed under AGPL.Be sure to respect the licenses.For packaged tasks with more permissive licenses, see:https://github.com/koodaamo/docop-tasks-restrictedhtml2text taskExtract plain text content of the HTML string.Expects HTML text in thehtmlfield of document.
Output document will have following fields set:textfield containing the plain text content of the HTMLfingerprintgenerated from the text field for e.g. detecting changesmodifiedfield indicating when text was changed, based on fingerprint, in HTTP Last-Modified format
Package: docopt-c
C-code generator for docopt languageNote,at this point the code generator handles only options(positional arguments, commands and pattern matching will follow).Step 1. Describe your CLI in docopt languageNaval Fate.

Usage:
  naval_fate ship create <name>...
  naval_fate ship <name> move <x> <y> [--speed=<kn>]
  naval_fate ship shoot <x> <y>
  naval_fate mine (set|remove) <x> <y> [--moored|--drifting]
  naval_fate --help
  naval_fate --version

Options:
  -h --help     Show this screen.
  --version     Show version.
  --speed=<kn>  Speed in knots [default: 10].
  --moored      Moored (anchored) mine.
  --drifting    Drifting mine.Step 2. Generate the C code$python-mdocopt_c-odocopt.cexample.docoptor by using pipe$catexample.docopt|python-mdocopt_c>docopt.cStep 3. Include the generateddocopt.cinto your program#include<stdlib.h>#include"docopt.c"intmain(intargc,char*argv[]){DocoptArgsargs=docopt(argc,argv,/* help */1,/* version */"2.0rc2");printf("Commands\n");printf("    mine == %s\n",args.mine?"true":"false");printf("    move == %s\n",args.move?"true":"false");printf("    create == %s\n",args.create?"true":"false");printf("    remove == %s\n",args.remove?"true":"false");printf("    set == %s\n",args.set?"true":"false");printf("    ship == %s\n",args.ship?"true":"false");printf("    shoot == %s\n",args.shoot?"true":"false");printf("Arguments\n");printf("    x == %s\n",args.x);printf("    y == %s\n",args.y);printf("Flags\n");printf("    --drifting == %s\n",args.drifting?"true":"false");printf("    --help == %s\n",args.help?"true":"false");printf("    --moored == %s\n",args.moored?"true":"false");printf("    --version == %s\n",args.version?"true":"false");printf("Options\n");printf("    --speed == %s\n",args.speed);returnEXIT_SUCCESS;}Step 4. Profit!$c99example.c-oexample.out
$./example.outmine--drifting--speed=20Commandsmine==truemove==falsecreate==falseremove==falseset==falseship==falseshoot==falseArgumentsx==(null)y==(null)Flags--drifting==true--help==false--moored==false--version==falseOptions--speed==20DevelopmentSee thePython version's pagefor more
info on developing.
Package: docoptcfg
Love usingdocoptover argparse orClick? Wish it took care of
environment variables and/or config files?docoptcfgis a wrapper fordocoptwhich handles reading configuration data from environment variables and/or an
INI/INF configuration file. You can (1) enable only the environment variable part, (2) only the config file part, (3) or
use both at the same time:args = docoptcfg(__doc__,env_prefix='MYAPP_')args = docoptcfg(__doc__,config_option='--config')args = docoptcfg(__doc__,config_option='--config',env_prefix='MYAPP_')📖 Full documentation:https://docoptcfg.readthedocs.orgPython 2.6, 2.7, PyPy, PyPy3, 3.3, 3.4, and 3.5 supported on Linux and OS X.Python 2.7, 3.3, 3.4, and 3.5 supported on Windows (both 32 and 64 bit versions of Python).QuickstartInstall:pipinstalldocoptcfgChangelogThis project adheres toSemantic Versioning.1.0.2 - 2016-06-28FixedBug where docoptcfg failed to handle positional arguments with repeating args/opts.1.0.1 - 2016-01-25Fixedsetup.py was previously configured for packages, not modules.1.0.0 - 2016-01-25Initial release.
Package: docopt-cmd
…Example"""Do somethings

Usage:
    example.py [-vfr] do (a|b)

Options:
    -v --verbose    Be verbose.
    -f --force      Force.
    -r --random     Huh?.
"""fromdocoptimportdocoptfromdocopt_cmdimportcmddefmain():args=docopt(__doc__)#print(args)cmd.dispatch(args)#explicitly specify spec and options to pass as arguments@cmd('do a',force='--force')defsomething(force):print('doing a')print(force)#or use magic@cmddefdo_b(random):print'doing b'printrandomif__name__=='__main__':main()
Package: docopt-dispatch
Experimental.Example"""Run something in development or production mode.

Usage: run.py --development <host> <port>
       run.py --production <host> <port>
       run.py remote add <item>
       run.py remote delete <item>

"""fromdocopt_dispatchimportdispatch@dispatch.on('--development')defdevelopment(host,port,**kwargs):print('in *development* mode')@dispatch.on('--production')defdevelopment(host,port,**kwargs):print('in *production* mode')@dispatch.on('items','add')defitems_add(item,**kwargs):print('adding item...')@dispatch.on('items','delete')defitems_delete(item,**kwargs):print('deleting item...')if__name__=='__main__':dispatch(__doc__)
Package: docopt-rc
docopt-rcis a drop-in rc-file parser augmenter fordocopt.Quick User’s GuideThese are the nessesary steps to usedocopt-rc:Install the package$pipinstalldocopt-rcImport into your projectfromdocoptimportdocoptimportrcimportmyscriptRun docopt to parse the command line argumentsargs=docopt(__doc__,version='MyScript{v}'.format(v=myscript.__version__))Set up your script level defaults (lowest priority)defaults={'url':'news.layervault.com','category':'news','votes':0}Parse potential config-files, both in user home and in the current directory. Missing files are silently skipped.# Merge the command line arguments with the defaults and any values# found in either global (`$HOME`) or local (this folder) config files.options=rc.extend_args(args,__file__,defaults,scopes=['global','local'])That’s it. We have now merged the defaults <= user configs <= command line arguments.DocumentationFor the time being I will refer you to the somewhat complete inline documentation for each function in the package.Background & MotivationConfig files can unburden the command line and allow users to set user/project specific defaults. A common practice is to name such files.<script_name>rc, e.g. ‘.bashrc’, ‘.bowerrc’. The values in such an rc-file should take precedence over script level defaults but be overwritten by command line arguments.I needed a very simple script that would parse both global (user), local (project), and custom config files and play nice with the excellent docopt package.Flaws & Limitationsdocopt, as great as it is, does come with a few limitations when trying to integrate with a config file parser. My solution has three nagging flaws:Boolean options (flags) become a major issue. There isn’t any built in way to flagFalseandprobably won’t beeither. This means you can’t override an options that defaults toTruefrom a config file. The current solution is toavoid flags in favor of `–option=<bool>`where bool is (‘yes’, ‘no’, ‘true’, ‘false’).docoptprovides a useful way to set defaults. Problem is that I couldn’t find a way to parse those defaults to compare what user supplied and default values. I thereforerequire all defaults to be set in a separate `dict`outside of the docstring.The intuative syntax for<position argument>,–option,commandworks greatin-scriptbut would be awkward as a requirement for user authored config files. Q.E.D.: I require thatno two argument/option/command names be the same.ChecklistDOES support YAML and JSON file formats (“JSON is YAML”)DOES convert docopt args to simpler versions by removing ‘–’ and ‘<>’DO NOT define your own defaults in the document stringDO define defaults in a separatedictDO NOT use boolean arguments (flags) you want to overwrite.DO use–option=<bool>where ‘bool’ is ‘yes’/’no’ in favor of flagsDO expect config files to be named “.<myapp>rc”DO NOT use multiple types of arguments with the the same nameLicense, Authors, ChangelogRead LICENSE, AUTHORS, CHANGELOG.rst
Package: docoseco
DocosecoDocker-composesecrets andconfigs.Automatize management of docker confgs and secrets.Usagedocoseco [CONFIG_ROOT_DIR] < docker-compose.template.yaml > docker-compose.yaml

  CONFIG_ROOT_DIR  Root directory for file search (default: .)It reads docker-compose yaml from stdin, updates all config and secret names with corresponding file content hashsums and writes result to stdout.RationaleDocker-compose configs and secrets are immutable by design. So, when config or secret is created from file viadocker stack deploy, it's impossible to update the file and deploy in the same way again. For example:# docker-compose.yamlversion:"3.8"services:redis:image:redis:latestconfigs:-source:my_configtarget:/redis_configconfigs:my_config:file:./my_config.txtIf, after the initial deployment,my_config.txtis changed, the next deployment attempt will fail.The common workaround is creating a new config, when a source file changes.
This is done by changing config name:# docker-compose.yaml...configs:my_config:name:my_config-2# Changing name creates new docker configfile:./my_config.txt# This file was changedTo avoid manual management of config names, numerical suffix might be replaced by a file content hashsum, which can be automatically calculated.# docker-compose.yaml...configs:my_config:name:my_config-bee414b86ee02806b17104813d44eea4# Auto-generated config namefile:./my_config.txt# This file was changed
Package: docoskin
Docoskin"Onion-skin" visual differences between a reference document image and a scanned copy.Given an image of a reference document, docoskin will attempt to find key points of the document in a scanned copy,
align the two, auto-correct the image contrasts and display a combined image, featuring sections in red which were
"removed from" the reference document and sections in green which were added to the document.The intended use for this is comparing a signed, returned scan of a contract with the original version as provided to
the signer to check for unagreed amendments.Implemented as a python library with a command-line interface. Significantly more power and flexibility is
achievable through accessing the python components.Depends on opencv and six (and, on python2.7, thefuturesbackport).opencv is always going to be a slightly painful dependency from a python point of view because a) it's a native library
and b) it doesn't really play by python packaging rules supplying an egg. I advocate use ofNixto
solve both these problems and provide adefault.nixso thatnixusers can simply perform a$ nix-shell .in the source directory for a development-ready shell (somthing like a non-python-specificvirtualenv).Those wishing to attempt using the pypiopencv-pythonpackage can try installing the package with the 'extra'pypi_opencv, whichhypotheticallyshould download & install opencv from pypi$ pip install -e .[pypi_opencv]butthe author has never had any luck with that and has unfavourable opinions ofpipin general, not to mention the
concept of downloading & installing binaries from pypi.Preliminary license is GPLv3.TestsThe test suite makes use of images which are kept in a git submodule due to their size. Performing a$ git submodule init
$ git submodule updateshould fetch the required data. If this data is not present, the tests will quietly skip tests requiring images (which
is most of them, though).
Package: docov
docovLight-weight, recursive docstring coverage analysis for python modules.Overviewdocovprovides light-weight docstring coverage analysis for python modules.
It recursively collects symbols defined by the specified module and checks whether these
symbols have docstrings and if they are longer than at least 20 symbols.The docstring coverage is computed simply as the fraction of symbols which are deemed
to have a sufficient docstring and the total number of symbols found.The command-line utility will generate a badge indicating the docstring coverage and
a report listing all symbols found in the module, which do not have sufficient
docstrings.In order to not distort the docstring coverage, symbols and modules (and their symbols)
can be ignored in the analysis.
This allows for some fine-tuning in really only considering the desired module's symbols.
Builtin types are currently always ignored, meaning that e.g. methods of a string object
in a module will not be assessed.Installationdocovis available viaPyPI:$ pip install docovUsageOnce installed,docovcan be used from the command-line$ docov <module-name>which will produce a badge and a report on symbols, which were deemed to have insufficient docstring.A short help text on available options can be found with$ docov -h
usage: docov [-h] [-o DIR] [-p PREFIX] [-i SYMBOL [SYMBOL ...]] [-d DEPTH] [--no-badge] [--no-report] MODULE

Command line utility to analyze docstring coverage of python modules.
Works by recursively fetching the module's symbol's docstrings and 
checking that they consist of at least 20 characters.

Generates a SVG-badge and a report if not specified otherwise, stored in
DIR/[PREFIX_]docov.svg and DIR/[PREFIX_]docov.txt respectively.

positional arguments:
  MODULE                The module which is to be analyzed.

optional arguments:
  -h, --help            show this help message and exit
  -o DIR, --output DIR  Output directory.
  -p PREFIX, --prefix PREFIX
                        Output file prefix: PREFIX_docov.[txt,svg]
  -i SYMBOL [SYMBOL ...], --ignore SYMBOL [SYMBOL ...]
                        Ignore symbols. If the symbol names a module, all its types will be ignored in the recursion.
  -d DEPTH, --depth DEPTH
                        Analysis recursion depth.
  --no-badge            Suppress badge generation.
  --no-report           Suppress report generation.
Package: docpie
An easy and Pythonic way to create your POSIX command lineView on:GitHub/PyPiContentsChangeLogSummaryInstallationGet Start!Why docpie?ReferenceLicenseDonateChangeLogversion 0.4.4:change auto balance function, fix the issue that won’t work for this case"""
Usage:
    cp [options] <source>... <target>

Options:
    -R
"""SummaryHow do you define your command line interface?
Write a parse by yourself or spend hours learningoptparse/argparse,
and modify both code side and document every time you update the interface?Life is short, man! You can simply do it this way:"""
My copy script

Usage:
  cp.py [options] <source_file> <target_file>
  cp.py [options] <source_file>... <target_directory>

Options:
  -h -? --help    print this screen
  --version       print the version of this script
  -v --verbose    print more information while  running
"""fromdocpieimportdocpieargs=docpie(__doc__)print(args)Now run it$pythoncp.pya.txtb.txtc.txt/tmp{'--':False,'--help':False,'--verbose':False,'--version':False,'-?':False,'-h':False,'-v':False,'<source_file>':['a.txt','b.txt','c.txt'],'<target_directory>':'/tmp','<target_file>':None}Write a__doc__, pass it to a function, DONE! Isn’t it simple?try it >>InstallationInstall release version:pipinstalldocpieInstall nightly/dev version:pipinstallgit+https://github.com/TylerTemp/docpie.git@devdocpiehas been tested with Python:2.6, 2.7, pypy-2.0, pypy-2.63.2, 3.3, 3.4, 3.5, pypy3-2.4You can run test suit bypython setup.py testGet Start!Interested? VisitWikiand get start!Or you cantry it in your browserWhy docpie?docpiecan greatly reduce the work you need to be done for
command-line interface. What you see is what you get.
Every time you only need to update your document, and keep the
code unchanged.Seeherefor more reasons.Referencethe code inbashlog.pyis taken fromtornado, andtracemore.pyis frompython
CookbookMany examples & tests are fromdocopt.Licensedocpieis released underMIT-LicenseDonateIf you like this project, you can buy me a beer so I can make it better!
Package: docpipe
docpipeA simple document pipeline mechanism that makes it easier to process and clean up Word and other document types.Other dependenciesThis has some other non-Python dependencies for certain functionality:soffice (open office) for handling DOC and DOCX filespdftotext (poppler-utils) for extracting text from PDFsLocal developmentClone this repoSetup a virtual environmentInstall dependencies:pip install -e '.[test]'Run tests:nosetestsLicenseCopyright 2022 Laws.Africa.This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU Lesser General Public License for more details.You should have received a copy of the GNU Lesser General Public License
along with this program.  If not, seehttps://www.gnu.org/licenses/.
Package: docplates
DocplatesDocplates is a PDF document templater which uses Jinja2 and LaTeX/WeasyPrint backends to create documents.InstallingDocplates can be simply installed by running:pip install docplatesOr if you prefer the development branch, one could use:pip install git+https://gitlab.oscdev.io/software/docplates/docplates.gitAlternatively if you prefer installing from a checked out git repository:pip install .Lastly, you could also build it and install the wheel...tox -e build
pip install dist/docplates-*.whlDocumentationDocplates DocumentationContributingSupportIssue TrackerLicenseDocplates is licensed under theGNU GPL v3 License.
Package: docplus
Documents UtilsUsageMake surelibreofficeis installed.Install docpluspip install --user docplusRun API Servierpython -m docplusAPIsFormat Convertuse httpie, convert to pdfhttp POST -f :5000/convert_to/pdf file@~/demo.docxuse httpie, convert to htmlhttp POST -f :5000/convert_to/html file@~/demo.docx
Package: docpy
docpyThis package auto-generates Markdown documentation from Python files.InstallationThis package is installed using pip:pip install docpyUsageThis package is used from the command line:docpy ...The package help entry is given below.usage: docpy [-h] [-a APPEND] [-o OUT] [-s SUB] [-t TEMP] ...

generate Markdown documentation for Python files

positional arguments:
  files                 files to be documented

optional arguments:
  -h, --help            show this help message and exit
  -a APPEND, --append APPEND
                        file to which to append generated Markdown
  -o OUT, --output OUT  file to save generated Markdown to
  -s SUB, --sub SUB     file with ::DOCUMENTATION:: tag to replace Markdown
  -t TEMP, --template TEMP
                        template file with ::DOCUMENTATION:: tag, needs OUT
                        argumentTemplatesYou can define a Markdown template in which your documentation will be placed using the-tflag, which must be used in conjunction with the-oflag. In your template, just put::DOCUMENTATION::where you want the documentation to be placed. For example,# This is a markdown file.My docs are below:

::DOCUMENTATION::_this concludes the documentation._Changelogv0.1.1:Fixed formatting error in docstringsv0.1.0:Initial release
Package: docraise
DocraiseDocraise is a Python project that checks whether the docstrings in your Python code contain valid "Raises" sections.
It ensures that every exception your code raises is documented in the docstrings, and vice versa - that every exception documented in the docstrings is actually raised by the code.InstallationInstall the project dependencies:pipinstall-rrequirements-dev.txtpre-commit setupDocraise usespre-committo manage git hooks. This helps to ensure that code style, tests, and other checks are run before each commit.We use the following pre-commit plugins:black: Ensures our Python code adheres to the Black code style.flake8: Lints our Python code to catch potential bugs.isort: Sorts our Python imports.mypy: Checks our Python code for type errors.pydocstyle: Checks our Python docstrings to ensure they adhere to the docstring conventions.conventional commit: Ensures all commit messages adhere to the Conventional Commits style.In the project directory, install the pre-commit hooks:pre-commitinstall
pre-commitinstall--hook-typecommit-msgUsageTODOTestingTODOpytesttests/
Package: docreader
DocReaderA utility for reading a CSV file and mapping it’s contents to python objects
based on the field names in the document.Contains classes for reading loosly structured documents containing rows of
text (eg. CSV files) and turning them into slightly higher level lists of
dictionaries.Typical usage is to create a subclass of DocReader and define the cols attribute
once. To use it, instantiate the subclass with an open file-like object (that
supports the iterator protocol and returns a full line of text on each next()
call).Iterating over the DocReader subclass instance will then yield a dict where the
keys are as defined in the cols attribute and the values are the cell’s logical
values that have passed through the correct conversion function.The cols attribute is itself is either a list of column names or a dictionary
mapping keys (which will be used as the keys in the final returned data) to an
options dictionary for that column.An options dictionary can have the following keys:column: The name of the column as it appears in the documentconvert: A callable that will be called with the string associated withthe data in this cell. Often a type (eg int, float) or a lambda.>>> import decimal
>>> def _price(val):
...     txt = val.replace('$', '').strip().lower()
...     txt = txt or None
...     return decimal.Decimal(txt)
...
>>> class MyReader(DocReader):
...     cols = dict(
...         a = dict(column='a', convert=int),
...         q = dict(column='b'),
...         c = dict(column='c', convert=lambda x: int(x)),
...         price = dict(convert=_price),
...     )
...
>>> import StringIO
>>> #Ignore the use of chr(10), doctest doesn't like \n.
>>> list(MyReader(StringIO.StringIO("a,b,c,price" + chr(10) + "1,2,3,$45.6" + chr(10) + "4,5,6,$55")))
[{u'a': 1, u'q': u'2', u'c': 3, u'price': Decimal('45.6')}, {u'a': 4, u'q': u'5', u'c': 6, u'price': Decimal('55')}]
>>> list(MyReader(StringIO.StringIO("a,b" + chr(10) + "1,2")))
Traceback (most recent call last):
...
MissingColumnException: Columns missing from input: c, price
Package: docrep
docstestspackageWhat’s this?Welcome to thedocumentationrepetition moduledocrep! This
module targets developers that develop complex and nested Python APIs and
helps them to create a well-documented piece of software.See thedocumentation on readthedocsfor a small tutorial.InstallationInstallation simply goes via pip:$ pip install docrepor viaconda:$ conda install -c conda-forge docrepor from the source ongithubvia:$ python setup.py installDisclaimerCopyright 2021 Philipp S. Sommer, Helmholtz-Zentrum GeesthachtLicensed under the Apache License, Version 2.0 (the “License”);
you may not use this file except in compliance with the License.
You may obtain a copy of the License athttp://www.apache.org/licenses/LICENSE-2.0Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an “AS IS” BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Package: docrepo
<a href="https://liberapay.com/TralahM/donate"><img alt="Donate using Liberapay" src="https://liberapay.com/assets/widgets/donate.svg"></a>docrepo.DocumentationInstallation#Interminaldo:$Building from Source for Developers$gitclonehttps://github.com/TralahM/docrepo.git$cddocrepoContributingSee the Contributing FileSee the Pull Request FileSupportLICENCERead the license hereSelf-Promotion