rosdistro package

Submodules

rosdistro.aptdistro module

class rosdistro.aptdistro.AptDistro(ubuntudistro, arch, shadow=True)[source]

Bases: object

depends(package, res=None, one=False)[source]
depends1(package)[source]
depends_on(package, res=None, one=False)[source]
depends_on1(package)[source]
has_package(package)[source]

rosdistro.common module

rosdistro.common.error(msg, end=None, file=None)[source]
rosdistro.common.info(msg, end=None, file=None)[source]
rosdistro.common.override_print(print_func=<function _print_func>)[source]
rosdistro.common.quiet(state=True)[source]
rosdistro.common.rmtree(path)[source]
rosdistro.common.warning(msg, end=None, file=None)[source]

rosdistro.dependency_walker module

class rosdistro.dependency_walker.DependencyWalker(distribution_instance, evaluate_condition_context=None)[source]

Bases: object

get_depends(pkg_name, depend_type, ros_packages_only=False)[source]

Return a set of package names which the package depends on.

get_depends_on(pkg_name, depend_type, ignore_pkgs=None)[source]

Return a set of package names which depend on the package.

get_recursive_depends(pkg_name, depend_types, ros_packages_only=False, ignore_pkgs=None, limit_depth=None)[source]

Return a set of package names which the package (transitively) depends on.

get_recursive_depends_on(pkg_name, depend_types, ignore_pkgs=None)[source]

Return a set of package names which (transitively) depend on the package.

class rosdistro.dependency_walker.SourceDependencyWalker(distribution_instance, evaluate_condition_context=None)[source]

Bases: rosdistro.dependency_walker.DependencyWalker

rosdistro.develdistro module

class rosdistro.develdistro.DevelDistro(name)[source]

Bases: object

class rosdistro.develdistro.DevelDistroRepo(name, data)[source]

Bases: object

get_rosinstall()[source]

rosdistro.distribution module

class rosdistro.distribution.Distribution(distribution_file, manifest_providers=None, source_manifest_providers=None)[source]

Bases: object

default_manifest_providers = [<function github_manifest_provider>, <function bitbucket_manifest_provider>, <function git_manifest_provider>, <function tar_manifest_provider>]
default_source_manifest_providers = [<function github_source_manifest_provider>, <function git_source_manifest_provider>, <function tar_source_manifest_provider>]
get_release_package_xml(pkg_name)[source]
get_source_package_xml(pkg_name)[source]
get_source_repo_package_xmls(repo_name)[source]

rosdistro.distribution_cache module

class rosdistro.distribution_cache.DistributionCache(name, data=None, distribution_file_data=None)[source]

Bases: object

get_data()[source]
get_source_packages()[source]

Returns dictionary mapping source package names to Package() objects.

update_distribution(distribution_file_data)[source]

rosdistro.distribution_cache_generator module

class rosdistro.distribution_cache_generator.CacheYamlDumper(*args, **kwargs)[source]

Bases: yaml.dumper.SafeDumper

A yaml dumper specific to dumping the serialized rosdistro cache file.

Allows long lines and direct unicode representation. This avoids writing escape sequences, line continuations, and other noise into the cache file. Also permits long strings to alias each other (by default only objects do).

ignore_aliases(content)[source]

Allow strings that look like package XML to alias to each other in the YAML output.

represent_mapping(tag, mapping, flow_style=False)[source]

Gives compact representation for the distribution_file section, while allowing the package XML cache sections room to breathe.

rosdistro.distribution_cache_generator.generate_distribution_cache(index, dist_name, preclean=False, ignore_local=False, include_source=False, debug=False)[source]
rosdistro.distribution_cache_generator.generate_distribution_caches(index, dist_names=None, preclean=False, ignore_local=False, include_source=False, debug=False)[source]

rosdistro.distribution_file module

class rosdistro.distribution_file.DistributionFile(name, data)[source]

Bases: object

get_data()[source]
merge(other_dist_file)[source]
rosdistro.distribution_file.create_distribution_file(dist_name, data)[source]

rosdistro.doc_build_file module

class rosdistro.doc_build_file.DocBuildFile(name, data)[source]

Bases: object

filter_repositories(repos)[source]
get_data()[source]
get_target_arches(os_name, os_code_name)[source]
get_target_configuration(os_name=None, os_code_name=None, arch=None)[source]
get_target_os_code_names(os_name)[source]
get_target_os_names()[source]

