Невозможно установить атрибут проекта gitlab с помощью python-gitlab 4.11.1Python

Программы на Python
Ответить Пред. темаСлед. тема
Anonymous
 Невозможно установить атрибут проекта gitlab с помощью python-gitlab 4.11.1

Сообщение Anonymous »

Я пытаюсь реализовать приложение Python для установки контейнера_expiration_policy проекта GitLab. Мой код выглядит так:

Код: Выделить всё

update_project = gl.projects.get(projectId)
update_project.container_expiration_policy = json_data

result = update_project.save()
print(result)
Я получил следующую ошибку:

Код: Выделить всё

gitlab.exceptions.GitlabUpdateError: 400: allow_merge_on_skipped_pipeline, analytics_access_level, autoclose_referenced_issues, auto_devops_enabled, auto_devops_deploy_strategy, auto_cancel_pending_pipelines, build_git_strategy, build_timeout, builds_access_level, ci_config_path, ci_default_git_depth, ci_allow_fork_pipelines_to_run_in_parent_project, ci_forward_deployment_enabled, ci_forward_deployment_rollback_allowed, ci_separated_caches, container_registry_access_level, container_expiration_policy_attributes, default_branch, description, emails_disabled, emails_enabled, forking_access_level, issues_access_level, lfs_enabled, merge_pipelines_enabled, merge_requests_access_level, merge_requests_template, merge_trains_enabled, merge_method, name, only_allow_merge_if_all_discussions_are_resolved, only_allow_merge_if_pipeline_succeeds, pages_access_level, path, printing_merge_request_link_enabled, public_builds, public_jobs, remove_source_branch_after_merge, repository_access_level, request_access_enabled, resolve_outdated_diff_discussions, restrict_user_defined_variables, show_diff_preview_in_email, security_and_compliance_access_level, squash_option, shared_runners_enabled, group_runners_enabled, snippets_access_level, tag_list, topics, visibility, wiki_access_level, avatar, suggestion_commit_message, merge_commit_template, squash_commit_template, issue_branch_template, repository_storage, packages_enabled, service_desk_enabled, keep_latest_artifact, mr_default_target_self, enforce_auth_checks_on_uploads, releases_access_level, environments_access_level, feature_flags_access_level, infrastructure_access_level, monitor_access_level, model_experiments_access_level, model_registry_access_level, warn_about_potentially_unwanted_characters, ci_pipeline_variables_minimum_override_role, ci_push_repository_for_job_token_allowed, issues_enabled, jobs_enabled, merge_requests_enabled, wiki_enabled, snippets_enabled, container_registry_enabled, allow_pipeline_trigger_approve_deployment, only_allow_merge_if_all_status_checks_passed, approvals_before_merge, external_authorization_classification_label, fallback_approvals_required, import_url, issues_template, mirror, merge_requests_template, merge_pipelines_enabled, merge_trains_enabled, merge_trains_skip_train_allowed, requirements_access_level, prevent_merge_without_jira_issue, ci_restrict_pipeline_cancellation_role are missing, at least one parameter must be provided
При использованииContainer_expiration_policy_attributes я получаю сообщение об ошибке недопустимого атрибута.
Однако я могу использовать клиентский инструмент HTTP для обновления файлаContainer_expiration_policy_attributes проекта.
п>

Подробнее здесь: https://stackoverflow.com/questions/789 ... lab-4-11-1
Реклама
Ответить Пред. темаСлед. тема

Быстрый ответ

Изменение регистра текста: 
Смайлики
:) :( :oops: :roll: :wink: :muza: :clever: :sorry: :angel: :read: *x)
Ещё смайлики…
   
К этому ответу прикреплено по крайней мере одно вложение.

Если вы не хотите добавлять вложения, оставьте поля пустыми.

Максимально разрешённый размер вложения: 15 МБ.

  • Похожие темы
    Ответы
    Просмотры
    Последнее сообщение
  • Загрузите файл GitLab с помощью gitlab-python
    Anonymous » » в форуме Python
    0 Ответы
    31 Просмотры
    Последнее сообщение Anonymous
  • Как получить URL-адрес проекта по идентификатору проекта, используя библиотеку gitlab в Python
    Anonymous » » в форуме Python
    0 Ответы
    18 Просмотры
    Последнее сообщение Anonymous
  • Удалить файл из репозитория Gitlab с помощью gitlab-ci.yml
    Anonymous » » в форуме Python
    0 Ответы
    5 Просмотры
    Последнее сообщение Anonymous
  • Настройка файла .gitlab-ci.yml в Gitlab для тестирования кодов Python
    Anonymous » » в форуме Python
    0 Ответы
    99 Просмотры
    Последнее сообщение Anonymous
  • Подключиться к gitlab, используя gitlab java api
    Гость » » в форуме JAVA
    0 Ответы
    99 Просмотры
    Последнее сообщение Гость

Вернуться в «Python»