Giter Site home page Giter Site logo

abf-console-client's Introduction

INTRO

Console client lets you work with ABF without web-interface. It can manage git repositories, check build-task status, create new build-task and so on.

BUILD

--arch (-a), can be set more than once.

Architecture to build with. If not set,

--save-to-repository (-s)
Repository to save built packages to. Packages will be published here.


--commit (-c), --branch (-b) and --tag (-t)

API takes git commit hash to build. So client have to resolve it.
1) If you've specified hash - it will be used "as is".
2) If you've specified branch or tag name - it will be resolved automatically using ABF API. (the hash of top commit will be used for branch)
3) If you've specified no git commit related options and you've specified a project name - this project's default branch will be used.
4) If you've specified no git commit related options and you've not specified a project name (you have to be in a git repository) - the top remote commit of your current branch will be used.

abf-console-client's People

Contributors

avokhmin avatar dsilakov avatar duratarskeyk avatar fedya avatar mikhailnov avatar pro-pra avatar stickler-ci avatar termim avatar tpgxyz avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

abf-console-client's Issues

abf put does not work

В спеке:
Source0: https://github.com/carlobaldassi/liblqr/archive/v%{version}.tar.gz?/liblqr-%{version}.tar.gz
делаю abf put клиентом из ОМА (rpm4), пишет:
File liblqr-0.4.2.tar.gz not found or empty, URL will be used instead. Skipping.
через rosa2016.1 работает
Что он хочет?

[email protected]: Permission denied (publickey).