rosdistro.doc_file module

class rosdistro.doc_file.DocFile(name, data)[source]

Bases: object

rosdistro.doc_repository_specification module

class rosdistro.doc_repository_specification.DocRepositorySpecification(name, data)[source]

Bases: rosdistro.repository_specification.RepositorySpecification

get_data()[source]

rosdistro.freeze_source module

rosdistro.freeze_source.freeze_distribution_sources(dist, release_version=False, release_tag=False, concurrent_ops=16, quiet=False)[source]

rosdistro.index module

class rosdistro.index.Index(data, base_url, url_query='')[source]

Bases: object

rosdistro.legacy module

rosdistro.legacy.get_cached_release(index, dist_name, cache=None, allow_lazy_load=False)[source]
rosdistro.legacy.get_doc_build_files(index, dist_name)[source]
rosdistro.legacy.get_doc_file(index, dist_name)[source]
rosdistro.legacy.get_release(index, dist_name)[source]
rosdistro.legacy.get_release_build_files(index, dist_name)[source]
rosdistro.legacy.get_release_builds(index, release_file)[source]
rosdistro.legacy.get_release_cache(index, dist_name)[source]
rosdistro.legacy.get_release_file(index, dist_name)[source]
rosdistro.legacy.get_source_build_files(index, dist_name)[source]
rosdistro.legacy.get_source_file(index, dist_name)[source]

rosdistro.loader module

rosdistro.loader.load_url(url, retry=2, retry_period=1, timeout=10, skip_decode=False)[source]

rosdistro.package module

class rosdistro.package.Package(name, repository_name)[source]

Bases: object

rosdistro.release module

class rosdistro.release.Release(rel_file, manifest_providers=None)[source]

Bases: object

default_manifest_providers = [<function github_manifest_provider>, <function bitbucket_manifest_provider>, <function git_manifest_provider>]
get_package_xml(pkg_name)[source]

rosdistro.release_build module

class rosdistro.release_build.ReleaseBuild(dist, release_build_file)[source]

Bases: object

get_package_names()[source]

rosdistro.release_build_file module

class rosdistro.release_build_file.ReleaseBuildFile(name, data)[source]

Bases: object

get_data()[source]
get_target_arches(os_name, os_code_name)[source]
get_target_configuration(os_name=None, os_code_name=None, arch=None)[source]
get_target_os_code_names(os_name)[source]
get_target_os_names()[source]

rosdistro.release_cache module

class rosdistro.release_cache.ReleaseCache(name, data=None, distribution_file_data=None)[source]

Bases: object

get_data()[source]
update_distribution(distribution_file_data)[source]

rosdistro.release_cache_generator module

rosdistro.release_cache_generator.generate_release_cache(index, dist_name, preclean=False, debug=False)[source]
rosdistro.release_cache_generator.generate_release_caches(index, dist_names=None, preclean=False, debug=False)[source]

rosdistro.release_file module

class rosdistro.release_file.ReleaseFile(name, data)[source]

Bases: object

rosdistro.release_repository_specification module

class rosdistro.release_repository_specification.ReleaseRepositorySpecification(name, data)[source]

Bases: rosdistro.repository_specification.RepositorySpecification

get_data()[source]
get_release_tag(pkg_name)[source]

rosdistro.repository module

class rosdistro.repository.Repository(name, doc_data, release_data, source_data, status_data)[source]

Bases: object

get_data()[source]

rosdistro.repository_specification module

class rosdistro.repository_specification.RepositorySpecification(name, data)[source]

Bases: object

VCS_REGEX = re.compile('(?:https?:\\/\\/|ssh:\\/\\/|git:\\/\\/|git@)((?:[a-fA-F0-9]{40}@)?[\\w.-]+)[:/]([\\w/-]*)(?:\\.git)?$')
get_data()[source]
get_url_parts()[source]

Returns a tuple for the server and path, eg (‘github.com’, ‘ros/catkin’)

has_remote_tag(tag)[source]
remote_refs
remote_tags

rosdistro.rosdistro module

class rosdistro.rosdistro.RosDependencies(name, cache_location)[source]

Bases: object

get_dependencies(package, rosdistro)[source]
class rosdistro.rosdistro.RosDistro(name, cache_location=None)[source]

