Get project info
485002
def get_project(self, project_id):
        
        try:
            result = self._request('/getproject/',
                                   {'projectid': project_id})
            return TildaProject(**result)
        except NetworkError:
            return []
333443
def get_project_filenames(self):
        """"""
        recent_files = []
        if self.current_active_project:
            recent_files = self.current_active_project.get_recent_files()
        elif self.latest_project:
            recent_files = self.latest_project.get_recent_files()
        return recent_files
44872
def get_project(self, project_id):
        
        try:
            return self._projects[project_id]
        except KeyError:
            raise aiohttp.web.HTTPNotFound(text="Project ID {} doesn't exist".format(project_id))
1172327
public CollectionRequest<ProjectStatus> findByProject(String project) {

        String path = String.format("/projects/%s/project_statuses", project);
        return new CollectionRequest<ProjectStatus>(this, ProjectStatus.class, path, "GET");
    }
555221
def get_project_resources(self, project, type=None, id=None):
        
        route_values = {}
        if project is not None:
            route_values['project'] = self._serialize.url('project', project, 'str')
        query_parameters = {}
        if type is not None:
            query_parameters['type'] = self._serialize.query('type', type, 'str')
        if id is not None:
            query_parameters['id'] = self._serialize.query('id', id, 'str')
        response = self._send(http_method='GET',
                              location_id='398c85bc-81aa-4822-947c-a194a05f0fef',
                              version='5.0-preview.1',
                              route_values=route_values,
                              query_parameters=query_parameters)
        return self._deserialize('[DefinitionResourceReference]', self._unwrap_collection(response))
919527
@RequestMapping(value = "", method = RequestMethod.GET)
    public Resource<Info> info() {
        return Resource.of(
                infoService.getInfo(),
                uri(on(getClass()).info())
        )
                // API links
                .with("user", uri(on(UserController.class).getCurrentUser()))
                        // TODO Structure controller (--> projects, branches, etc.)
                        // Info message
                .with("_applicationInfo", uri(on(InfoController.class).applicationInfo()))
                ;
    }
416399
function getUserSharedProjects(user) {
		return userProject.findOne({'username': user}, 'sharedProjects')
		.then(function(doc) {
			if (!doc) {
				return undefined;
			}
			var projects = doc.sharedProjects;
			projects = projects.map(function(project) {
				var name = path.win32.basename(project);
				return {'Name': name, 'Location': project};
			});
			return projects;
		});
	}
43417
def info(self):
        """"""

        return self._h._get_resource(
            resource=('apps', self.name),
            obj=App,
        )
576736
def get_projects(self, **kwargs):
        

        _login = kwargs.get('login', self._login)
        search_url = SEARCH_URL.format(login=_login)
        return self._request_api(url=search_url).json()
709723
def get_project(username, project, machine_name=None):
    

    try:
        account = Account.objects.get(
            username=username,
            date_deleted__isnull=True)
    except Account.DoesNotExist:
        return "Account '%s' not found" % username

    if project is None:
        project = account.default_project
    else:
        try:
            project = Project.objects.get(pid=project)
        except Project.DoesNotExist:
            project = account.default_project

    if project is None:
        return "None"

    if account.person not in project.group.members.all():
        project = account.default_project

    if project is None:
        return "None"

    if account.person not in project.group.members.all():
        return "None"

    return project.pid
399372
def get_project_details(project):
    
    result = []
    for datastore in _get_datastores():
        value = datastore.get_project_details(project)
        value['datastore'] = datastore.config['DESCRIPTION']
        result.append(value)
    return result
629437
def get(project, credentials=None):
        """"""
        user, oauth_access_token = parsecredentials(credentials)
        if not Project.exists(project, user):
            return withheaders(flask.make_response("Project " + project + " was not found for user " + user,404) ,headers={'allow_origin': settings.ALLOW_ORIGIN})#404
        else:
            #if user and not Project.access(project, user) and not user in settings.ADMINS:
            #    return flask.make_response("Access denied to project " +  project + " for user " + user, 401) #401
            datafile = os.path.join(Project.path(project,credentials),'clam.xml')
            statuscode, statusmsg, statuslog, completion = Project.status(project, user) #pylint: disable=unused-variable
            if statuscode == clam.common.status.DONE and os.path.exists(datafile):
                f = io.open(datafile,'r',encoding='utf-8')
                xmldata = f.read(os.path.getsize(datafile))
                f.close()
                data = clam.common.data.CLAMData(xmldata, None,False, Project.path(project,credentials), loadmetadata=False)
                return Project.response(user, project, settings.PARAMETERS,"",False,oauth_access_token,','.join([str(x) for x in data.program.matchedprofiles]) if data.program else "", data.program) #200
            else:
                #HTTP request parameters may be used to pre-set global parameters when starting a project (issue #66)
                for parametergroup, parameterlist in settings.PARAMETERS: #pylint: disable=unused-variable
                    for parameter in parameterlist:
                        value = parameter.valuefrompostdata(flask.request.values)
                        if value is not None:
                            parameter.set(value)
                return Project.response(user, project, settings.PARAMETERS,"",False,oauth_access_token)
604779
def get_project(id=None, name=None):
    
    content = get_project_raw(id, name)
    if content:
        return utils.format_json(content)
1112578
def on_select_task(self, task):
        ''''''
        # inject informations about project
        logger.info('select %(project)s:%(taskid)s %(url)s', task)

        project_info = self.projects.get(task['project'])
        assert project_info, 'no such project'
        task['type'] = self.TASK_PACK
        task['group'] = project_info.group
        task['project_md5sum'] = project_info.md5sum
        task['project_updatetime'] = project_info.updatetime

        # lazy join project.crawl_config
        if getattr(project_info, 'crawl_config', None):
            task = BaseHandler.task_join_crawl_config(task, project_info.crawl_config)

        project_info.active_tasks.appendleft((time.time(), task))
        self.send_task(task)
        return task
523434
def get_project() -> Optional[str]:
    
    project = SETTINGS.project
    if not project:
        require_test_mode_enabled()
        raise RunError('Missing project name; for test mode, please set PULUMI_NODEJS_PROJECT')
    return project
78508
def get_job_log_url(self, project, **params):
        
        return self._get_json(self.JOB_LOG_URL_ENDPOINT, project,
                              **params)
1264560
def funding_info(self, key, value):
    """"""
    return {
        'agency': value.get('a'),
        'grant_number': value.get('c'),
        'project_number': value.get('f'),
    }