python-saneyaml_0.3.orig/.gitignore0000644000000000000000000000114013374544111014442 0ustar00# ScanCode special files /SCANCODE_DEV_MODE # Python compiled files *.py[cod] # virtualenv and other misc bits *.egg-info /dist /build /bin /lib /scripts /Scripts /Lib /pip-selfcheck.json /tmp .Python /include /Include /local */local/* /local/ /share/ /tcl/ /.eggs/ # Installer logs pip-log.txt # Unit test / coverage reports .cache .coverage .coverage.* nosetests.xml htmlcov # Translations *.mo # IDEs .project .pydevproject .idea org.eclipse.core.resources.prefs .vscode # Sphinx docs/_build # Various junk and temp files .DS_Store *~ .*.sw[po] .build .ve *.bak /.cache/ # pyenv /.python-version python-saneyaml_0.3.orig/.travis.yml0000644000000000000000000000065613374544111014576 0ustar00language: python python: - "2.7" - "3.6" install: - pip install -r requirements_dev.txt script: - bin/py.test -vvs tests notifications: irc: channels: - "chat.freenode.net#aboutcode" on_success: change on_failure: always use_notice: true skip_join: true template: - "%{repository_slug}#%{build_number} (%{branch} - %{commit} : %{author}): %{message} : %{build_url}" python-saneyaml_0.3.orig/CHANGELOG.rst0000644000000000000000000000011113374544111014470 0ustar00Changelog ========= 0.1 (2018-11-17) ---------------- Initial release. python-saneyaml_0.3.orig/CONTRIBUTING.rst0000644000000000000000000000721713374544111015126 0ustar00============ Contributing ============ Contributions are welcome and appreciated! Every little bit helps, and credit will always be given. .. _issue : https://github.com/nexB/saneyaml/issue __ issue_ If you are new and want to find easy tickets to work on, check `easy issues `_ When contributing to this project (such as code, bugs, documentation, etc.) you agree to the Developer `Certificate of Origin `_ and its license (see the `apache-2.0.LICENSE `_ file). The same approach is used by the Linux Kernel developers and several other projects. For commits, it is best to simply add a line like this to your commit message, with your name and email:: Signed-off-by: Jane Doe Please try to write a good commit message, see `good commit message wiki `_ for details. In particular use the imperative for your commit subject: think that you are giving an order to the codebase to update itself. Feature requests and feedback ============================= To send feedback or ask a question, `file an issue `_ If you are proposing a feature: * Explain how it would work. * Keep the scope simple possible to make it easier to implement. * Remember that your contributions are welcomed to implement this feature! Chat with other developers ========================== For other questions, discussions, and chats, we have: - an official Gitter channel at https://gitter.im/aboutcode-org/discuss Gitter also has an IRC bridge at https://irc.gitter.im/ This is the main place where we chat and meet. - an official #aboutcode IRC channel on freenode (server chat.freenode.net) for scancode and other related tools. You can use your favorite IRC client or use the web chat at https://webchat.freenode.net/ . This is a busy place with a lot of CI and commit notifications that makes actual chat sometimes difficult! - a mailing list at `sourceforge `_ Bug reports =========== When `reporting a bug`__ please include: * Your operating system name, version and architecture (32 or 64 bits). * Your Python version. * Your Saneyaml version. * Any additional details about your local setup that might be helpful to diagnose this bug. * Detailed steps to reproduce the bug, such as the commands you ran and a link to the code you are scanning. * The errors messages or failure trace if any. * If helpful, you can add a screenshot as an issue attachment when relevant or some extra file as a link to a `Gist `_. Documentation improvements ========================== Documentation can come in the form of wiki pages, docstrings, blog posts, articles, etc. Even a minor typo fix is welcomed. See also extra documentation on the `Wiki `_. Pull Request Guidelines ----------------------- If you need a code review or feedback while you are developing the code just create a pull request. You can add new commits to your branch as needed. For merging, your request would need to: 1. Include unit tests that are passing (run ``py.test``). 2. Update documentation as needed for new API, functionality etc. 3. Add a note to ``CHANGELOG.rst`` about the changes. 4. Add your name to ``AUTHORS.rst``. Test tips --------- To run a subset of test functions containing test_myfeature in their name use:: py.test -k test_myfeature To run tests verbosely, displaying all print statements to terminal:: py.test -vvs python-saneyaml_0.3.orig/MANIFEST.in0000644000000000000000000000052413374544111014215 0ustar00graft src graft tests prune src/saneyaml.egg-info include CHANGELOG.rst include README.rst include CONTRIBUTING.rst include apache-2.0.LICENSE include NOTICE include MANIFEST.in include setup.py include setup.cfg include .gitignore include .travis.yml include appveyor.yml include saneyaml.ABOUT global-exclude *.py[co] __pycache__ *.*~ python-saneyaml_0.3.orig/NOTICE0000644000000000000000000000117713374544111013370 0ustar00Copyright (c) 2018 nexB Inc. and others. All rights reserved. http://nexb.com and https://github.com/nexB/saneyaml/ Licensed 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 at http://www.apache.org/licenses/LICENSE-2.0 Unless 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. python-saneyaml_0.3.orig/README.rst0000644000000000000000000000261013374544111014144 0ustar00======== saneyaml ======== This micro library is a PyYaml wrapper with sane behaviour to read and write readable YAML safely, typically when used with configuration files. With saneyaml you can dump readable and clean YAML and load safely any YAML preserving ordering and avoiding surprises of type conversions by loading everything except booleans as strings. Optionally you can check for duplicated map keys when loading YAML. Works with Python 2 and 3. Requires PyYAML. License: apache-2.0 Homepage_url: https://github.com/nexB/saneyaml Usage:: pip install saneyaml >>> from saneyaml import load as l >>> from saneyaml import dump as d >>> a=l('''version: 3.0.0.dev6 ... ... description: | ... AboutCode Toolkit is a tool to process ABOUT files. An ABOUT file ... provides a way to document a software component. ... ''') >>> a OrderedDict([ (u'version', u'3.0.0.dev6'), (u'description', u'AboutCode Toolkit is a tool to process ABOUT files. ' 'An ABOUT file\nprovides a way to document a software component.\n')]) >>> pprint(a.items()) [(u'version', u'3.0.0.dev6'), (u'description', u'AboutCode Toolkit is a tool to process ABOUT files. An ABOUT file\nprovides a way to document a software component.\n')] >>> print(d(a)) version: 3.0.0.dev6 description: | AboutCode Toolkit is a tool to process ABOUT files. An ABOUT file provides a way to document a software component. python-saneyaml_0.3.orig/apache-2.0.LICENSE0000644000000000000000000002367513374544111015215 0ustar00 Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS python-saneyaml_0.3.orig/appveyor.yml0000644000000000000000000000076613374544111015057 0ustar00version: '{build}' install: - configure etc/conf/dev build: off test_script: - set - py.test -vvs tests on_success: - "python etc/scripts/irc-notify.py aboutcode [{project_name}:{branch}] {short_commit}: \"{message}\" ({author}) {color_green}Succeeded,Details: {build_url},Commit: {commit_url}" on_failure: - "python etc/scripts/irc-notify.py aboutcode [{project_name}:{branch}] {short_commit}: \"{message}\" ({author}) {color_red}Failed,Details: {build_url},Commit: {commit_url}" python-saneyaml_0.3.orig/requirements_dev.txt0000644000000000000000000000001513374544111016574 0ustar00pytest -e . python-saneyaml_0.3.orig/saneyaml.ABOUT0000644000000000000000000000054613374544111015070 0ustar00about_resource: . name: saneyaml description: | homepage_url: http://www.nexb.com/community.html license_expression: apache-2.0 licenses: - key: apache-2.0 name: Apache 2.0 file: apache-2.0.LICENSE copyright: Copyright (c) 2018 nexB Inc. and others notice_file: NOTICE vcs_tool: git vcs_repository: https://github.com/nexB/saneyaml.git python-saneyaml_0.3.orig/setup.cfg0000644000000000000000000000110213374544111014271 0ustar00[bdist_wheel] universal = 1 [metadata] license_file = NOTICE [aliases] release = clean --all sdist bdist_wheel [tool:pytest] norecursedirs = .git bin dist build _build dist local ci docs man share samples .cache .settings etc Include include Lib lib Scripts thirdparty/* tmp/* tests/testdata/* python_files = *.py python_classes=Test python_functions=test addopts = -rfEsxXw --strict -s -vv --ignore docs/conf.py --ignore setup.py --doctest-modules python-saneyaml_0.3.orig/setup.py0000644000000000000000000000327013452447145014200 0ustar00#!/usr/bin/env python # -*- encoding: utf-8 -*- from __future__ import absolute_import from __future__ import print_function from glob import glob import io from os.path import basename from os.path import dirname from os.path import join from os.path import splitext from setuptools import find_packages from setuptools import setup setup( name='saneyaml', version='0.3', license='Apache-2.0', description='Dump readable YAML and load safely any YAML preserving ' 'ordering and avoiding surprises of type conversions. ' 'This library is a PyYaml wrapper with sane behaviour to read and ' 'write readable YAML safely, typically when used for configuration.', long_description='', author='AboutCode authors and others.', author_email='info@nexb.com', url='http://aboutcode.org', packages=find_packages('src'), package_dir={'': 'src'}, py_modules=[splitext(basename(path))[0] for path in glob('src/*.py')], include_package_data=True, zip_safe=False, platforms='any', classifiers=[ 'Development Status :: 5 - Production/Stable', 'Programming Language :: Python', 'Programming Language :: Python :: 2', 'Programming Language :: Python :: 2.7', 'Programming Language :: Python :: 3', 'Programming Language :: Python :: 3.6', 'Intended Audience :: Developers', 'License :: OSI Approved :: Apache Software License', 'Operating System :: OS Independent', 'Topic :: Software Development', 'Topic :: Utilities', ], keywords=[ 'yaml', 'block', 'flow', 'readable', ], install_requires=[ 'PyYAML >= 3.11, <= 3.13', ], ) python-saneyaml_0.3.orig/src/0000755000000000000000000000000013374544111013245 5ustar00python-saneyaml_0.3.orig/tests/0000755000000000000000000000000013211266106013613 5ustar00python-saneyaml_0.3.orig/src/saneyaml.py0000644000000000000000000002466513452447145015453 0ustar00#!/usr/bin/env python # -*- coding: utf8 -*- # # Copyright (c) 2018 nexB Inc. and others. All rights reserved. # http://nexb.com and https://github.com/nexB/saneyaml/ # # Licensed 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 at # http://www.apache.org/licenses/LICENSE-2.0 # Unless 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. from __future__ import absolute_import from __future__ import print_function from __future__ import unicode_literals from collections import OrderedDict from functools import partial import sys import yaml from yaml.error import YAMLError from yaml.emitter import Emitter from yaml.resolver import Resolver from yaml.representer import SafeRepresenter from yaml.serializer import Serializer try: # pragma: nocover from yaml import CSafeLoader as SafeLoader except ImportError: # pragma: nocover from yaml import SafeLoader try: # pragma: nocover # Python 2 unicode except NameError: # pragma: nocover # Python 3 unicode = str # NOQA # Python 2 to 3.5 python2 = sys.version_info[0] < 3 python3old = sys.version_info[0] == 3 and sys.version_info[1] < 6 OLD_PY = python2 or python3old if OLD_PY: # pragma: nocover from collections import OrderedDict as odict else: # CPython 3.6 and up dict is ordered by default. And this is the Python spec # in 3.7 and up. odict = dict """ A wrapper around PyYAML to provide sane defaults ensuring that dump/load does not damage content, keeps ordering and ordered mappings, use always block-style and use two spaces indents to get the most readable YAML and quotes or folds texts in a sane way. Use the `load` function to get a primitive type from a YAML string and the `dump` function to get a YAML string from a primitive type. Optionally check that there are no duplicated map keys when loading. Load and dump rely on subclasses of SafeLoader and SafeDumper respectively doing all the dirty bidding to get PyYAML straight. Note that since PyYAML does not have a consistent dump indent behaviou accross versions and Python vs C/libyaml, the tests may behave differently in some cases and fail. """ ############################################################################### # Loading ############################################################################### def load(s, allow_duplicate_keys=True): """ Return an object safely loaded from a YAML string `s`. `s` must be unicode or a string that converts to unicode without errors using an `utf-8` codec. If `allow_duplicate_keys` is False, a DuplicateYamlMappingKeyError Exception is raised if a mapping contains duplicated keys. """ if allow_duplicate_keys: loader = SaneLoader else: loader = DupeKeySaneLoader return yaml.load(s, Loader=loader) class UnsupportedYamlFeatureError(YAMLError): pass class BaseSaneLoader(SafeLoader): """ A base safe loader configured with many sane defaults. """ def string_loader(loader, node): # NOQA """ Ensure that a scalar type (a value) is returned as a plain unicode string. """ return loader.construct_scalar(node) def ordered_loader(self, node, check_dupe=False): """ Ensure that YAML maps order is preserved and loaded in an ordered mapping. """ assert isinstance(node, yaml.MappingNode) omap = odict() yield omap for key, value in node.value: key = self.construct_object(key) value = self.construct_object(value) if check_dupe and key in omap: raise UnsupportedYamlFeatureError( 'Duplicate key in YAML source: {}'.format(key)) omap[key] = value # Load most types as strings : nulls, ints, (such as in version 01) floats (such # as version 2.20) and timestamps conversion (in versions too), booleans are all # loaded as plain strings. # This avoid unwanted type conversions for unquoted strings and the resulting # content damaging. This overrides the implicit resolvers. Callers must handle # type conversion explicitly from unicode to other types in the loaded objects. BaseSaneLoader.add_constructor('tag:yaml.org,2002:str', BaseSaneLoader.string_loader) BaseSaneLoader.add_constructor('tag:yaml.org,2002:null', BaseSaneLoader.string_loader) BaseSaneLoader.add_constructor('tag:yaml.org,2002:boolean', BaseSaneLoader.string_loader) BaseSaneLoader.add_constructor('tag:yaml.org,2002:timestamp', BaseSaneLoader.string_loader) BaseSaneLoader.add_constructor('tag:yaml.org,2002:float', BaseSaneLoader.string_loader) BaseSaneLoader.add_constructor('tag:yaml.org,2002:int', BaseSaneLoader.string_loader) BaseSaneLoader.add_constructor('tag:yaml.org,2002:null', BaseSaneLoader.string_loader) # Fall back to mapping for anything else, e.g. ignore tags such as # !!Python, ruby and other dangerous mappings: treat them as a mapping BaseSaneLoader.add_constructor(None, BaseSaneLoader.ordered_loader) class SaneLoader(BaseSaneLoader): pass # Always load mapping as ordered mappings SaneLoader.add_constructor('tag:yaml.org,2002:map', BaseSaneLoader.ordered_loader) SaneLoader.add_constructor('tag:yaml.org,2002:omap', BaseSaneLoader.ordered_loader) class DupeKeySaneLoader(BaseSaneLoader): """ A variant that check that maps do not contain duplicate keys. Raise DuplicateYamlMappingKeyError on duplicate. """ pass # Always load mapping as ordered mappings dupe_checkding_ordered_loader = partial(BaseSaneLoader.ordered_loader, check_dupe=True) DupeKeySaneLoader.add_constructor('tag:yaml.org,2002:map', dupe_checkding_ordered_loader) DupeKeySaneLoader.add_constructor('tag:yaml.org,2002:omap', dupe_checkding_ordered_loader) ############################################################################### # Dumping ############################################################################### def dump(obj, indent=2, encoding=None): """ Return a safe and sane YAML string representation from `obj`. This is a unicode string if `encoding` is None. Otherwise this is a byte string using the provided encoding. The preferred encoding should be UTF-8 for bytes. """ return yaml.dump( data=obj, Dumper=SaneDumper, # no flow, only block and minimal styling default_flow_style=False, default_style=None, # this would include the type tags if True canonical=False, # all unicode allow_unicode=True, encoding=encoding, # anything above 2 will yield weird vertical indents on lists and maps indent=indent, # make this 80ish width=90, # posix LF line_break='\n', # no --- and ... explicit_start=False, explicit_end=False, ) class IndentingEmitter(Emitter): def increase_indent(self, flow=False, indentless=False): """ Ensure that lists items are always indented. """ return super(IndentingEmitter, self).increase_indent( flow=False, indentless=False) class SaneDumper(IndentingEmitter, Serializer, SafeRepresenter, Resolver): def __init__(self, stream, default_style=None, default_flow_style=None, canonical=None, indent=None, width=None, allow_unicode=None, line_break=None, encoding=None, explicit_start=None, explicit_end=None, version=None, tags=None): IndentingEmitter.__init__(self, stream, canonical=canonical, indent=indent, width=width, allow_unicode=allow_unicode, line_break=line_break) Serializer.__init__(self, encoding=encoding, explicit_start=explicit_start, explicit_end=explicit_end, version=version, tags=tags) SafeRepresenter.__init__(self, default_style=default_style, default_flow_style=default_flow_style) Resolver.__init__(self) def determine_block_hints(self, text): """ Avoid extra hint in blocks such as `|-` for literals. """ return '' def ignore_aliases(self, data): """ Avoid having aliases created from re-used Python objects or else. """ return True def ordered_dumper(self, data): """ Ensure that maps are always dumped in the items order. """ return self.represent_mapping('tag:yaml.org,2002:map', data.items(), flow_style=False) def null_dumper(self, value): # NOQA """ Always dump nulls as empty string. """ return self.represent_scalar('tag:yaml.org,2002:null', '') def string_dumper(self, value): """ Ensure that all scalars are dumped as UTF-8 unicode, folded and quoted in the sanest and most readable way. """ tag = 'tag:yaml.org,2002:str' style = None if isinstance(value, float): style = "'" if isinstance(value, bytes): value = value.decode('utf-8') elif not isinstance(value, unicode): value = repr(value) # do not quote integer strings if value.isdigit() and unicode(int(value)) == value: style = None tag = 'tag:yaml.org,2002:int' if '\n' in value: # literal_style for multilines style = '|' return self.represent_scalar(tag, value, style=style) def boolean_dumper(self, value): """ Dump booleans as yes or no strings. They will be loaded back as boolean by default alright. """ value = 'yes' if value else 'no' return self.represent_scalar('tag:yaml.org,2002:bool', value, style=None) SaneDumper.add_representer(int, SaneDumper.string_dumper) SaneDumper.add_representer(odict, SaneDumper.ordered_dumper) SaneDumper.add_representer(OrderedDict, SaneDumper.ordered_dumper) SaneDumper.add_representer(type(None), SaneDumper.null_dumper) SaneDumper.add_representer(bool, SaneDumper.boolean_dumper) SaneDumper.add_representer(bytes, SaneDumper.string_dumper) SaneDumper.add_representer(str, SaneDumper.string_dumper) SaneDumper.add_representer(unicode, SaneDumper.string_dumper) SaneDumper.add_representer(float, SaneDumper.string_dumper) python-saneyaml_0.3.orig/tests/data/0000755000000000000000000000000013211267161014526 5ustar00python-saneyaml_0.3.orig/tests/test_saneyaml.py0000644000000000000000000001562313374544111017051 0ustar00#!/usr/bin/env python # -*- coding: utf8 -*- # # Copyright (c) 2018 nexB Inc. and others. All rights reserved. # http://nexb.com and https://github.com/nexB/saneyaml/ # # Licensed 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 at # http://www.apache.org/licenses/LICENSE-2.0 # Unless 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. from __future__ import absolute_import from __future__ import print_function from __future__ import unicode_literals from collections import OrderedDict import io import json import os import re from unittest.case import TestCase import saneyaml try: unicode except NameError: unicode = str # NOQA test_data_dir = os.path.join(os.path.dirname(__file__), 'data') def get_test_loc(test_path, exists=True, test_data_dir=test_data_dir): """ Given a `test_path` relative to the `test_data_dir` directory, return the location to a test file or directory for this path. """ if not os.path.exists(test_data_dir): raise IOError( "[Errno 2] No such directory: test_data_dir not found:" " '%(test_data_dir)s'" % locals()) test_loc = os.path.abspath(os.path.join(test_data_dir, test_path)) if exists and not os.path.exists(test_loc): raise IOError( "[Errno 2] No such file or directory: test_path not found: " "'%(test_loc)s'" % locals()) return test_loc class TestSaneyaml(TestCase): def test_load_with_and_without_ruby_tags(self): test_file_with_tag = get_test_loc('ruby_tags/metadata1') test_file_without_tag = get_test_loc('ruby_tags/metadata1.notag') with_tags = saneyaml.load(open(test_file_with_tag, 'rb').read()) without_tags = saneyaml.load(open(test_file_without_tag, 'rb').read()) assert with_tags == without_tags def test_load_optionally_raise_exception_on_dupe(self): test = ''' a: 12 b: 23 a: 45 ''' try: saneyaml.load(test, allow_duplicate_keys=False) self.fail('Exception not raised') except saneyaml.UnsupportedYamlFeatureError as e: assert 'Duplicate key in YAML source: a' == str(e) def test_load_optionally_raise_exception_on_dupe_in_nested_mappings(self): test = ''' 2: 3: 4 4: 5 5: 6: 9 8: 9 6: 8 ''' try: saneyaml.load(test, allow_duplicate_keys=False) self.fail('Exception not raised') except saneyaml.UnsupportedYamlFeatureError: pass def test_load_does_not_raise_exception_on_dupe_by_default(self): test = ''' a: 12 b: 23 a: 45 ''' saneyaml.load(test) def test_dump_does_handles_numbers_and_booleans_correctly(self): test = [ None, OrderedDict([ (1, None), (123.34, 'tha') ]) ] expected = ( "-\n" "- 1:\n" " '123.34': tha\n") assert expected == saneyaml.dump(test) def test_dump_increases_indents_correctly(self): test = { 'a': [ 1, [ 2, 3, [ 4, 5 ] ] ] } expected = 'a:\n - 1\n - - 2\n - 3\n - - 4\n - 5\n' assert expected == saneyaml.dump(test) def test_dump_converts_bytes_to_unicode_correctly(self): test = {b'a': b'foo'} expected = 'a: foo\n' assert expected == saneyaml.dump(test) def test_load_ignore_aliases(self): test = ''' x: !!int 5 &environ: - this - null - 2012-03-12 that: *environ ''' result = saneyaml.load(test) expected = OrderedDict([ ('x', '5'), ('', ['this', 'null', '2012-03-12']), ('that', '') ]) assert expected == result safe_chars = re.compile(r'[\W_]', re.MULTILINE) def python_safe(s, python2=False): """Return a name safe to use as a python function name""" s = s.strip().lower() s = [x for x in safe_chars.split(s) if x] s = '_'.join(s) if saneyaml.python2: s = s.encode('utf-8') return s def get_yaml_test_method(test_file, expected_load_file, expected_dump_file, regen=False): """ Build and return a test function closing on tests arguments and the function name. """ def closure_test_function(self): with io.open(test_file, encoding='utf-8') as inp: test_load = saneyaml.load(inp.read()) test_dump = saneyaml.dump(test_load) if regen: with io.open(expected_load_file, 'w', encoding='utf-8') as out: json.dump(test_load, out, indent=2) with io.open(expected_dump_file, 'w', encoding='utf-8') as out: out.write(test_dump) with io.open(expected_load_file, encoding='utf-8') as inp: expected_load = json.load(inp, object_pairs_hook=OrderedDict) with io.open(expected_dump_file, encoding='utf-8') as inp: expected_dump = inp.read() assert expected_load == test_load assert expected_dump == test_dump tfn = test_file.replace(test_data_dir, '').strip('/\\') test_name = 'test_{}'.format(tfn) test_name = python_safe(test_name) closure_test_function.__name__ = test_name closure_test_function.funcname = test_name return closure_test_function, test_name def build_tests(cls, test_subdir='yamls', test_data_dir=test_data_dir, regen=False): """ Dynamically build test methods from a YAML test files and expected JSON files. Attach these methods to the cls test class. Collect tests from test and expected files in `test_data_dir/test_subdir`. """ for top, _, files in os.walk(os.path.join(test_data_dir, test_subdir)): for yfile in files: if yfile.endswith('.yml'): test_file = os.path.abspath(os.path.join(top, yfile)) expected_load_file = test_file + '.expected.load.json' expected_dump_file = test_file + '.expected.yaml.dump' method, name = get_yaml_test_method( test_file, expected_load_file, expected_dump_file, regen) # attach that method to our test class setattr(cls, name, method) class TestDataDriven(TestCase): """ This test case consist of loading and dumping several YAML files and check the results using data files. """ # test functions are attached to this class at module import time pass build_tests(cls=TestDataDriven, test_subdir='yamls', regen=False) python-saneyaml_0.3.orig/tests/data/ruby_tags/0000755000000000000000000000000013374544111016530 5ustar00python-saneyaml_0.3.orig/tests/data/yamls/0000755000000000000000000000000013374544111015656 5ustar00python-saneyaml_0.3.orig/tests/data/ruby_tags/metadata10000644000000000000000000000344513374544111020322 0ustar00--- !ruby/object:Gem::Specification name: blankslate version: !ruby/object:Gem::Version version: 3.1.3 platform: ruby authors: - Jim Weirich - David Masover - Jack Danger Canty autorequire: bindir: bin cert_chain: [] date: 2014-06-18 00:00:00.000000000 Z dependencies: - !ruby/object:Gem::Dependency name: rspec requirement: !ruby/object:Gem::Requirement requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' type: :development prerelease: false version_requirements: !ruby/object:Gem::Requirement requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' - !ruby/object:Gem::Dependency name: bundler requirement: !ruby/object:Gem::Requirement requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' type: :development prerelease: false version_requirements: !ruby/object:Gem::Requirement requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' description: email: rubygems@6brand.com executables: [] extensions: [] extra_rdoc_files: [] files: - Gemfile - Gemfile.lock - MIT-LICENSE - README - Rakefile - VERSION - blankslate.gemspec - lib/blankslate.rb - spec/blankslate_spec.rb homepage: http://github.com/masover/blankslate licenses: [] metadata: {} post_install_message: rdoc_options: [] require_paths: - lib required_ruby_version: !ruby/object:Gem::Requirement requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' required_rubygems_version: !ruby/object:Gem::Requirement requirements: - - ! '>=' - !ruby/object:Gem::Version version: '0' requirements: [] rubyforge_project: rubygems_version: 2.2.2 signing_key: specification_version: 4 summary: BlankSlate extracted from Builder. test_files: - spec/blankslate_spec.rb has_rdoc: python-saneyaml_0.3.orig/tests/data/ruby_tags/metadata1.notag0000644000000000000000000000256113374544111021427 0ustar00--- name: blankslate version: version: 3.1.3 platform: ruby authors: - Jim Weirich - David Masover - Jack Danger Canty autorequire: bindir: bin cert_chain: [] date: 2014-06-18 00:00:00.000000000 Z dependencies: - name: rspec requirement: requirements: - - ! '>=' - version: '0' type: :development prerelease: false version_requirements: requirements: - - ! '>=' - version: '0' - name: bundler requirement: requirements: - - ! '>=' - version: '0' type: :development prerelease: false version_requirements: requirements: - - ! '>=' - version: '0' description: email: rubygems@6brand.com executables: [] extensions: [] extra_rdoc_files: [] files: - Gemfile - Gemfile.lock - MIT-LICENSE - README - Rakefile - VERSION - blankslate.gemspec - lib/blankslate.rb - spec/blankslate_spec.rb homepage: http://github.com/masover/blankslate licenses: [] metadata: {} post_install_message: rdoc_options: [] require_paths: - lib required_ruby_version: requirements: - - ! '>=' - version: '0' required_rubygems_version: requirements: - - ! '>=' - version: '0' requirements: [] rubyforge_project: rubygems_version: 2.2.2 signing_key: specification_version: 4 summary: BlankSlate extracted from Builder. test_files: - spec/blankslate_spec.rb has_rdoc: python-saneyaml_0.3.orig/tests/data/yamls/about.yml0000644000000000000000000000135513374544111017517 0ustar00about_resource: . name: AboutCode-toolkit about_resource_path: . version: 3.0.0.dev6 owner: nexB Inc. author: Jillian Daguil, Chin Yeung Li, Philippe Ombredanne, Thomas Druez description: | AboutCode Toolkit is a tool to process ABOUT files. An ABOUT file provides a simple way to document the provenance (origin and license) 'about' a software component. This is a small text file stored in the codebase side-by-side with the documented software component. homepage_url: http://www.nexb.com/community.html license: apache-2.0 license_name: Apache 2.0 license_file: apache-2.0.LICENSE copyright: Copyright (c) 2013-2017 nexB Inc. notice_file: NOTICE vcs_tool: git vcs_repository: https://github.com/nexB/aboutcode-toolkit.git python-saneyaml_0.3.orig/tests/data/yamls/about.yml.expected.load.json0000644000000000000000000000150413374544111023201 0ustar00{ "about_resource": ".", "name": "AboutCode-toolkit", "about_resource_path": ".", "version": "3.0.0.dev6", "owner": "nexB Inc.", "author": "Jillian Daguil, Chin Yeung Li, Philippe Ombredanne, Thomas Druez", "description": "AboutCode Toolkit is a tool to process ABOUT files. An ABOUT file\nprovides a simple way to document the provenance (origin and license)\n'about' a software component. This is a small text file stored in the\ncodebase side-by-side with the documented software component.\n", "homepage_url": "http://www.nexb.com/community.html", "license": "apache-2.0", "license_name": "Apache 2.0", "license_file": "apache-2.0.LICENSE", "copyright": "Copyright (c) 2013-2017 nexB Inc.", "notice_file": "NOTICE", "vcs_tool": "git", "vcs_repository": "https://github.com/nexB/aboutcode-toolkit.git" }python-saneyaml_0.3.orig/tests/data/yamls/about.yml.expected.yaml.dump0000644000000000000000000000133613374544111023223 0ustar00about_resource: . name: AboutCode-toolkit about_resource_path: . version: 3.0.0.dev6 owner: nexB Inc. author: Jillian Daguil, Chin Yeung Li, Philippe Ombredanne, Thomas Druez description: | AboutCode Toolkit is a tool to process ABOUT files. An ABOUT file provides a simple way to document the provenance (origin and license) 'about' a software component. This is a small text file stored in the codebase side-by-side with the documented software component. homepage_url: http://www.nexb.com/community.html license: apache-2.0 license_name: Apache 2.0 license_file: apache-2.0.LICENSE copyright: Copyright (c) 2013-2017 nexB Inc. notice_file: NOTICE vcs_tool: git vcs_repository: https://github.com/nexB/aboutcode-toolkit.git python-saneyaml_0.3.orig/tests/data/yamls/afpl-8.0.yml0000644000000000000000000000011613374544111017624 0ustar00license_expression: afpl-8.0 is_license_text: yes notes: Aladin FPL v8, short python-saneyaml_0.3.orig/tests/data/yamls/afpl-8.0.yml.expected.load.json0000644000000000000000000000014413374544111023313 0ustar00{ "license_expression": "afpl-8.0", "is_license_text": true, "notes": "Aladin FPL v8, short" }python-saneyaml_0.3.orig/tests/data/yamls/afpl-8.0.yml.expected.yaml.dump0000644000000000000000000000011613374544111023331 0ustar00license_expression: afpl-8.0 is_license_text: yes notes: Aladin FPL v8, short python-saneyaml_0.3.orig/tests/data/yamls/artistic-2.0_or_later_or_gpl-2.0.yml0000644000000000000000000000034413374544111024247 0ustar00license_expression: artistic-2.0 OR gpl-2.0 is_license_notice: yes notes: technically the license is artistic-2.0 or any later version of that licenses as used in Perl 5. This is a rare notice so we only report artistic-2.0 python-saneyaml_0.3.orig/tests/data/yamls/artistic-2.0_or_later_or_gpl-2.0.yml.expected.load.json0000644000000000000000000000036613374544111027741 0ustar00{ "license_expression": "artistic-2.0 OR gpl-2.0", "is_license_notice": true, "notes": "technically the license is artistic-2.0 or any later version of that licenses as used in Perl 5. This is a rare notice so we only report artistic-2.0" }python-saneyaml_0.3.orig/tests/data/yamls/artistic-2.0_or_later_or_gpl-2.0.yml.expected.yaml.dump0000644000000000000000000000034213374544111027752 0ustar00license_expression: artistic-2.0 OR gpl-2.0 is_license_notice: yes notes: technically the license is artistic-2.0 or any later version of that licenses as used in Perl 5. This is a rare notice so we only report artistic-2.0 python-saneyaml_0.3.orig/tests/data/yamls/autoconf-exception-3.0.yml0000644000000000000000000000573113374544111022517 0ustar00key: autoconf-exception-3.0 short_name: Autoconf exception to GPL 3.0 name: Autoconf exception to GPL 3.0 category: Copyleft Limited owner: Free Software Foundation (FSF) homepage_url: http://www.gnu.org/licenses/autoconf-exception-3.0.html is_exception: yes spdx_license_key: Autoconf-exception-3.0 text_urls: - http://www.gnu.org/licenses/autoconf-exception-3.0.html other_urls: - http://www.gnu.org/licenses/gpl-3.0.txt standard_notice: |- This program is free software: you can redistribute it and/or modify it under the terms of the GNU 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 General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . AUTOCONF CONFIGURE SCRIPT EXCEPTION Version 3.0, 18 August 2009 Copyright © 2009 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. This Exception is an additional permission under section 7 of the GNU General Public License, version 3 ("GPLv3"). It applies to a given file that bears a notice placed by the copyright holder of the file stating that the file is governed by GPLv3 along with this Exception. The purpose of this Exception is to allow distribution of Autoconf's typical output under terms of the recipient's choice (including proprietary). 0. Definitions. "Covered Code" is the source or object code of a version of Autoconf that is a covered work under this License. "Normally Copied Code" for a version of Autoconf means all parts of its Covered Code which that version can copy from its code (i.e., not from its input file) into its minimally verbose, non-debugging and non-tracing output. "Ineligible Code" is Covered Code that is not Normally Copied Code. 1. Grant of Additional Permission. You have permission to propagate output of Autoconf, even if such propagation would otherwise violate the terms of GPLv3. However, if by modifying Autoconf you cause any Ineligible Code of the version you received to become Normally Copied Code of your modified version, then you void this Exception for the resulting covered work. If you convey that resulting covered work, you must remove this Exception in accordance with the second paragraph of Section 7 of GPLv3. 2. No Weakening of Autoconf Copyleft. The availability of this Exception does not imply any general presumption that third-party software is unaffected by the copyleft requirements of the license of Autoconf. python-saneyaml_0.3.orig/tests/data/yamls/autoconf-exception-3.0.yml.expected.load.json0000644000000000000000000000567113374544111026210 0ustar00{ "key": "autoconf-exception-3.0", "short_name": "Autoconf exception to GPL 3.0", "name": "Autoconf exception to GPL 3.0", "category": "Copyleft Limited", "owner": "Free Software Foundation (FSF)", "homepage_url": "http://www.gnu.org/licenses/autoconf-exception-3.0.html", "is_exception": true, "spdx_license_key": "Autoconf-exception-3.0", "text_urls": [ "http://www.gnu.org/licenses/autoconf-exception-3.0.html" ], "other_urls": [ "http://www.gnu.org/licenses/gpl-3.0.txt" ], "standard_notice": "This program is free software: you can redistribute it and/or modify it\nunder the terms of the GNU General Public License as published by the Free\nSoftware Foundation, either version 3 of the License, or (at your option)\nany later version.\nThis program is distributed in the hope that it will be useful, but WITHOUT\nANY WARRANTY; without even the implied warranty of MERCHANTABILITY or\nFITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for\nmore details.\nYou should have received a copy of the GNU General Public License along\nwith this program. If not, see .\nAUTOCONF CONFIGURE SCRIPT EXCEPTION\nVersion 3.0, 18 August 2009\nCopyright \u00a9 2009 Free Software Foundation, Inc. \nEveryone is permitted to copy and distribute verbatim copies of this\nlicense document, but changing it is not allowed.\nThis Exception is an additional permission under section 7 of the GNU\nGeneral Public License, version 3 (\"GPLv3\"). It applies to a given file\nthat bears a notice placed by the copyright holder of the file stating that\nthe file is governed by GPLv3 along with this Exception.\nThe purpose of this Exception is to allow distribution of Autoconf's\ntypical output under terms of the recipient's choice (including\nproprietary).\n0. Definitions.\n\"Covered Code\" is the source or object code of a version of Autoconf that\nis a covered work under this License.\n\"Normally Copied Code\" for a version of Autoconf means all parts of its\nCovered Code which that version can copy from its code (i.e., not from its\ninput file) into its minimally verbose, non-debugging and non-tracing\noutput.\n\"Ineligible Code\" is Covered Code that is not Normally Copied Code.\n1. Grant of Additional Permission.\nYou have permission to propagate output of Autoconf, even if such\npropagation would otherwise violate the terms of GPLv3. However, if by\nmodifying Autoconf you cause any Ineligible Code of the version you\nreceived to become Normally Copied Code of your modified version, then you\nvoid this Exception for the resulting covered work. If you convey that\nresulting covered work, you must remove this Exception in accordance with\nthe second paragraph of Section 7 of GPLv3.\n2. No Weakening of Autoconf Copyleft.\nThe availability of this Exception does not imply any general presumption\nthat third-party software is unaffected by the copyleft requirements of the\nlicense of Autoconf." }python-saneyaml_0.3.orig/tests/data/yamls/autoconf-exception-3.0.yml.expected.yaml.dump0000644000000000000000000000560013374544111026217 0ustar00key: autoconf-exception-3.0 short_name: Autoconf exception to GPL 3.0 name: Autoconf exception to GPL 3.0 category: Copyleft Limited owner: Free Software Foundation (FSF) homepage_url: http://www.gnu.org/licenses/autoconf-exception-3.0.html is_exception: yes spdx_license_key: Autoconf-exception-3.0 text_urls: - http://www.gnu.org/licenses/autoconf-exception-3.0.html other_urls: - http://www.gnu.org/licenses/gpl-3.0.txt standard_notice: | This program is free software: you can redistribute it and/or modify it under the terms of the GNU 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 General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . AUTOCONF CONFIGURE SCRIPT EXCEPTION Version 3.0, 18 August 2009 Copyright © 2009 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. This Exception is an additional permission under section 7 of the GNU General Public License, version 3 ("GPLv3"). It applies to a given file that bears a notice placed by the copyright holder of the file stating that the file is governed by GPLv3 along with this Exception. The purpose of this Exception is to allow distribution of Autoconf's typical output under terms of the recipient's choice (including proprietary). 0. Definitions. "Covered Code" is the source or object code of a version of Autoconf that is a covered work under this License. "Normally Copied Code" for a version of Autoconf means all parts of its Covered Code which that version can copy from its code (i.e., not from its input file) into its minimally verbose, non-debugging and non-tracing output. "Ineligible Code" is Covered Code that is not Normally Copied Code. 1. Grant of Additional Permission. You have permission to propagate output of Autoconf, even if such propagation would otherwise violate the terms of GPLv3. However, if by modifying Autoconf you cause any Ineligible Code of the version you received to become Normally Copied Code of your modified version, then you void this Exception for the resulting covered work. If you convey that resulting covered work, you must remove this Exception in accordance with the second paragraph of Section 7 of GPLv3. 2. No Weakening of Autoconf Copyleft. The availability of this Exception does not imply any general presumption that third-party software is unaffected by the copyleft requirements of the license of Autoconf. python-saneyaml_0.3.orig/tests/data/yamls/contextlib2.yml0000644000000000000000000000076013374544111020641 0ustar00about_resource: contextlib2-0.5.5-py2.py3-none-any.whl version: 0.5.5 download_url: https://pypi.python.org/packages/a2/71/8273a7eeed0aff6a854237ab5453bc9aa67deb49df4832801c21f0ff3782/contextlib2-0.5.5-py2.py3-none-any.whl name: contextlib2 home_url: https://github.com/ncoghlan/contextlib2 owner: Nick Goghlan license_expression: python license_file: contextlib2.LICENSE copyright: Copyright (c) Python contributors vcs_tool: git vcs_repository: https://github.com/ncoghlan/contextlib2.git python-saneyaml_0.3.orig/tests/data/yamls/contextlib2.yml.expected.load.json0000644000000000000000000000107213374544111024324 0ustar00{ "about_resource": "contextlib2-0.5.5-py2.py3-none-any.whl", "version": "0.5.5", "download_url": "https://pypi.python.org/packages/a2/71/8273a7eeed0aff6a854237ab5453bc9aa67deb49df4832801c21f0ff3782/contextlib2-0.5.5-py2.py3-none-any.whl", "name": "contextlib2", "home_url": "https://github.com/ncoghlan/contextlib2", "owner": "Nick Goghlan", "license_expression": "python", "license_file": "contextlib2.LICENSE", "copyright": "Copyright (c) Python contributors", "vcs_tool": "git", "vcs_repository": "https://github.com/ncoghlan/contextlib2.git" }python-saneyaml_0.3.orig/tests/data/yamls/contextlib2.yml.expected.yaml.dump0000644000000000000000000000075313374544111024350 0ustar00about_resource: contextlib2-0.5.5-py2.py3-none-any.whl version: 0.5.5 download_url: https://pypi.python.org/packages/a2/71/8273a7eeed0aff6a854237ab5453bc9aa67deb49df4832801c21f0ff3782/contextlib2-0.5.5-py2.py3-none-any.whl name: contextlib2 home_url: https://github.com/ncoghlan/contextlib2 owner: Nick Goghlan license_expression: python license_file: contextlib2.LICENSE copyright: Copyright (c) Python contributors vcs_tool: git vcs_repository: https://github.com/ncoghlan/contextlib2.git python-saneyaml_0.3.orig/tests/data/yamls/copyright_test.yml0000644000000000000000000000717713374544111021464 0ustar00what: - copyrights - holders - holders_summary copyrights: - copyright Steinar H. Gunderson and Knut Auvor Grythe - Copyright (c) 1996-1997 Cisco Systems, Inc. - Copyright (c) Ian F. Darwin, 1987. - Copyright (c) Ian F. Darwin 1986, 1987, 1989, 1990, 1991, 1992, 1994, 1995. - copyright 1992 by Eric Haines, erich@eye.com - Copyright (c) 1995, Board of Trustees of the University of Illinois - Copyright (c) 1994, Jeff Hostetler, Spyglass, Inc. - Copyright (c) 1993, 1994 by Carnegie Mellon University - Copyright (c) 1991 Bell Communications Research, Inc. - (c) Copyright 1993,1994 by Carnegie Mellon University - Copyright (c) 1991 Bell Communications Research, Inc. - Copyright RSA Data Security, Inc. - Copyright (c) 1991-2, RSA Data Security, Inc. - Copyright RSA Data Security, Inc. - Copyright (c) 1991-2, RSA Data Security, Inc. - copyright RSA Data Security, Inc. - Copyright (c) 1991-2, RSA Data Security, Inc. - copyright RSA Data Security, Inc. - Copyright (c) 1991-2, RSA Data Security, Inc. - Copyright (c) 2000-2002 The Apache Software Foundation. - copyright RSA Data Security, Inc. - Copyright (c) 1990-2, RSA Data Security, Inc. - Copyright 1991 by the Massachusetts Institute of Technology - Copyright 1991 by the Massachusetts Institute of Technology - Copyright (c) 1997-2001 University of Cambridge - copyright by the University of Cambridge, England. - Copyright (c) Zeus Technology Limited 1996. - Copyright (c) 1998, 1999, 2000 Thai Open Source Software Center Ltd and Clark Cooper - copyright of Pete Harlow holders: - Steinar H. Gunderson and Knut Auvor Grythe - Cisco Systems, Inc. - Ian F. Darwin - Ian F. Darwin - Eric Haines - Board of Trustees of the University of Illinois - Jeff Hostetler, Spyglass, Inc. - Carnegie Mellon University - Bell Communications Research, Inc. - Carnegie Mellon University - Bell Communications Research, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - The Apache Software Foundation. - RSA Data Security, Inc. - RSA Data Security, Inc. - the Massachusetts Institute of Technology - the Massachusetts Institute of Technology - University of Cambridge - the University of Cambridge, England. - Zeus Technology Limited - Thai Open Source Software Center Ltd and Clark Cooper - Pete Harlow holders_summary: - value: RSA Data Security, Inc. count: 10 - value: Bell Communications Research, Inc. count: 2 - value: Carnegie Mellon University count: 2 - value: Ian F. Darwin count: 2 - value: the Massachusetts Institute of Technology count: 2 - value: Board of Trustees of the University of Illinois count: 1 - value: Cisco Systems, Inc. count: 1 - value: Eric Haines count: 1 - value: Jeff Hostetler, Spyglass, Inc. count: 1 - value: Pete Harlow count: 1 - value: Steinar H. Gunderson and Knut Auvor Grythe count: 1 - value: Thai Open Source Software Center Ltd and Clark Cooper count: 1 - value: The Apache Software Foundation. count: 1 - value: University of Cambridge count: 1 - value: Zeus Technology Limited count: 1 - value: the University of Cambridge, England. count: 1 python-saneyaml_0.3.orig/tests/data/yamls/copyright_test.yml.expected.load.json0000644000000000000000000001000613374544111025133 0ustar00{ "what": [ "copyrights", "holders", "holders_summary" ], "copyrights": [ "copyright Steinar H. Gunderson and Knut Auvor Grythe ", "Copyright (c) 1996-1997 Cisco Systems, Inc.", "Copyright (c) Ian F. Darwin, 1987.", "Copyright (c) Ian F. Darwin 1986, 1987, 1989, 1990, 1991, 1992, 1994, 1995.", "copyright 1992 by Eric Haines, erich@eye.com", "Copyright (c) 1995, Board of Trustees of the University of Illinois", "Copyright (c) 1994, Jeff Hostetler, Spyglass, Inc.", "Copyright (c) 1993, 1994 by Carnegie Mellon University", "Copyright (c) 1991 Bell Communications Research, Inc.", "(c) Copyright 1993,1994 by Carnegie Mellon University", "Copyright (c) 1991 Bell Communications Research, Inc.", "Copyright RSA Data Security, Inc.", "Copyright (c) 1991-2, RSA Data Security, Inc.", "Copyright RSA Data Security, Inc.", "Copyright (c) 1991-2, RSA Data Security, Inc.", "copyright RSA Data Security, Inc.", "Copyright (c) 1991-2, RSA Data Security, Inc.", "copyright RSA Data Security, Inc.", "Copyright (c) 1991-2, RSA Data Security, Inc.", "Copyright (c) 2000-2002 The Apache Software Foundation.", "copyright RSA Data Security, Inc.", "Copyright (c) 1990-2, RSA Data Security, Inc.", "Copyright 1991 by the Massachusetts Institute of Technology", "Copyright 1991 by the Massachusetts Institute of Technology", "Copyright (c) 1997-2001 University of Cambridge", "copyright by the University of Cambridge, England.", "Copyright (c) Zeus Technology Limited 1996.", "Copyright (c) 1998, 1999, 2000 Thai Open Source Software Center Ltd and Clark Cooper", "copyright of Pete Harlow" ], "holders": [ "Steinar H. Gunderson and Knut Auvor Grythe", "Cisco Systems, Inc.", "Ian F. Darwin", "Ian F. Darwin", "Eric Haines", "Board of Trustees of the University of Illinois", "Jeff Hostetler, Spyglass, Inc.", "Carnegie Mellon University", "Bell Communications Research, Inc.", "Carnegie Mellon University", "Bell Communications Research, Inc.", "RSA Data Security, Inc.", "RSA Data Security, Inc.", "RSA Data Security, Inc.", "RSA Data Security, Inc.", "RSA Data Security, Inc.", "RSA Data Security, Inc.", "RSA Data Security, Inc.", "RSA Data Security, Inc.", "The Apache Software Foundation.", "RSA Data Security, Inc.", "RSA Data Security, Inc.", "the Massachusetts Institute of Technology", "the Massachusetts Institute of Technology", "University of Cambridge", "the University of Cambridge, England.", "Zeus Technology Limited", "Thai Open Source Software Center Ltd and Clark Cooper", "Pete Harlow" ], "holders_summary": [ { "value": "RSA Data Security, Inc.", "count": "10" }, { "value": "Bell Communications Research, Inc.", "count": "2" }, { "value": "Carnegie Mellon University", "count": "2" }, { "value": "Ian F. Darwin", "count": "2" }, { "value": "the Massachusetts Institute of Technology", "count": "2" }, { "value": "Board of Trustees of the University of Illinois", "count": "1" }, { "value": "Cisco Systems, Inc.", "count": "1" }, { "value": "Eric Haines", "count": "1" }, { "value": "Jeff Hostetler, Spyglass, Inc.", "count": "1" }, { "value": "Pete Harlow", "count": "1" }, { "value": "Steinar H. Gunderson and Knut Auvor Grythe", "count": "1" }, { "value": "Thai Open Source Software Center Ltd and Clark Cooper", "count": "1" }, { "value": "The Apache Software Foundation.", "count": "1" }, { "value": "University of Cambridge", "count": "1" }, { "value": "Zeus Technology Limited", "count": "1" }, { "value": "the University of Cambridge, England.", "count": "1" } ] }python-saneyaml_0.3.orig/tests/data/yamls/copyright_test.yml.expected.yaml.dump0000644000000000000000000000660513374544111025164 0ustar00what: - copyrights - holders - holders_summary copyrights: - copyright Steinar H. Gunderson and Knut Auvor Grythe - Copyright (c) 1996-1997 Cisco Systems, Inc. - Copyright (c) Ian F. Darwin, 1987. - Copyright (c) Ian F. Darwin 1986, 1987, 1989, 1990, 1991, 1992, 1994, 1995. - copyright 1992 by Eric Haines, erich@eye.com - Copyright (c) 1995, Board of Trustees of the University of Illinois - Copyright (c) 1994, Jeff Hostetler, Spyglass, Inc. - Copyright (c) 1993, 1994 by Carnegie Mellon University - Copyright (c) 1991 Bell Communications Research, Inc. - (c) Copyright 1993,1994 by Carnegie Mellon University - Copyright (c) 1991 Bell Communications Research, Inc. - Copyright RSA Data Security, Inc. - Copyright (c) 1991-2, RSA Data Security, Inc. - Copyright RSA Data Security, Inc. - Copyright (c) 1991-2, RSA Data Security, Inc. - copyright RSA Data Security, Inc. - Copyright (c) 1991-2, RSA Data Security, Inc. - copyright RSA Data Security, Inc. - Copyright (c) 1991-2, RSA Data Security, Inc. - Copyright (c) 2000-2002 The Apache Software Foundation. - copyright RSA Data Security, Inc. - Copyright (c) 1990-2, RSA Data Security, Inc. - Copyright 1991 by the Massachusetts Institute of Technology - Copyright 1991 by the Massachusetts Institute of Technology - Copyright (c) 1997-2001 University of Cambridge - copyright by the University of Cambridge, England. - Copyright (c) Zeus Technology Limited 1996. - Copyright (c) 1998, 1999, 2000 Thai Open Source Software Center Ltd and Clark Cooper - copyright of Pete Harlow holders: - Steinar H. Gunderson and Knut Auvor Grythe - Cisco Systems, Inc. - Ian F. Darwin - Ian F. Darwin - Eric Haines - Board of Trustees of the University of Illinois - Jeff Hostetler, Spyglass, Inc. - Carnegie Mellon University - Bell Communications Research, Inc. - Carnegie Mellon University - Bell Communications Research, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - RSA Data Security, Inc. - The Apache Software Foundation. - RSA Data Security, Inc. - RSA Data Security, Inc. - the Massachusetts Institute of Technology - the Massachusetts Institute of Technology - University of Cambridge - the University of Cambridge, England. - Zeus Technology Limited - Thai Open Source Software Center Ltd and Clark Cooper - Pete Harlow holders_summary: - value: RSA Data Security, Inc. count: 10 - value: Bell Communications Research, Inc. count: 2 - value: Carnegie Mellon University count: 2 - value: Ian F. Darwin count: 2 - value: the Massachusetts Institute of Technology count: 2 - value: Board of Trustees of the University of Illinois count: 1 - value: Cisco Systems, Inc. count: 1 - value: Eric Haines count: 1 - value: Jeff Hostetler, Spyglass, Inc. count: 1 - value: Pete Harlow count: 1 - value: Steinar H. Gunderson and Knut Auvor Grythe count: 1 - value: Thai Open Source Software Center Ltd and Clark Cooper count: 1 - value: The Apache Software Foundation. count: 1 - value: University of Cambridge count: 1 - value: Zeus Technology Limited count: 1 - value: the University of Cambridge, England. count: 1 python-saneyaml_0.3.orig/tests/data/yamls/corner-cases.yml0000644000000000000000000000017413374544111020767 0ustar00about_resource: null name: 123.34 about_resource_path: 012 &environ: - this - null - 2012-03-12 that: *environ python-saneyaml_0.3.orig/tests/data/yamls/corner-cases.yml.expected.load.json0000644000000000000000000000022613374544111024453 0ustar00{ "about_resource": "null", "name": "123.34", "about_resource_path": "012", "": [ "this", "null", "2012-03-12" ], "that": "" }python-saneyaml_0.3.orig/tests/data/yamls/corner-cases.yml.expected.yaml.dump0000644000000000000000000000016413374544111024473 0ustar00about_resource: 'null' name: '123.34' about_resource_path: '012' ? '' : - this - 'null' - '2012-03-12' that: '' python-saneyaml_0.3.orig/tests/data/yamls/gpl-2.0.yml0000644000000000000000000000341513374544111017463 0ustar00key: gpl-2.0 short_name: GPL 2.0 name: GNU General Public License 2.0 category: Copyleft owner: Free Software Foundation (FSF) homepage_url: http://www.gnu.org/licenses/gpl-2.0.html notes: |- This is the last version of the GPL text as published by the FSF. This variation was published around about the time of the FSF released the GPL 3 in July 2007. http://web.archive.org/web/20070716031727/http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt It is found live here https://www.gnu.org/licenses/old-licenses/gpl-2.0.txt and here https://www.gnu.org/licenses/old-licenses/gpl-2.0.html It refers to the Franklin Street address and to the GNU Lesser General Public License everywhere both in the text and HTML formats. There are four other variations that were published over the years. You can find these in the GPL rules as gpl-2.0_100.RULE, gpl-2.0_101.RULE, gpl-2.0_102.RULE and gpl-2.0_103.RULE. Their corresponding YAML data explains their history and provides archive.org pointer to their texts. Per SPDX.org, this license was released June 1991 This license is OSI certified. spdx_license_key: GPL-2.0-only other_spdx_license_keys: - GPL-2.0 text_urls: - http://www.gnu.org/licenses/gpl-2.0.txt - http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt osi_url: http://opensource.org/licenses/gpl-license.php faq_url: http://www.gnu.org/licenses/old-licenses/gpl-2.0-faq.html other_urls: - http://creativecommons.org/choose/cc-gpl - http://creativecommons.org/images/public/cc-GPL-a.png - http://creativecommons.org/licenses/GPL/2.0/ - http://creativecommons.org/licenses/GPL/2.0/legalcode.pt - http://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html - http://www.opensource.org/licenses/GPL-2.0 python-saneyaml_0.3.orig/tests/data/yamls/gpl-2.0.yml.expected.load.json0000644000000000000000000000351613374544111023153 0ustar00{ "key": "gpl-2.0", "short_name": "GPL 2.0", "name": "GNU General Public License 2.0", "category": "Copyleft", "owner": "Free Software Foundation (FSF)", "homepage_url": "http://www.gnu.org/licenses/gpl-2.0.html", "notes": "This is the last version of the GPL text as published by the FSF. This\nvariation was published around about the time of the FSF released the GPL 3\nin July 2007.\nhttp://web.archive.org/web/20070716031727/http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt \nIt is found live here https://www.gnu.org/licenses/old-licenses/gpl-2.0.txt\nand here https://www.gnu.org/licenses/old-licenses/gpl-2.0.html \nIt refers to the Franklin Street address and to the\nGNU Lesser General Public License everywhere both in the text and HTML\nformats. There are four other variations that were published over the\nyears. You can find these in the GPL rules as gpl-2.0_100.RULE,\ngpl-2.0_101.RULE, gpl-2.0_102.RULE and gpl-2.0_103.RULE. Their\ncorresponding YAML data explains their history and provides archive.org\npointer to their texts. Per SPDX.org, this license was released June 1991\nThis license is OSI certified.", "spdx_license_key": "GPL-2.0-only", "other_spdx_license_keys": [ "GPL-2.0" ], "text_urls": [ "http://www.gnu.org/licenses/gpl-2.0.txt", "http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt" ], "osi_url": "http://opensource.org/licenses/gpl-license.php", "faq_url": "http://www.gnu.org/licenses/old-licenses/gpl-2.0-faq.html", "other_urls": [ "http://creativecommons.org/choose/cc-gpl", "http://creativecommons.org/images/public/cc-GPL-a.png", "http://creativecommons.org/licenses/GPL/2.0/", "http://creativecommons.org/licenses/GPL/2.0/legalcode.pt", "http://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html", "http://www.opensource.org/licenses/GPL-2.0" ] }python-saneyaml_0.3.orig/tests/data/yamls/gpl-2.0.yml.expected.yaml.dump0000644000000000000000000000336613374544111023175 0ustar00key: gpl-2.0 short_name: GPL 2.0 name: GNU General Public License 2.0 category: Copyleft owner: Free Software Foundation (FSF) homepage_url: http://www.gnu.org/licenses/gpl-2.0.html notes: "This is the last version of the GPL text as published by the FSF. This\nvariation was\ \ published around about the time of the FSF released the GPL 3\nin July 2007.\nhttp://web.archive.org/web/20070716031727/http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt\ \ \nIt is found live here https://www.gnu.org/licenses/old-licenses/gpl-2.0.txt\nand here\ \ https://www.gnu.org/licenses/old-licenses/gpl-2.0.html \nIt refers to the Franklin Street\ \ address and to the\nGNU Lesser General Public License everywhere both in the text and HTML\n\ formats. There are four other variations that were published over the\nyears. You can find\ \ these in the GPL rules as gpl-2.0_100.RULE,\ngpl-2.0_101.RULE, gpl-2.0_102.RULE and gpl-2.0_103.RULE.\ \ Their\ncorresponding YAML data explains their history and provides archive.org\npointer\ \ to their texts. Per SPDX.org, this license was released June 1991\nThis license is OSI certified." spdx_license_key: GPL-2.0-only other_spdx_license_keys: - GPL-2.0 text_urls: - http://www.gnu.org/licenses/gpl-2.0.txt - http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt osi_url: http://opensource.org/licenses/gpl-license.php faq_url: http://www.gnu.org/licenses/old-licenses/gpl-2.0-faq.html other_urls: - http://creativecommons.org/choose/cc-gpl - http://creativecommons.org/images/public/cc-GPL-a.png - http://creativecommons.org/licenses/GPL/2.0/ - http://creativecommons.org/licenses/GPL/2.0/legalcode.pt - http://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html - http://www.opensource.org/licenses/GPL-2.0 python-saneyaml_0.3.orig/tests/data/yamls/idna-2.6-py2.py3-none-any.whl.yml0000644000000000000000000000211013374544111023346 0ustar00about_resource: idna-2.6-py2.py3-none-any.whl attribute: true checksum_md5: 875c4a7b32b4897537d5ea9247b5c79e checksum_sha1: a75f31778ea0bbf218d7ae085f4f961d004d6ff2 contact: http://kim.id.au/ copyright: Copyright (c) 2013-2017, Kim Davies description: 'Internationalized Domain Names for Python (IDNA 2008 and UTS #46)' download_url: https://pypi.python.org/packages/27/cc/6dd9a3869f15c2edfab863b992838277279ce92663d334df9ecf5106f5c6/idna-2.6-py2.py3-none-any.whl#md5=875c4a7b32b4897537d5ea9247b5c79e homepage_url: https://github.com/kjd/idna license_expression: bsd-new AND python AND unicode licenses: - file: bsd-new.LICENSE key: bsd-new name: BSD-3-Clause - file: python.LICENSE key: python name: Python Software Foundation License v2 - file: unicode.LICENSE key: unicode name: Unicode Inc License Agreement name: idna notice_file: idna-2.6-py2.py3-none-any.whl.NOTICE notice_url: https://github.com/kjd/idna/blob/v2.6/LICENSE.rst owner: Kim Davies owner_url: https://github.com/kjd track_changes: true vcs_repository: https://github.com/kjd/idna version: '2.6' python-saneyaml_0.3.orig/tests/data/yamls/idna-2.6-py2.py3-none-any.whl.yml.expected.load.json0000644000000000000000000000245513374544111027050 0ustar00{ "about_resource": "idna-2.6-py2.py3-none-any.whl", "attribute": true, "checksum_md5": "875c4a7b32b4897537d5ea9247b5c79e", "checksum_sha1": "a75f31778ea0bbf218d7ae085f4f961d004d6ff2", "contact": "http://kim.id.au/", "copyright": "Copyright (c) 2013-2017, Kim Davies", "description": "Internationalized Domain Names for Python (IDNA 2008 and UTS #46)", "download_url": "https://pypi.python.org/packages/27/cc/6dd9a3869f15c2edfab863b992838277279ce92663d334df9ecf5106f5c6/idna-2.6-py2.py3-none-any.whl#md5=875c4a7b32b4897537d5ea9247b5c79e", "homepage_url": "https://github.com/kjd/idna", "license_expression": "bsd-new AND python AND unicode", "licenses": [ { "file": "bsd-new.LICENSE", "key": "bsd-new", "name": "BSD-3-Clause" }, { "file": "python.LICENSE", "key": "python", "name": "Python Software Foundation License v2" }, { "file": "unicode.LICENSE", "key": "unicode", "name": "Unicode Inc License Agreement" } ], "name": "idna", "notice_file": "idna-2.6-py2.py3-none-any.whl.NOTICE", "notice_url": "https://github.com/kjd/idna/blob/v2.6/LICENSE.rst", "owner": "Kim Davies", "owner_url": "https://github.com/kjd", "track_changes": true, "vcs_repository": "https://github.com/kjd/idna", "version": "2.6" }python-saneyaml_0.3.orig/tests/data/yamls/idna-2.6-py2.py3-none-any.whl.yml.expected.yaml.dump0000644000000000000000000000210613374544111027060 0ustar00about_resource: idna-2.6-py2.py3-none-any.whl attribute: yes checksum_md5: 875c4a7b32b4897537d5ea9247b5c79e checksum_sha1: a75f31778ea0bbf218d7ae085f4f961d004d6ff2 contact: http://kim.id.au/ copyright: Copyright (c) 2013-2017, Kim Davies description: 'Internationalized Domain Names for Python (IDNA 2008 and UTS #46)' download_url: https://pypi.python.org/packages/27/cc/6dd9a3869f15c2edfab863b992838277279ce92663d334df9ecf5106f5c6/idna-2.6-py2.py3-none-any.whl#md5=875c4a7b32b4897537d5ea9247b5c79e homepage_url: https://github.com/kjd/idna license_expression: bsd-new AND python AND unicode licenses: - file: bsd-new.LICENSE key: bsd-new name: BSD-3-Clause - file: python.LICENSE key: python name: Python Software Foundation License v2 - file: unicode.LICENSE key: unicode name: Unicode Inc License Agreement name: idna notice_file: idna-2.6-py2.py3-none-any.whl.NOTICE notice_url: https://github.com/kjd/idna/blob/v2.6/LICENSE.rst owner: Kim Davies owner_url: https://github.com/kjd track_changes: yes vcs_repository: https://github.com/kjd/idna version: '2.6' python-saneyaml_0.3.orig/tests/data/yamls/isodate.yml0000644000000000000000000000074413374544111020036 0ustar00about_resource: isodate-0.5.4-cp27-none-any.whl download_url: https://pypi.python.org/packages/f4/5b/fe03d46ced80639b7be9285492dc8ce069b841c0cebe5baacdd9b090b164/isodate-0.5.4.tar.gz#md5=9da3ea2af54a6261d854e73d2266030e name: isodate version: 0.5.4 license_expression: bsd-new license_file: isodate.LICENSE copyright: Copyright (c) 2009 Gerhard Weis owner: Gerhard Weis home_url: https://github.com/gweis/isodate vcs_tool: git vcs_repository: https://github.com/gweis/isodate.git python-saneyaml_0.3.orig/tests/data/yamls/isodate.yml.expected.load.json0000644000000000000000000000105713374544111023522 0ustar00{ "about_resource": "isodate-0.5.4-cp27-none-any.whl", "download_url": "https://pypi.python.org/packages/f4/5b/fe03d46ced80639b7be9285492dc8ce069b841c0cebe5baacdd9b090b164/isodate-0.5.4.tar.gz#md5=9da3ea2af54a6261d854e73d2266030e", "name": "isodate", "version": "0.5.4", "license_expression": "bsd-new", "license_file": "isodate.LICENSE", "copyright": "Copyright (c) 2009 Gerhard Weis", "owner": "Gerhard Weis", "home_url": "https://github.com/gweis/isodate", "vcs_tool": "git", "vcs_repository": "https://github.com/gweis/isodate.git" }python-saneyaml_0.3.orig/tests/data/yamls/isodate.yml.expected.yaml.dump0000644000000000000000000000074013374544111023537 0ustar00about_resource: isodate-0.5.4-cp27-none-any.whl download_url: https://pypi.python.org/packages/f4/5b/fe03d46ced80639b7be9285492dc8ce069b841c0cebe5baacdd9b090b164/isodate-0.5.4.tar.gz#md5=9da3ea2af54a6261d854e73d2266030e name: isodate version: 0.5.4 license_expression: bsd-new license_file: isodate.LICENSE copyright: Copyright (c) 2009 Gerhard Weis owner: Gerhard Weis home_url: https://github.com/gweis/isodate vcs_tool: git vcs_repository: https://github.com/gweis/isodate.git python-saneyaml_0.3.orig/tests/data/yamls/license_texs.yml0000644000000000000000000000276713374544111021102 0ustar00license_expressions: - gpl-1.0-plus - lgpl-2.0-plus - lgpl-3.0 - lgpl-2.0-plus - lgpl-2.0-plus - lgpl-2.0-plus - spl-1.0 - lgpl-2.0-plus - bsd-new - bitstream - gpl-1.0-plus - gpl-1.0-plus - font-exception-gpl - boost-1.0 - boost-original - mit-open-group - mpl-1.1 - lgpl-2.0-plus - lgpl-2.1 - lgpl-2.0-plus - lgpl-2.1 - lgpl-2.1 - lgpl-2.1 - gpl-1.0-plus - gpl-1.0-plus - gpl-2.0-plus - mit - lgpl-2.0-plus - lgpl-2.0-plus - lgpl-2.0-plus - bsd-new - bsd-new - gpl-1.0-plus - lgpl-2.0-plus - gpl-1.0-plus - gpl-2.0 - gpl-1.0-plus - gpl-1.0-plus - lgpl-2.0-plus - bsd-new - bsd-new - ijg - bsd-new - bsd-new - bitstream - bitstream - bitstream - lgpl-2.1 - bitstream - bitstream - lgpl-2.1 - lgpl-2.0-plus - gpl-1.0-plus - openssl-ssleay - lgpl-2.0 - lgpl-2.0-plus - gpl-1.0-plus - lgpl-2.0-plus - public-domain - bitstream - bitstream - bitstream - bitstream - lgpl-2.1 - bitstream - bitstream - lgpl-2.1 - lgpl-2.0-plus - gpl-1.0-plus - openssl-ssleay - lgpl-2.0 - lgpl-2.0-plus - gpl-1.0-plus - lgpl-2.0-plus - public-domain - stlport-4.5 - lgpl-2.0-plus - mit - lgpl-2.0-plus - lppl-1.2 OR later - mit - mit - gpl-1.0-plus - unknown expected_failure: yes notes: this is failing for now.python-saneyaml_0.3.orig/tests/data/yamls/license_texs.yml.expected.load.json0000644000000000000000000000314513374544111024557 0ustar00{ "license_expressions": [ "gpl-1.0-plus", "lgpl-2.0-plus", "lgpl-3.0", "lgpl-2.0-plus", "lgpl-2.0-plus", "lgpl-2.0-plus", "spl-1.0", "lgpl-2.0-plus", "bsd-new", "bitstream", "gpl-1.0-plus", "gpl-1.0-plus", "font-exception-gpl", "boost-1.0", "boost-original", "mit-open-group", "mpl-1.1", "lgpl-2.0-plus", "lgpl-2.1", "lgpl-2.0-plus", "lgpl-2.1", "lgpl-2.1", "lgpl-2.1", "gpl-1.0-plus", "gpl-1.0-plus", "gpl-2.0-plus", "mit", "lgpl-2.0-plus", "lgpl-2.0-plus", "lgpl-2.0-plus", "bsd-new", "bsd-new", "gpl-1.0-plus", "lgpl-2.0-plus", "gpl-1.0-plus", "gpl-2.0", "gpl-1.0-plus", "gpl-1.0-plus", "lgpl-2.0-plus", "bsd-new", "bsd-new", "ijg", "bsd-new", "bsd-new", "bitstream", "bitstream", "bitstream", "lgpl-2.1", "bitstream", "bitstream", "lgpl-2.1", "lgpl-2.0-plus", "gpl-1.0-plus", "openssl-ssleay", "lgpl-2.0", "lgpl-2.0-plus", "gpl-1.0-plus", "lgpl-2.0-plus", "public-domain", "bitstream", "bitstream", "bitstream", "bitstream", "lgpl-2.1", "bitstream", "bitstream", "lgpl-2.1", "lgpl-2.0-plus", "gpl-1.0-plus", "openssl-ssleay", "lgpl-2.0", "lgpl-2.0-plus", "gpl-1.0-plus", "lgpl-2.0-plus", "public-domain", "stlport-4.5", "lgpl-2.0-plus", "mit", "lgpl-2.0-plus", "lppl-1.2 OR later", "mit", "mit", "gpl-1.0-plus", "unknown" ], "expected_failure": true, "notes": "this is failing for now." }python-saneyaml_0.3.orig/tests/data/yamls/license_texs.yml.expected.yaml.dump0000644000000000000000000000252013374544111024572 0ustar00license_expressions: - gpl-1.0-plus - lgpl-2.0-plus - lgpl-3.0 - lgpl-2.0-plus - lgpl-2.0-plus - lgpl-2.0-plus - spl-1.0 - lgpl-2.0-plus - bsd-new - bitstream - gpl-1.0-plus - gpl-1.0-plus - font-exception-gpl - boost-1.0 - boost-original - mit-open-group - mpl-1.1 - lgpl-2.0-plus - lgpl-2.1 - lgpl-2.0-plus - lgpl-2.1 - lgpl-2.1 - lgpl-2.1 - gpl-1.0-plus - gpl-1.0-plus - gpl-2.0-plus - mit - lgpl-2.0-plus - lgpl-2.0-plus - lgpl-2.0-plus - bsd-new - bsd-new - gpl-1.0-plus - lgpl-2.0-plus - gpl-1.0-plus - gpl-2.0 - gpl-1.0-plus - gpl-1.0-plus - lgpl-2.0-plus - bsd-new - bsd-new - ijg - bsd-new - bsd-new - bitstream - bitstream - bitstream - lgpl-2.1 - bitstream - bitstream - lgpl-2.1 - lgpl-2.0-plus - gpl-1.0-plus - openssl-ssleay - lgpl-2.0 - lgpl-2.0-plus - gpl-1.0-plus - lgpl-2.0-plus - public-domain - bitstream - bitstream - bitstream - bitstream - lgpl-2.1 - bitstream - bitstream - lgpl-2.1 - lgpl-2.0-plus - gpl-1.0-plus - openssl-ssleay - lgpl-2.0 - lgpl-2.0-plus - gpl-1.0-plus - lgpl-2.0-plus - public-domain - stlport-4.5 - lgpl-2.0-plus - mit - lgpl-2.0-plus - lppl-1.2 OR later - mit - mit - gpl-1.0-plus - unknown expected_failure: yes notes: this is failing for now. python-saneyaml_0.3.orig/tests/data/yamls/lxml-4.2.1-cp27-cp27m-win_amd64.whl.yml0000644000000000000000000000211713374544111024074 0ustar00about_resource: lxml-4.2.1-cp27-cp27m-win_amd64.whl attribute: true checksum_md5: b9123b80ec548e3c2766a4d570ce1a10 checksum_sha1: d271b00d8ed39c747a274666d89e8bac09bd3e03 copyright: Copyright (c) 2004 Infrae. description: lxml is the most feature-rich and easy-to-use library for processing XML and HTML in the Python language. download_url: https://files.pythonhosted.org/packages/52/7f/aeaa0064809c319078b97bd30a0d7f7ee062df07608fa439029a948a431e/lxml-4.2.1-cp27-cp27m-win_amd64.whl homepage_url: http://lxml.de/ license_expression: bsd-new AND (mit AND gpl-2.0-plus AND zpl-2.0 AND zlib) licenses: - file: bsd-new.LICENSE key: bsd-new name: BSD-3-Clause - file: gpl-2.0-plus.LICENSE key: gpl-2.0-plus name: GNU General Public License 2.0 or later - file: mit.LICENSE key: mit name: MIT License - file: zlib.LICENSE key: zlib name: ZLIB License - file: zpl-2.0.LICENSE key: zpl-2.0 name: Zope Public License 2.0 name: LXML notice_file: lxml-4.2.1-cp27-cp27m-win_amd64.whl.NOTICE owner: Infrae redistribute: true track_changes: true version: 4.2.1 python-saneyaml_0.3.orig/tests/data/yamls/lxml-4.2.1-cp27-cp27m-win_amd64.whl.yml.expected.load.json0000644000000000000000000000253713374544111027570 0ustar00{ "about_resource": "lxml-4.2.1-cp27-cp27m-win_amd64.whl", "attribute": true, "checksum_md5": "b9123b80ec548e3c2766a4d570ce1a10", "checksum_sha1": "d271b00d8ed39c747a274666d89e8bac09bd3e03", "copyright": "Copyright (c) 2004 Infrae.", "description": "lxml is the most feature-rich and easy-to-use library for processing XML and HTML in the Python language.", "download_url": "https://files.pythonhosted.org/packages/52/7f/aeaa0064809c319078b97bd30a0d7f7ee062df07608fa439029a948a431e/lxml-4.2.1-cp27-cp27m-win_amd64.whl", "homepage_url": "http://lxml.de/", "license_expression": "bsd-new AND (mit AND gpl-2.0-plus AND zpl-2.0 AND zlib)", "licenses": [ { "file": "bsd-new.LICENSE", "key": "bsd-new", "name": "BSD-3-Clause" }, { "file": "gpl-2.0-plus.LICENSE", "key": "gpl-2.0-plus", "name": "GNU General Public License 2.0 or later" }, { "file": "mit.LICENSE", "key": "mit", "name": "MIT License" }, { "file": "zlib.LICENSE", "key": "zlib", "name": "ZLIB License" }, { "file": "zpl-2.0.LICENSE", "key": "zpl-2.0", "name": "Zope Public License 2.0" } ], "name": "LXML", "notice_file": "lxml-4.2.1-cp27-cp27m-win_amd64.whl.NOTICE", "owner": "Infrae", "redistribute": true, "track_changes": true, "version": "4.2.1" }python-saneyaml_0.3.orig/tests/data/yamls/lxml-4.2.1-cp27-cp27m-win_amd64.whl.yml.expected.yaml.dump0000644000000000000000000000211213374544111027574 0ustar00about_resource: lxml-4.2.1-cp27-cp27m-win_amd64.whl attribute: yes checksum_md5: b9123b80ec548e3c2766a4d570ce1a10 checksum_sha1: d271b00d8ed39c747a274666d89e8bac09bd3e03 copyright: Copyright (c) 2004 Infrae. description: lxml is the most feature-rich and easy-to-use library for processing XML and HTML in the Python language. download_url: https://files.pythonhosted.org/packages/52/7f/aeaa0064809c319078b97bd30a0d7f7ee062df07608fa439029a948a431e/lxml-4.2.1-cp27-cp27m-win_amd64.whl homepage_url: http://lxml.de/ license_expression: bsd-new AND (mit AND gpl-2.0-plus AND zpl-2.0 AND zlib) licenses: - file: bsd-new.LICENSE key: bsd-new name: BSD-3-Clause - file: gpl-2.0-plus.LICENSE key: gpl-2.0-plus name: GNU General Public License 2.0 or later - file: mit.LICENSE key: mit name: MIT License - file: zlib.LICENSE key: zlib name: ZLIB License - file: zpl-2.0.LICENSE key: zpl-2.0 name: Zope Public License 2.0 name: LXML notice_file: lxml-4.2.1-cp27-cp27m-win_amd64.whl.NOTICE owner: Infrae redistribute: yes track_changes: yes version: 4.2.1 python-saneyaml_0.3.orig/tests/data/yamls/lxml-4.2.1.tar.gz.yml0000644000000000000000000000203113374544111021215 0ustar00about_resource: lxml-4.2.1.tar.gz attribute: true checksum_md5: c266d9062e23b08f66426979a2b36f51 checksum_sha1: 5ac888d5957f74298fb6daf74778bd91812f7571 copyright: Copyright (c) 2004 Infrae. description: lxml is the most feature-rich and easy-to-use library for processing XML and HTML in the Python language. download_url: https://files.pythonhosted.org/packages/e8/5d/98f56e274bdf17f2e0d9016d1788ca80d26d8987dcd5e1d9416d86ee0625/lxml-4.2.1.tar.gz homepage_url: http://lxml.de/ license_expression: bsd-new AND (mit AND gpl-2.0-plus AND zpl-2.0 AND zlib) licenses: - file: bsd-new.LICENSE key: bsd-new name: BSD-3-Clause - file: gpl-2.0-plus.LICENSE key: gpl-2.0-plus name: GNU General Public License 2.0 or later - file: mit.LICENSE key: mit name: MIT License - file: zlib.LICENSE key: zlib name: ZLIB License - file: zpl-2.0.LICENSE key: zpl-2.0 name: Zope Public License 2.0 name: LXML notice_file: lxml-4.2.1.tar.gz.NOTICE owner: Infrae redistribute: true track_changes: true version: 4.2.1 python-saneyaml_0.3.orig/tests/data/yamls/lxml-4.2.1.tar.gz.yml.expected.load.json0000644000000000000000000000245113374544111024711 0ustar00{ "about_resource": "lxml-4.2.1.tar.gz", "attribute": true, "checksum_md5": "c266d9062e23b08f66426979a2b36f51", "checksum_sha1": "5ac888d5957f74298fb6daf74778bd91812f7571", "copyright": "Copyright (c) 2004 Infrae.", "description": "lxml is the most feature-rich and easy-to-use library for processing XML and HTML in the Python language.", "download_url": "https://files.pythonhosted.org/packages/e8/5d/98f56e274bdf17f2e0d9016d1788ca80d26d8987dcd5e1d9416d86ee0625/lxml-4.2.1.tar.gz", "homepage_url": "http://lxml.de/", "license_expression": "bsd-new AND (mit AND gpl-2.0-plus AND zpl-2.0 AND zlib)", "licenses": [ { "file": "bsd-new.LICENSE", "key": "bsd-new", "name": "BSD-3-Clause" }, { "file": "gpl-2.0-plus.LICENSE", "key": "gpl-2.0-plus", "name": "GNU General Public License 2.0 or later" }, { "file": "mit.LICENSE", "key": "mit", "name": "MIT License" }, { "file": "zlib.LICENSE", "key": "zlib", "name": "ZLIB License" }, { "file": "zpl-2.0.LICENSE", "key": "zpl-2.0", "name": "Zope Public License 2.0" } ], "name": "LXML", "notice_file": "lxml-4.2.1.tar.gz.NOTICE", "owner": "Infrae", "redistribute": true, "track_changes": true, "version": "4.2.1" }python-saneyaml_0.3.orig/tests/data/yamls/lxml-4.2.1.tar.gz.yml.expected.yaml.dump0000644000000000000000000000202413374544111024724 0ustar00about_resource: lxml-4.2.1.tar.gz attribute: yes checksum_md5: c266d9062e23b08f66426979a2b36f51 checksum_sha1: 5ac888d5957f74298fb6daf74778bd91812f7571 copyright: Copyright (c) 2004 Infrae. description: lxml is the most feature-rich and easy-to-use library for processing XML and HTML in the Python language. download_url: https://files.pythonhosted.org/packages/e8/5d/98f56e274bdf17f2e0d9016d1788ca80d26d8987dcd5e1d9416d86ee0625/lxml-4.2.1.tar.gz homepage_url: http://lxml.de/ license_expression: bsd-new AND (mit AND gpl-2.0-plus AND zpl-2.0 AND zlib) licenses: - file: bsd-new.LICENSE key: bsd-new name: BSD-3-Clause - file: gpl-2.0-plus.LICENSE key: gpl-2.0-plus name: GNU General Public License 2.0 or later - file: mit.LICENSE key: mit name: MIT License - file: zlib.LICENSE key: zlib name: ZLIB License - file: zpl-2.0.LICENSE key: zpl-2.0 name: Zope Public License 2.0 name: LXML notice_file: lxml-4.2.1.tar.gz.NOTICE owner: Infrae redistribute: yes track_changes: yes version: 4.2.1 python-saneyaml_0.3.orig/tests/data/yamls/not-a-license_125.yml0000644000000000000000000000023213374544111021423 0ustar00is_negative: yes notes: See in https://github.com/jslicense/spdx-correct.js/tree/ae4124a26e862181d16d745b5b9ac6838e4a6109 which is a license-related toolpython-saneyaml_0.3.orig/tests/data/yamls/not-a-license_125.yml.expected.load.json0000644000000000000000000000025113374544111025112 0ustar00{ "is_negative": true, "notes": "See in https://github.com/jslicense/spdx-correct.js/tree/ae4124a26e862181d16d745b5b9ac6838e4a6109 which is a license-related tool" }python-saneyaml_0.3.orig/tests/data/yamls/not-a-license_125.yml.expected.yaml.dump0000644000000000000000000000023413374544111025132 0ustar00is_negative: yes notes: See in https://github.com/jslicense/spdx-correct.js/tree/ae4124a26e862181d16d745b5b9ac6838e4a6109 which is a license-related tool