Bases: object

get_depends(items, depth=0, dep_dict={'build': ['build', 'run', 'buildtool', 'test'], 'buildtool': ['build', 'run', 'buildtool', 'test'], 'run': ['build', 'run', 'buildtool', 'test'], 'test': ['build', 'run', 'buildtool', 'test']})[source]
get_depends1(items)[source]
get_depends_on(items, depth=0, dep_dict={'build': ['build', 'run', 'buildtool', 'test'], 'buildtool': ['build', 'run', 'buildtool', 'test'], 'run': ['build', 'run', 'buildtool', 'test'], 'test': ['build', 'run', 'buildtool', 'test']})[source]
get_depends_on1(items)[source]
get_package(pkg)[source]
get_packages()[source]
get_repositories()[source]
get_repository(repo)[source]
get_rosinstall(items, version='last_release', source='vcs')[source]
class rosdistro.rosdistro.RosDistroFile(name)[source]

Bases: object

class rosdistro.rosdistro.RosPackage(name, repository)[source]

Bases: object

get_package_xml(rosdistro)[source]
get_release_tag(rosdistro)[source]
get_rosinstall(version, source, rosdistro)[source]
class rosdistro.rosdistro.RosRepository(name, version, url)[source]

Bases: object

get_rosinstall(version, source)[source]
rosdistro.rosdistro.get_package_dependencies(package_xml)[source]
rosdistro.rosdistro.invert_dict(d)[source]
rosdistro.rosdistro.retrieve_dependencies(package_xml)[source]

rosdistro.source_build_file module

class rosdistro.source_build_file.SourceBuildFile(name, data)[source]

Bases: object

filter_repositories(repos)[source]
get_data()[source]
get_target_arches(os_name, os_code_name)[source]
get_target_configuration(os_name=None, os_code_name=None, arch=None)[source]
get_target_os_code_names(os_name)[source]
get_target_os_names()[source]

rosdistro.source_file module

class rosdistro.source_file.SourceFile(name, data)[source]

Bases: object

rosdistro.source_repository_cache module

class rosdistro.source_repository_cache.SourceRepositoryCache(data)[source]

Bases: object

This class represents a cache of the package XML strings for all packages in a single repo at a particular moment in time. A dictionary of many of these (one for each repo) keyed to the repo name represents the totality of the source package xml cache.

add(package_name, package_path, package_xml_string)[source]

Add a package to the cache.

classmethod from_ref(ref)[source]

Create a new empty cache instance from just the version control reference hash.

get_data()[source]

Return the bare data dict, suitable for serializing into yaml.

items()[source]

Generator of (str, str, str) containing the package name, path relative to repo root, and package xml string.

keys()[source]

Return the list of packages in the repo cache.

ref()[source]

Return the version control hash.

rosdistro.source_repository_specification module

class rosdistro.source_repository_specification.SourceRepositorySpecification(name, data)[source]

Bases: rosdistro.repository_specification.RepositorySpecification

get_data()[source]

rosdistro.status module

rosdistro.vcs module

class rosdistro.vcs.Git(cwd=None)[source]

Bases: object

command(*args)[source]
classmethod version_gte(version)[source]
rosdistro.vcs.ref_is_hash(ref)[source]

rosdistro.verify module

rosdistro.verify.reformat_files(index_url)[source]
rosdistro.verify.verify_files(index_url, callback, include_deprecated=False)[source]
rosdistro.verify.verify_files_identical(index_url)[source]
rosdistro.verify.verify_files_parsable(index_url)[source]

rosdistro.writer module

rosdistro.writer.yaml_from_distribution_file(distribution_file)[source]
rosdistro.writer.yaml_from_release_file(release_file)[source]

Module contents

rosdistro.get_cached_distribution(index, dist_name, cache=None, allow_lazy_load=False)[source]
rosdistro.get_distribution(index, dist_name)[source]
rosdistro.get_distribution_cache(index, dist_name)[source]
rosdistro.get_distribution_cache_string(index, dist_name)[source]
rosdistro.get_distribution_file(index, dist_name)[source]
rosdistro.get_distribution_files(index, dist_name)[source]
rosdistro.get_index(url)[source]
rosdistro.get_index_url()[source]
rosdistro.get_package_condition_context(index, dist_name)[source]