Returns all deployments found in a chain URI's deployment data that contain link dependencies.
761367
def get_linked_deployments(deployments: Dict[str, Any]) -> Dict[str, Any]:
    
    linked_deployments = {
        dep: data
        for dep, data in deployments.items()
        if get_in(("runtime_bytecode", "link_dependencies"), data)
    }
    for deployment, data in linked_deployments.items():
        if any(
            link_dep["value"] == deployment
            for link_dep in data["runtime_bytecode"]["link_dependencies"]
        ):
            raise BytecodeLinkingError(
                f"Link dependency found in {deployment} deployment that references its "
                "own contract instance, which is disallowed"
            )
    return linked_deployments
472112
def get_deployments(token_manager=None,
                    app_url=defaults.APP_URL):
    
    headers = token_manager.get_access_token_headers()
    deployment_url = environment.get_deployment_url(app_url=app_url)
    response = requests.get('%s/api/v1/deployments' % deployment_url,
                            headers=headers)

    if response.status_code == 200:
        return response.json()
    else:
        raise JutException('Error %s: %s' % (response.status_code, response.text))
1322794
public java.util.List<DeploymentInfo> getDeploymentsInfo() {
        if (deploymentsInfo == null) {
            deploymentsInfo = new com.amazonaws.internal.SdkInternalList<DeploymentInfo>();
        }
        return deploymentsInfo;
    }
707850
function showLinkedDeps() {
  const linkedDeps = getLinkedDeps(packageKeys, packageHash);
  if (linkedDeps.length) {
    logPkgsMsg('Linked', linkedDeps);
  } else {
    log('No linked dependencies found');
  }
}
805644
def get_deploy_data(self):
        '''
        
        '''

        if self.state and self.state.deploy_data:
            return self.state.deploy_data

        return {}
692760
def deployAll(self):
        '''
            
        '''
        targets = [Target.getTarget(iid) for iid, n, p in self.db.listTargets()]

        for target in targets:
            target.deploy()

        verbose('Deploy all complete')
953449
def find_release(package, releases, dependencies=None):
    """"""
    dependencies = dependencies if dependencies is not None else {}
    for release in releases:
        url = release['url']
        old_priority = dependencies.get(package, {}).get('priority', 0)

        for suffix, priority in SUFFIXES.items():
            if url.endswith(suffix):
                if old_priority < priority:
                    sha256 = release['digests']['sha256']
                    dependencies[package] = {
                        'package': package,
                        'url': url,
                        'sha256': sha256,
                        'priority': priority,
                    }

    return dependencies[package]
1019798
public static List<ResourceRoot> allResourceRoots(DeploymentUnit deploymentUnit) {
        List<ResourceRoot> roots = new ArrayList<ResourceRoot>();
        // not all deployment units have a deployment root
        final ResourceRoot deploymentRoot = deploymentUnit.getAttachment(Attachments.DEPLOYMENT_ROOT);
        if (deploymentRoot != null)
            roots.add(deploymentRoot);
        roots.addAll(deploymentUnit.getAttachmentList(Attachments.RESOURCE_ROOTS));
        return roots;
    }
641495
public static void findSourceFiles(List<SourceLocation> sourceLocations,
                                       Set<String> sourceTypes,
                                       Map<String,Source> foundFiles,
                                       Map<String, Module> foundModules,
                                       Module currentModule,
                                       boolean permitSourcesInDefaultPackage,
                                       boolean inLinksrc)
                                               throws IOException {

        for (SourceLocation source : sourceLocations) {
            source.findSourceFiles(sourceTypes,
                                   foundFiles,
                                   foundModules,
                                   currentModule,
                                   permitSourcesInDefaultPackage,
                                   inLinksrc);
        }
    }
96147
def missing_dependencies
      missing = []
      dependency_versions(:recursive => false).each do |pkg, target_versions|
        found = false
        target_versions.each do |_target, versions|
          dependency = dependency_for(pkg)
          found = versions.any? { |version| dependency.match?(pkg, version) }
        end
        missing << pkg unless found
      end
      missing
    end
1118963
def get_data_urls(deployment_name,
                  endpoint_type='juttle',
                  token_manager=None,
                  app_url=defaults.APP_URL):
    
    deployment_details = deployments.get_deployment_details(deployment_name,
                                                            token_manager=token_manager,
                                                            app_url=app_url)

    # use a random juttle endpoint
    data_urls = []
    for endpoint in deployment_details['endpoints']:
        if endpoint_type in endpoint['type']:
            data_urls.append(endpoint['uri'])

    if len(data_urls) == 0:
        raise JutException('No data engine currently configured for '
                           'deployment "%s"' % deployment_name)

    return data_urls
1330109
function getAllDependencies() {
    var folder = './' + getBowerFolder();
    var bowerDependencies = fs.readdirSync(folder, {encoding: 'utf8'});

    var dependencyInfos = [];
    bowerDependencies.forEach(function(dirname) {
        var filepath = nodePath.resolve(cwd, folder, dirname, '.bower.json');
        if (fs.existsSync(filepath)) {
            var dependencyInfo = getDependency(filepath);
            dependencyInfo.dirName = dirname;
            dependencyInfos.push(dependencyInfo);
        }
    });

    return dependencyInfos;
}
212911
def list_deployments(self):
        
        response = self._do_request('GET', '/v2/deployments')
        return self._parse_response(response, MarathonDeployment, is_list=True)