nikolanp@rosa2021 ~> abf get blacksaber/Serviio -b master
Схема файла конфигурации была изменена либо файл поврежден, перезапускаем настройку конфигурации
ABF URL [https://abf.rosalinux.ru]:
User [nikolanp]: blacksaber
Password:
Default project branch [master]:
Default project owner [blacksaber]:
Default platform [rosa2021.1]:
File-store URL [https://file-store.rosalinux.ru]:
Default publishing status for new builds [default]:
Конфигурация успешно завершена
Теперь вы можете запустить "abf locate update-recursive -d PATH", где PATH - это ваша директория с клонированными проектами ABF. Это позволит вам использовать команду "abfcd " для перехода в директорию проекта.

Клонирование в «Serviio»…
[email protected]: Permission denied (publickey).
fatal: Не удалось прочитать из внешнего репозитория.

Удостоверьтесь, что у вас есть необходимые права доступа
и репозиторий существует.
nikolanp@rosa2021 ~ [1]>

abf rpmbduild fails on downloading sources

abf rpmbduild fails to download sources, while abf fetch works

[root@tpg-80xl tpg]# rpm -qf $(command -v abf)
abf-console-client-3.0.2.4-1.noarch

[tpg@tpg-80xl dnf]$ LC_ALL=C abf rpmbuild
Fetching file dnf-4.2.15.tar.gz
stty: 'standard input': Inappropriate ioctl for device
Size: 2 MB
Saving as: /home/tpg/OpenMandriva/dnf/dnf-4.2.15.tar.gz
ERROR: not enough values to unpack (expected 2, got 0) [http://file-store.openmandriva.org/api/v1/file_stores/0777a1e7c9c9c02659fd6ed4e1b02f6f251fcad9]
Executing rpmbuild...
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.owoWEm
+ umask 022
+ cd /tmp/abf/rpmbuild/BUILD
+ '[' 1 -eq 1 ']'
+ '[' 1 -eq 1 ']'
+ '[' 1 -eq 1 ']'
+ cd /tmp/abf/rpmbuild/BUILD
+ rm -rf dnf-4.2.15
+ /usr/bin/gzip -dc /tmp/abf/rpmbuild/dnf-4.2.15.tar.gz
+ /bin/tar -xof -
gzip: skipping: /tmp/abf/rpmbuild/dnf-4.2.15.tar.gz: corrupted -- incomplete deflate data
gzip: abort: internal threads error
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd dnf-4.2.15
/var/tmp/rpm-tmp.owoWEm: line 40: cd: dnf-4.2.15: No such file or directory
error: Bad exit status from /var/tmp/rpm-tmp.owoWEm (%prep)
    Bad exit status from /var/tmp/rpm-tmp.owoWEm (%prep)

Macros inside Source are expanded incorrectly

Берем такой спек:

%global goipath github.com/OpenPrinting/goipp
%global golicenses LICENSE
%global godocs README.md index.md

Summary:	IPP core protocol in pure Go (RFC 8010)
Name:		golang-github-openprinting-goipp
Group:		Development/Other
License:	BSD
Version:	1.0.0
Release:	1
Url:		%{gourl}
Source0:	%{gosource}
BuildRequires:	go-srpm-macros
%gometa

%description
Package goipp implements the IPP core protocol in pure Go (RFC 8010).

%gopkg
%gopkgfiles

#-----------------------------------------------------------------------

%prep
%goprep

%install
%gopkginstall

%check
%gocheck

Делаем spectool -g *.spec - работает, делаем abf put - не работает:
$ abf put -n
ошибка: файл %{gosource} (Source0) не существует, пропускаем!
При загрузке произошли ошибки, останавливаем работу.

Оно, наверное, как-то неродными для rpm средствами распарсивает спек.

Рассинхрон архитектур на abf.io и здесь

При запуске сборки на ABF и через клиент:

  • порядок архитектур разный, т.е., например, второй по счету сборочный лист получается разных архитектур
  • e2k включен на abf, в клиенте его нет

image

[FR] Add upload progress indicator

abf fetch has a progress indicator but abf put does not. When uploding large files like sources of chromium browser, it would be a bit useful to see the progress.

abf fetch/rpmbuild downloads from file-store slowly

Example:

git clone https://abf.io/import/kernel-5.10 -b rosa2019.1
cd kernel-5.10
abf rpmbuild

Download speed will be 150-250 KB/s, but direct wget/curl/etc from file-store.rosalinux.ru is up to 6 MB/s.

To set up a default configuration file, symbolic link in /etc/abf/mock/configs have to be created. I need sudo rights to do it.

To set up a default configuration file, symbolic link in /etc/abf/mock/configs have to be created. I need sudo rights to do it.

So i execute it with sudo:

[tpg@tpg-virtualbox gc]$ sudo abf mock -c cooker-x86_64-main.cfg
[sudo] hasło użytkownika tpg: 
Traceback (most recent call last):
  File "/usr/bin/abf", line 1725, in <module>
    from abf.console.misc import *
  File "/usr/lib/python3.8/site-packages/abf/console/misc.py", line 20, in <module>
    log = Log('models')
  File "/usr/lib/python3.8/site-packages/abf/console/log.py", line 27, in __init__
    logging.config.fileConfig(os.path.expanduser(conf_path))
  File "/usr/lib64/python3.8/logging/config.py", line 71, in fileConfig
    formatters = _create_formatters(cp)
  File "/usr/lib64/python3.8/logging/config.py", line 104, in _create_formatters
    flist = cp["formatters"]["keys"]
  File "/usr/lib64/python3.8/configparser.py", line 960, in __getitem__
    raise KeyError(key)
KeyError: 'formatters'

add a spec build with the mock command

[nikolanp@rosa2021 RyzenAdj]$ abf mock
Traceback (most recent call last):
File "/usr/bin/abf", line 1783, in
command_line.func()
File "/usr/bin/abf", line 540, in localbuild_mock_urpm
find_spec_problems()
File "/usr/lib/python3.8/site-packages/abf/console/misc.py", line 259, in find_spec_problems
res = get_project_data(spec_path)
File "/usr/lib/python3.8/site-packages/abf/console/misc.py", line 99, in get_project_data
rpm_spec = parse_spec_silently(ts, spec_path)
File "/usr/lib/python3.8/site-packages/abf/console/misc.py", line 70, in parse_spec_silently
rpm_spec = ts.parseSpec(spec_path)
File "/usr/lib64/python3.8/site-packages/rpm/transaction.py", line 45, in parseSpec
return rpm.spec(specfile)
ValueError: can't parse specfile

[nikolanp@rosa2021 RyzenAdj]$

Incorrect return code

mikhailnov@hp-xfce ~ $ abf publish 4635901
Публикуется проект 4635901...
Не могу опубликовать задачу 4635901: Access violation to this page!
mikhailnov@hp-xfce ~ $ echo $?
0

[FR] add rpmbuild -p

Currently abf rpmbuild can run rpmbuild -bb and rpmbuild -bs, please add running rpmbuild -bp as abf rpmbuild -b p to quickly check appliability of patches.

Connection problems (or intermittent errors) stop chain_builds

Using abf chain_build on a long list of packages (e.g. an update of all KDE packages) frequently results in e.g.

345217 (openmandriva/qt5-qtbase:x86_64 - build started)
Internal server error: it has returned non-json data. 

where the "Internal server error" is a temporary connection problem or a temporary server outage (e.g. timeout).
At that point, the chain_build stops and is hard to resume (edit the file list to remove all items that have already been built; make sure everything that was in the queue at the same time finished successfully, ...)

It would be nice to retry instead of aborting the entire chain_build at a problem that probably is none.

abf publish does not work (with ROSA ABF)

[user@rosa2019 tmp]$ abf publish -v 3836974
2021-08-13 01:29:51,785 DEBUG in abf:publish:1474: PUBLISH started
2021-08-13 01:29:51,786 DEBUG in model.py:init:88: Загружается BuildList 3836974 с использованием API
2021-08-13 01:29:51,786 DEBUG in model.py:get_init_data:506: Чтение данных о сборочном листе 3836974
2021-08-13 01:29:51,786 DEBUG in jsn.py:get_url_contents:145: Скачиваем ссылку https://abf.rosalinux.ru/api/v1/build_lists/3836974.json
2021-08-13 01:29:51,789 DEBUG in jsn.py:get_url_contents:165: Найдено в кэше! ETag: W/"a98d397c88c03080f15f984c0446f45c"
2021-08-13 01:29:52,261 DEBUG in jsn.py:get_url_contents:177: Получаем результат из кэша (кэш был проверен на актуальность)
2021-08-13 01:29:52,267 DEBUG in model.py:init:103: Создается заглушка для Project 181158
2021-08-13 01:29:52,268 DEBUG in model.py:init:103: Создается заглушка для Arch 7
2021-08-13 01:29:52,268 DEBUG in model.py:init:103: Создается заглушка для Repository 4328
2021-08-13 01:29:52,269 DEBUG in model.py:init:103: Создается заглушка для Platform 4084
2021-08-13 01:29:52,269 DEBUG in model.py:init:103: Создается заглушка для Platform 4084
2021-08-13 01:29:52,270 DEBUG in model.py:init:103: Создается заглушка для Repository 4327
2021-08-13 01:29:52,270 DEBUG in model.py:init:103: Создается заглушка для Platform 4084
2021-08-13 01:29:52,271 DEBUG in model.py:init:103: Создается заглушка для Repository 4328
2021-08-13 01:29:52,271 DEBUG in model.py:init:103: Создается заглушка для Platform 4084
2021-08-13 01:29:52,272 INFO in model.py:publish:654: Публикуется проект 3836974...
2021-08-13 01:29:52,272 DEBUG in jsn.py:get_url_contents:145: Скачиваем ссылку https://abf.rosalinux.ru/api/v1/build_lists/3836974/publish.json
2021-08-13 01:29:52,573 DEBUG in jsn.py:get_url_contents:179: Код возврата: 404
2021-08-13 01:29:52,579 ERROR in jsn.py:process_response:123: Неизветсная ошибка сервера: Ошибка 404. Страница не найдена!
2021-08-13 01:29:52,580 ERROR in abf:publish:1483: Не могу опубликовать задачу 3836974: Ошибка 404. Страница не найдена!

Makefile does not work on Dragonfly BSD

[root@nas-dfly ~/abf-console-client]# make DESTDIR=/tmp/abf-test install
mkdir -p /tmp/abf-test/lib/python/site-packages /tmp/abf-test/usr/bin /tmp/abf-test/usr/share/man/man1
cp -p --parents abf/console/*.py abf/*.py abf/api/*.py /tmp/abf-test/lib/python/site-packages
cp: illegal option -- -
usage: cp [-R [-H | -L | -P]] [-f | -i | -n] [-alpvx] source_file target_file
       cp [-R [-H | -L | -P]] [-f | -i | -n] [-alpvx] source_file ... target_directory
*** Error code 64

Stop.
make: stopped in /root/abf-console-client
[root@nas-dfly ~/abf-console-client]# uname -a
DragonFly nas-dfly 5.6-RELEASE DragonFly v5.6.1.3.gabd682-RELEASE #0: Sun Jun 23 01:20:29 MSK 2019     root@nas-dfly:/usr/obj/usr/src/sys/X86_64_GENERIC  x86_64
[root@nas-dfly ~/abf-console-client]# 

abf does not recognize sources from .abf.yml

abf does not recognize sources from .abf.yml


[tpg@tpg-80xl kernel-release-clang]$ abf put -m "new version 5.3.11"
Traceback (most recent call last):
  File "/usr/bin/abf", line 1769, in <module>
    command_line.func()
  File "/usr/bin/abf", line 817, in put
    error_count = upload_files(models, min_size, remove_files=not command_line.do_not_remove_files, path=path, upload_all=command_line.upload_all)
  File "/usr/lib/python3.7/site-packages/abf/console/misc.py", line 546, in upload_files
    filesize = os.stat(source).st_size
FileNotFoundError: [Errno 2] No such file or directory: 'patch-5.3.11.xz'

После переустановки перестал работать и нет авторизации под пользователем

nikolanp@rosa2021 ~> abf get blacksaber/blacksaber_repo -b master
Клонирование в «blacksaber_repo»…
X11 forwarding request failed on channel 0
nikolanp@rosa2021 ~> cd /home/nikolanp/blacksaber_repo
nikolanp@rosa2021 ~/blacksaber_repo (master)> abf put -m "Add my repo"
Traceback (most recent call last):
File "/usr/bin/abf", line 1783, in
command_line.func()
File "/usr/bin/abf", line 825, in put
error_count = upload_files(models, min_size, remove_files=not command_line.do_not_remove_files, path=path, upload_all=command_line.upload_all)
File "/usr/lib/python3.8/site-packages/abf/console/misc.py", line 574, in upload_files
sha_hash = models.jsn.upload_file(source)
File "/usr/lib/python3.8/site-packages/abf/api/jsn.py", line 260, in upload_file
res = self.get_file_info_by_hash(sha_hash)
File "/usr/lib/python3.8/site-packages/abf/api/jsn.py", line 309, in get_file_info_by_hash
return self.get_url_contents(URL, GET=GET, file_store=True)
File "/usr/lib/python3.8/site-packages/abf/api/jsn.py", line 196, in get_url_contents
cache_etags.put(url, etag_new)
File "/usr/lib/python3.8/site-packages/beaker/cache.py", line 317, in put
self._get_value(key, **kw).set_value(value)
File "/usr/lib/python3.8/site-packages/beaker/container.py", line 409, in set_value
self.namespace.acquire_write_lock()
File "/usr/lib/python3.8/site-packages/beaker/container.py", line 220, in acquire_write_lock
r = self.access_lock.acquire_write_lock(wait)
File "/usr/lib/python3.8/site-packages/beaker/synchronization.py", line 186, in acquire_write_lock
x = self.do_acquire_write_lock(wait)
File "/usr/lib/python3.8/site-packages/beaker/synchronization.py", line 261, in do_acquire_write_lock
filedescriptor = self._open(os.O_CREAT | os.O_WRONLY)
File "/usr/lib/python3.8/site-packages/beaker/synchronization.py", line 242, in _open
filedescriptor = os.open(self.filename, mode)
PermissionError: [Errno 13] Permission denied: '/tmp/abf_cache/etags/7/75/751ebf2d42780d2581ffd420d6a310f866cdcc67.lock'
nikolanp@rosa2021 ~/blacksaber_repo (master) [1]> sudo abf mock
[sudo] пароль для nikolanp:
Авторизация не удалась. Неверный логин или пароль
nikolanp@rosa2021 ~/blacksaber_repo (master)>
пароля на пользователе нет.
nikolanp@rosa2021 ~> rpm -qa | grep abf
python3-abf-3.0.3.6-1.noarch
abf-console-client-3.0.3.6-1.noarch
nikolanp@rosa2021 ~
Операционная система: ROSA Fresh Desktop 2021.1
Версия KDE Plasma: 5.22.5
Версия KDE Frameworks: 5.86.0
Версия Qt: 5.15.2
Версия ядра: 5.10.74-generic-2rosa2021.1-x86_64 (64-бита)
Графическая платформа: X11
Процессоры: 6 × AMD FX(tm)-6300 Six-Core Processor
Память: 7,7 ГиБ ОЗУ
Графический процессор: NVC1

[FR] abf chain_publish

ОЧЕНЬ не хватает abf chain_publish, который бы автоматически последовательно публиковал цепочку контейнеров. Вот как публиковать https://bugzilla.rosalinux.ru/show_bug.cgi?id=13169 и https://abf.io/build_lists/4387643 из него? Упороться же можно, было бы круто скомандовать: "abf chain_publish 4387643", — а оно пусть само выстроит цепочку и публикует ее.

[FR]добавить в клиент возможность управления ветками

Здравствуйте. Очень не удобно постоянно переключаться между гитом и abf-console-client. Если создаю гитом ветку, то гитом должен её коммитить и отправить. А до этого abf не срабатывает на сборку, так, как ветку не видит. Тогда нужно добавить в abf данную возможность.

портировал на 2016.1

saber716rus@saber716rus-VirtualBox ~> abf get -b rosa2016.1 blacksaber/abf-console-client

Traceback (most recent call last):

File "/usr/bin/abf", line 23, in

  from abf.console.config import Config, mkdirs

ImportError: No module named 'abf'

saber716rus@saber716rus-VirtualBox ~>

abf publish does not work

$ abf publish 3951304

Публикуется проект 3951304...
Неизветсная ошибка сервера: Ошибка 404. Страница не найдена!
Не могу опубликовать задачу 3951304: Ошибка 404. Страница не найдена!
Внутренняя ошибка сервера: он вернул данные не в формате json.

Руками при этом из веб-морды опубликовать смог.

i686 not build for rosa2019.1

Fow some reasone now abf build -b rosa2019.1 -p import/dos2unix does not start a build for i686:

[user@1 dracut]$ abf build -b rosa2019.1 -p import/dos2unix
Выбраны репозитории, подключаемые для сборки: [rosa2019.1/main]
Выбраны архитектуры: [x86_64, aarch64]
Сборочное задание import/dos2unix|rosa2019.1|rosa2019.1/main|x86_64 успешно запущено. Идентификатор задания - 3691005
Сборочное задание import/dos2unix|rosa2019.1|rosa2019.1/main|aarch64 успешно запущено. Идентификатор задания - 3691006
[user@1 dracut]$ 

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.