1195905
function () {
      var getConflictingDependencies = function (dependencies) {
        var conflicts = [];
        if (!dependencies) {
          return conflicts;
        }
        // for each dependency, extract and check the qualified artifactId
        dependencies.forEach(function (dependency) {
          function filterByDependencyString (dep) {
            return typeof dependency === 'string' ? dependency === dep : _.isEqual(dependency, dep);
          }

          var arrayOfEqualDependencies = dependencies.filter(
            filterByDependencyString);

          // find dependency in conflicts if dependency is n object
          var findedDep;
          if (typeof dependency === 'object') {
            findedDep = conflicts.find(function (dep) {
              return dep.artifactId === dependency.artifactId && dep.webpackageId === dependency.webpackageId && dep.endpointId === dependency.endpointId;
            });
          }
          if (arrayOfEqualDependencies.length > 1 && conflicts.indexOf(dependency) < 0 && !findedDep) {
            conflicts.push(dependency);
          }
        });
        return conflicts;
      };

      var doUniqueDependenciesCheck = function (artifact) {
        var conflictingDependencies = [];
        if (doc.modelVersion.indexOf('8.') === 0) { // we do have at least one endpoints for each artifact (modelVersion 8.x.x)
          // for each artifacts endpoint, check it's dependencies
          artifact.endpoints.forEach(function (endpoint) {
            conflictingDependencies = endpoint.dependencies ? getConflictingDependencies(endpoint.dependencies) : [];

            conflictingDependencies.forEach(function (dependency) {
              errors.push('RuleViolation identified: Artifact \'' + artifact.artifactId + '\' / endpoint \'' +
                endpoint.endpointId + '\' contains multiple references to dependency \'' + dependency +
                '\'');
            });
          });
        } else { // we don't have endpoints in artifact (modelVersion 9.x.x)
          // for each artifact, check it's dependencies
          conflictingDependencies = artifact.dependencies ? getConflictingDependencies(artifact.dependencies) : [];

          conflictingDependencies.forEach(function (dependency) {
            var dependencyStr = typeof dependency === 'object' ? JSON.stringify(dependency) : dependency;
            errors.push('RuleViolation identified: Artifact \'' + artifact.artifactId +
              '\' contains multiple references to dependency \'' + dependencyStr + '\'');
          });
        }
      };
      //
      var allArtifacts = [];
      // collect artifacts
      if (doc.artifacts) {
        var artifactTypes = Object.keys(doc.artifacts);
        artifactTypes.forEach(function (artifactType) {
          allArtifacts = allArtifacts.concat(doc.artifacts[ artifactType ]);
        });
      }
      // call rule for each artifact
      allArtifacts.forEach(function (artifact) {
        if (artifact.endpoints || artifact.dependencies) {
          doUniqueDependenciesCheck(artifact);
        }
      });
    }
1007247
def get_dependencies(self):
        """"""
        # pylint: disable=no-member
        return super().get_dependencies() + [
            Data.collection_set,
            Data.entity_set,
            Data.parents,
        ]
898380
async function getPkgReleases({ lookupName, registryUrls }) {
  const versions = [];
  const dependency = getDependencyParts(lookupName);
  if (!is.nonEmptyArray(registryUrls)) {
    logger.error(`No repositories defined for ${dependency.display}`);
    return null;
  }
  const repositories = registryUrls.map(repository =>
    repository.replace(/\/?$/, '/')
  );
  logger.debug(
    `Found ${repositories.length} repositories for ${dependency.display}`
  );
  const repoForVersions = {};
  for (let i = 0; i < repositories.length; i += 1) {
    const repoUrl = repositories[i];
    logger.debug(
      `Looking up ${dependency.display} in repository #${i} - ${repoUrl}`
    );
    const mavenMetadata = await downloadMavenXml(
      dependency,
      repoUrl,
      'maven-metadata.xml'
    );
    if (mavenMetadata) {
      const newVersions = extractVersions(mavenMetadata).filter(
        version => !versions.includes(version)
      );
      const latestVersion = getLatestVersion(newVersions);
      if (latestVersion) {
        repoForVersions[latestVersion] = repoUrl;
      }
      versions.push(...newVersions);
      logger.debug(`Found ${newVersions.length} new versions for ${dependency.display} in repository ${repoUrl}`); // prettier-ignore
    }
  }

  if (versions.length === 0) {
    logger.info(`No versions found for ${dependency.display} in ${repositories.length} repositories`); // prettier-ignore
    return null;
  }
  logger.debug(`Found ${versions.length} versions for ${dependency.display}`);
  const latestVersion = getLatestVersion(versions);
  const repoUrl = repoForVersions[latestVersion];
  const dependencyInfo = await getDependencyInfo(
    dependency,
    repoUrl,
    latestVersion
  );

  return {
    ...dependency,
    ...dependencyInfo,
    releases: versions.map(v => ({ version: v })),
  };
}
330529
function getAllDependencies(allVariables, currentKey, dependencies = new Set()) {

    if (!allVariables[currentKey].dependencies.length) {

        dependencies.add(`${currentKey}: ${allVariables[currentKey].value}`);
        return Array.from(dependencies);
    } else {

        allVariables[currentKey].dependencies.forEach(dependecy => {
            getAllDependencies(allVariables, dependecy, dependencies).forEach(newDependency => dependencies.add(newDependency));
        });

        dependencies.add(`${currentKey}: ${allVariables[currentKey].value}`);
        return Array.from(dependencies);
    }
}