GithubHelp home page GithubHelp logo

aurman's People

Contributors

devnoname120 avatar dnswrsrx avatar eli-schwartz avatar lchris314 avatar mauladen avatar morganamilo avatar njfox avatar polygamma avatar saleemrashid avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

aurman's Issues

Enhancement request: Use $VISUAL for editing (if set) instead of $EDITOR

First of: Thank you for creating aurman, I think it is really a nifty tool and so far I enjoy using it very much!

One small idea that I had would be to allow usage of $VISUAL for editing PKGBUILDs instead of just $EDITOR, because I personally find a GUI editor to be much more comfortable than nano.

Thank you for considering this!

Output without arguments

Providing no arguments to aurman results in a wall of text that seems to be in markdown format. The output in that case should be something like aurman --help output. That would make usage a bit more readable.

Nice work, btw.

Edit: I've noticed that aurman --help just passes that argument to pacman. aurman should have its own help.

.reviewed file not found

It seems the .reviewed file is not created.

$ python main.py -Su
:: Starting full system upgrade...
 there is nothing to do
AUR Packages: nlohmann-json auracle-git
Repo Packages:
Do you want to install these packages? Y/n: y
Do you want to view the changes of PKGBUILD of nlohmann-json ? N/y: y
Do you want to edit PKGBUILD? N/y: y
Do you want to use the files as they are now? Y/n: y
2018-02-08 10:15:29,733 - main - <module> - ERROR - Unknown exception occurred.
Traceback (most recent call last):
  File "main.py", line 167, in <module>
    process(argv[1:])
  File "main.py", line 145, in process
    package.show_pkgbuild_install_files_to_user()
  File "/home/remy/code/aurman/src/package_classes.py", line 215, in show_pkgbuild_install_files_to_user
    with open(os.path.join(git_aurman_dir, ".reviewed"), "r") as f:
FileNotFoundError: [Errno 2] No such file or directory: '/home/remy/.cache/aurman/auracle-git/.git/aurman/.reviewed'

Issue when installing package when no non-repo are installed

I have a fresh installation of Archlinux, with no user packages installed.
It is exiting with the following error message
2018-01-31 18:38:17,759 - Utils - all_installed_not_repo_packages - INFO - could not fetch the list of installed aur packages

It seems that pacman -Qm is exiting with an exit code of 1, so the if condition here is failing.

I have fixed this locally by changing if pacman_return.returncode != 0 to if pacman_return.returncode not in [0,1]:

Support pacman wrappers

First of all, thanks for the great AUR helper! It would be really nice if aurman could support pacman wrappers: as it is right now, the call to pacman is hard-coded into wrappers.py (as far as I could tell).

Making this configurable by either an environmental variable (the pacaur way) or a config file (trizen/yay/etc. way) would allow the use of powerpill for example.

Edit: I'd also be happy to send a PR if you think it's a feature worth having but don't want to implement it yourself.

Handling of personal repos

I have a personal repo named "my". aurman does not handle it well.

~/paketierung/meine_Pakete/otf-ibm-plex $ LANG=C aurman -Suy
:: Synchronizing package databases...
core is up to date
extra is up to date
community is up to date
xyne-x86_64 is up to date
my is up to date
:: Starting full system upgrade...
there is nothing to do

analyzing installed packages...
fetching upstream repo packages...
2018-02-25 14:29:33,872 - main - main - ERROR -
Traceback (most recent call last):
File "/usr/lib/python3.6/site-packages/aurman/main.py", line 281, in main
process(argv[1:])
File "/usr/lib/python3.6/site-packages/aurman/main.py", line 140, in process
upstream_system = System(System.get_repo_packages())
File "/usr/lib/python3.6/site-packages/aurman/classes.py", line 836, in get_repo_packages
return Package.get_packages_from_expac("-S", (), PossibleTypes.REPO_PACKAGE)
File "/usr/lib/python3.6/site-packages/aurman/classes.py", line 264, in get_packages_from_expac
to_expand['repo']):
ValueError: 'my' is not in list

Streamline --devel source checkout and prompts

Not a bug, but a possible improvement.
When updating with $ python main.py -Su --devel --needed, the checkout of the sources is done between the prompts. This could be streamlined by asking all prompt first, then doing the checkout of the sources.

The drawback is that it is not easily possible to retrieve the exact new version of the packages in case you want to display it to the user, but this is a minor annoyance especially when --needed is used.

Ignore Package

Hi there, beeing able to ignore packages would be nice.
There already is an option in the pacman.conf to ignore a list of packages or whole groups.

Configurable cache directory

Cache directory is hardcoded in XDG_CACHE_HOME or ~/.cache/aurman. It would be great to be able to change it, says to /tmp/aurman without having to use a link.

Solver doesn't check versioning of repo providers correctly

aurman r257.f2ce5f5-1.

My system is fully up-to-date, and reinstalling a random AUR packages seem to requier removal of unrelated repo packages:

$ aurman -S pacaur-git

~~ analyzing installed packages...
~~ fetching upstream repo packages...
~~ fetching needed aur packages...
~~ fetching ignored packages...
~~ calculating solutions...

:: The following 2 package(s) are getting removed:
   community/intellij-idea-community-edition  2:2017.3.4-1          ->  /
   extra/jdk9-openjdk                         9.0.4.u11-1           ->  /

:: The following 1 package(s) are getting updated:
   aur/pacaur-git                             4.7.10.47.ga0f232d-1  ->  4.7.10-1
?? Do you want to continue? Y/n: n

The issue seems related to versioned providers. jdk9-openjdk provides java-environment=9, while intellij-idea-community-edition depends on java-environment.
As a side note, the package jre8-openjdk, providing java-runtime=8, is also installed (though it shouldn't matter here I guess).

With --deep_search, other repo packages need to be reinstalled for some reason:

$ aurman -S pacaur-git --deep_search

~~ analyzing installed packages...
~~ fetching upstream repo packages...
~~ fetching needed aur packages...
~~ fetching ignored packages...
~~ calculating solutions...

:: The following 2 package(s) are getting installed:
   aur/cower                                  /                      ->  17-2
   core/pacman                                /                      ->  5.0.2-2

:: The following 5 package(s) are getting removed:
   aur/cower-git                              17.5.g59ecf02-1        ->  /
   community/intellij-idea-community-edition  2:2017.3.4-1           ->  /
   extra/jdk9-openjdk                         9.0.4.u11-1            ->  /
   aur/pacman-contrib-git                     0.0.1.r25.g2a5fc09-1   ->  /
   aur/pacman-git                             5.0.1.223.ga7dbe463-1  ->  /

:: The following 1 package(s) are getting updated:
   aur/pacaur-git                             4.7.10.47.ga0f232d-1   ->  4.7.10-1

:: The following 73 package(s) are getting reinstalled:
   core/acl                                   2.2.52-4               ->  2.2.52-4
   core/archlinux-keyring                     20180108-1             ->  20180108-1
   core/attr                                  2.4.47-3               ->  2.4.47-3
   core/bash                                  4.4.019-1              ->  4.4.019-1
   core/bzip2                                 1.0.6-7                ->  1.0.6-7
   core/ca-certificates                       20170307-1             ->  20170307-1
   core/ca-certificates-cacert                20140824-4             ->  20140824-4
   core/ca-certificates-mozilla               3.35-1                 ->  3.35-1
   core/ca-certificates-utils                 20170307-1             ->  20170307-1
   core/coreutils                             8.29-1                 ->  8.29-1
   core/cracklib                              2.9.6-1                ->  2.9.6-1
   core/curl                                  7.58.0-1               ->  7.58.0-1
   core/db                                    5.3.28-3               ->  5.3.28-3
   core/e2fsprogs                             1.43.9-1               ->  1.43.9-1
   extra/expac                                8-1                    ->  8-1
   core/expat                                 2.2.5-1                ->  2.2.5-1
   core/filesystem                            2017.10-2              ->  2017.10-2
   core/findutils                             4.6.0-2                ->  4.6.0-2
   core/gcc-libs                              7.3.0-1                ->  7.3.0-1
   core/gdbm                                  1.14.1-1               ->  1.14.1-1
   extra/git                                  2.16.2-1               ->  2.16.2-1
   core/glib2                                 2.54.3+2+g94b38beff-1  ->  2.54.3+2+g94b38beff-1
   core/glibc                                 2.26-11                ->  2.26-11
   core/gmp                                   6.1.2-1                ->  6.1.2-1
   core/gnupg                                 2.2.5-1                ->  2.2.5-1
   core/gnutls                                3.5.18-1               ->  3.5.18-1
   core/gpgme                                 1.10.0-2               ->  1.10.0-2
   core/grep                                  3.1-1                  ->  3.1-1
   core/iana-etc                              20180221-1             ->  20180221-1
   core/keyutils                              1.5.10-1               ->  1.5.10-1
   core/krb5                                  1.16-1                 ->  1.16-1
   core/libarchive                            3.3.2-1                ->  3.3.2-1
   core/libassuan                             2.5.1-1                ->  2.5.1-1
   core/libcap                                2.25-1                 ->  2.25-1
   core/libffi                                3.2.1-2                ->  3.2.1-2
   core/libgcrypt                             1.8.2-1                ->  1.8.2-1
   core/libgpg-error                          1.27-1                 ->  1.27-1
   core/libidn                                1.33-2                 ->  1.33-2
   core/libidn2                               2.0.4-2                ->  2.0.4-2
   core/libksba                               1.3.5-1                ->  1.3.5-1
   core/libldap                               2.4.45-4               ->  2.4.45-4
   core/libnghttp2                            1.30.0-1               ->  1.30.0-1
   core/libpsl                                0.19.1-1               ->  0.19.1-1
   core/libsasl                               2.1.26-12              ->  2.1.26-12
   core/libsecret                             0.18.5+14+g9980655-1   ->  0.18.5+14+g9980655-1
   core/libssh2                               1.8.0-2                ->  1.8.0-2
   core/libtasn1                              4.13-1                 ->  4.13-1
   core/libtirpc                              1.0.2-3                ->  1.0.2-3
   core/libunistring                          0.9.8-1                ->  0.9.8-1
   core/libutil-linux                         2.31.1-1               ->  2.31.1-1
   core/linux-api-headers                     4.14.8-1               ->  4.14.8-1
   core/lz4                                   1:1.8.1.2-1            ->  1:1.8.1.2-1
   core/ncurses                               6.1-3                  ->  6.1-3
   core/nettle                                3.4-1                  ->  3.4-1
   core/npth                                  1.5-1                  ->  1.5-1
   core/openssl                               1.1.0.g-1              ->  1.1.0.g-1
   core/p11-kit                               0.23.9-1               ->  0.23.9-1
   core/pacman-mirrorlist                     20180224-1             ->  20180224-1
   core/pam                                   1.3.0-1                ->  1.3.0-1
   core/pambase                               20171006-1             ->  20171006-1
   core/pcre                                  8.41-1                 ->  8.41-1
   core/pcre2                                 10.31-1                ->  10.31-1
   core/perl                                  5.26.1-2               ->  5.26.1-2
   extra/perl-error                           0.17025-2              ->  0.17025-2
   core/pinentry                              1.1.0-1                ->  1.1.0-1
   core/readline                              7.0.003-1              ->  7.0.003-1
   core/shadow                                4.5-4                  ->  4.5-4
   core/sqlite                                3.22.0-1               ->  3.22.0-1
   core/sudo                                  1.8.22-1               ->  1.8.22-1
   core/tzdata                                2018c-1                ->  2018c-1
   core/xz                                    5.2.3-1                ->  5.2.3-1
   extra/yajl                                 2.1.0-1                ->  2.1.0-1
   core/zlib                                  1:1.2.11-2             ->  1:1.2.11-2
:: You are using --deep_search, hence --needed is active.
:: These packages will not actually be reinstalled.
?? Do you want to continue? Y/n:

Maybe that list of "reinstalled but actually not reinstalled" packages shouldn't be printed, unless it is actually useful in some way to the user(?)

Lack of important features

I am currently quite satisfied with aurman's development status, I can't think of any important missing features.

Can anyone else think of something I haven't thought of that really should be supported?

Continuous integration

I've seen that you have already some tests. It would be nice to have continuous integration into this project early on.

I did some preliminary work in this branch for pacaur project. There is a custom Docker image that could be adapted and Travis CI simple config. If you are interested I could give a hand with this.

Distribution not found

After the most recent update (2.9.19) I'm getting the following when I try to run aurman:

Traceback (most recent call last):
  File "/usr/bin/aurman", line 6, in <module>
    from pkg_resources import load_entry_point
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3088, in <module>
    @_call_aside
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3072, in _call_aside
    f(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3101, in _initialize_master_working_set
    working_set = WorkingSet._build_master()
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 574, in _build_master
    ws.require(__requires__)
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 892, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/usr/lib/python2.7/site-packages/pkg_resources/__init__.py", line 778, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'requests' distribution was not found and is required by aurman

A recent install (possibly ros-kinetic) may have set python2 as the default. I have reset the symlink /usr/bin/python back to python3 and python --version now is back to 3.6.4, but the above error persists. Maybe main.py needs a shebang?

Support -Si to retrieve package information

-i option is really useful to retrieve basic information of aur packages.

Description in pacman -S --help

  -i, --info           view package information (-ii for extended information)

Confusing help information

There are three commands with confusing information from aurman --help.
--domain name
--keyserver name
--holdpkg name
There are other options that also could use name, but this is confusing in any case. I would recommend removing name from all options.

In addition, I would capitalize the first letter of aurman exclusive options description to match native ones.

unable to run as user without prompting for sudo password

Hello,

I am unable to get aurman to run as my special aur_builder user without prompting for sudo password.

$ sudo -i -u aur_builder
[sudo] password for cgorichanaz: 
[aur_builder@CharlieDesktop18 ~]$ aurman -S --noconfirm --noedit --needed bash-completion
~~ initializing aurman...
~~ calculating solutions...

:: The following 1 package(s) are getting installed:
   extra/bash-completion  /  ->  2.8-1
~~ looking for new pkgbuilds and fetch them...
[sudo] password for aur_builder: 

yaourt works as expected:

[aur_builder@CharlieDesktop18 ~]$ yaourt -S --noconfirm --needed bash-completion
resolving dependencies...
looking for conflicting packages...

Packages (1) bash-completion-2.8-1

Total Installed Size:  0.78 MiB

:: Proceed with installation? [Y/n] 
(1/1) checking keys in keyring                     [######################] 100%
(1/1) checking package integrity                   [######################] 100%
(1/1) loading package files                        [######################] 100%
(1/1) checking for file conflicts                  [######################] 100%
(1/1) checking available disk space                [######################] 100%
:: Processing package changes...
(1/1) installing bash-completion                   [######################] 100%
:: Running post-transaction hooks...
(1/1) Arming ConditionNeedsUpdate...
[aur_builder@CharlieDesktop18 ~]$ 

/etc/sudoers:

## Ansible managed
##
## User privilege specification
##
root ALL=(ALL) ALL

%wheel ALL=(ALL) ALL
%wheel ALL=(ALL) NOPASSWD:/usr/bin/openvpn*

Defaults timestamp_timeout=1440

#includedir /etc/sudoers.d

/etc/sudoers.d/11-install-aur_builder:

aur_builder ALL=(ALL) NOPASSWD: /usr/bin/pacman

Note this issue still occurs with that last line set instead to aur_builder ALL=(ALL) NOPASSWD: ALL. I am not sure if I am missing something, as I would not expect to be prompted for the password at all with that setting.

If I go ahead and create a password for the user and then type the password at the prompt, the last few lines of output of sudo journalctl _COMM=sudo | grep aur_builder | tail are:

Mar 25 18:24:40 CharlieDesktop18 sudo[26064]: aur_builder : TTY=pts/0 ; PWD=/home/aur_builder ; USER=root ; COMMAND=validate
Mar 25 18:24:40 CharlieDesktop18 sudo[30424]: aur_builder : TTY=pts/0 ; PWD=/home/aur_builder ; USER=root ; COMMAND=/usr/bin/pacman --sync bash-completion --noconfirm --needed --asdeps
Mar 25 18:24:40 CharlieDesktop18 sudo[30452]: aur_builder : TTY=pts/0 ; PWD=/home/aur_builder ; USER=root ; COMMAND=/usr/bin/pacman -D --asexplicit bash-completion

I hoped to find it was calling some other program I needed to allow in the sudoers file, though that would not explain the NOPASSWD: ALL not working. I am not sure what COMMAND=validate is.

`noedit` in config file

Hello!

Thank you for aurman.

I don't want to edit some AUR-files, but I have to use option --noedit almost for every command: -Syu, -S, -S --needed, etc.

It would be nice to have noedit in config file ([miscellaneous] section), once and for all.

Thank you.

Error message when local search give zero matches

[gkulin@vw22 ~]$ aurman -Qs vk
local/vk-messenger 3.1.0-1
VK Messenger for Linux
[gkulin@vw22 ~]$ aurman -Qs vkmes
2018-03-13 14:11:16,292 - wrappers - pacman - ERROR - pacman query pacman -Qs vkmes failed

Packages with same names in known repos and AUR

I do not know if this is only a theoretical problem, but it may be that a package in the AUR has the same name as a known repo package. What to do in this case? Prefer the repo package, prefer the AUR package, ask the user? Since I am new in the "AUR helper business" I don't have enough experience to decide that in a sensible way.

aurman output formatting affects all later printed text in bash for windows

Described behaviour looks like this:
image

Could you fix it or maybe add an option to disable such formatting in output?

Upd:
The thing is you are using "\033[1m" and "\033[21m" for switching bold on and off respectively, and git-bash treats them as increased intensity and double underline. So adding a command line parameter to disable text formatting would be best.

Upd2:
Actually in my case it can be fixed with replacing "\033[21m" in coloring.py:40 with "\033[0m" which stands for reset attributes.

setup.py, PKGBUILD

Make it a real package, also provide a PKGBUILD. Nobody wants python main.py ...
Also provide it to the AUR when it is ready for everyday use

Providers not taken into account in deps solver

I have cower-git installed, which provides cower.
When installing a package that requires cower, the dependency solver fails.

In addition to package names, you'll need to check providers here.

$ python main.py -S --packages pacaur-git
2018-02-08 12:26:47,693 - package_utilites - check_versioning_and_conflicts - ERROR - Dep cower not fulfilled
2018-02-08 12:26:47,694 - main - process - ERROR - Dep problem, exiting.
2018-02-08 12:26:47,694 - main - <module> - ERROR - Unknown exception occurred.
Traceback (most recent call last):
  File "main.py", line 112, in process
    check_versioning_and_conflicts(packages_going_to_install, classified_packages)
  File "/home/remy/code/aurman/src/package_utilites.py", line 319, in check_versioning_and_conflicts
    raise InvalidInput()
own_exceptions.InvalidInput

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "main.py", line 167, in <module>
    process(argv[1:])
  File "main.py", line 115, in process
    exit(1)
SystemExit: 1

aurman can accidentally be installed in a venv

python on my system goes to a "local commands" virtual environment, which is Python 2.7, not the global Python 3 that aurman wants. I fixed it with this patch (which is the recommended way of getting the correct Python) but I'm not sure about any Arch-specific standards.

diff --git a/PKGBUILD b/PKGBUILD
index 2ac7e58..5cf95d3 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -12,6 +12,6 @@ md5sums=('SKIP')
 
 package() {
     cd "$srcdir/aurman_sources"
-    python setup.py install --root="$pkgdir/" --optimize=1
+    /usr/bin/env python3 setup.py install --root="$pkgdir/" --optimize=1
     install -Dm644 ./bash.completion "$pkgdir/usr/share/bash-completion/completions/aurman"
 }

Providers choices not separate

Consider the following:

$ aurman -S --pk ros-indigo-desktop-full

analyzing installed packages...
fetching upstream repo packages...
fetching needed aur packages...
calculating solutions...
More than one solution has been found
Choose between the following options to find one solution

Which of the following 5 packages do you want to install? Enter the corresponding number.                                                                                                   

1: ruby
2: hdf5-openmpi
3: hdf5
4: rubinius
5: rubinius-ruby

Enter the number: 1 2 3 4 5
That was not a valid choice!
1: ruby
2: hdf5-openmpi
3: hdf5
4: rubinius
5: rubinius-ruby

Enter the number: 3

Which of the following 3 packages do you want to install? Enter the corresponding number.                                                                                                   

1: ruby
2: rubinius
3: rubinius-ruby

Enter the number: 1

The following 352 package(s) are getting installed:

I was initially puzzled while looking at the firs prompt, since I assumed the 5 proposed choices were due to a single required package. It looks however like 2 'packages' have multiple providers, and that they both were merged into a single prompt.

I'd also suggest to explicily display the actual provider as pacman does (hdf5 and ruby above, and java-runtime below):

$ sudo pacman -S java-runtime
:: There are 3 providers available for java-runtime: <- needed virtual package
:: Repository extra
   1) jre7-openjdk  2) jre8-openjdk  3) jre9-openjdk

Enter a number (default=1):

Duplicated/triplicated commits in git history

I just open this issue since there are many (almost all) recent commits that are duplicated/triplicated in different branches. This makes following the progress quite difficult. Previous commits can be fixed with a rebase, but I don't know what is generating these duplicates.

Are you using any git manager in particular or just the command line?

better formatted output

Currently just printing some lines without nice formatting or useful information like versions of the packages.

Change that, also add colors for better readability.

--print flag for dependency solving

Besides the additional notifications on stderr, it might be helpful to have --print flag or similar which only displays a list of (totally ordered) tentative AUR dependencies. That way other programs can easily reuse aurman as a dependency solver.

Ideally, such a list would be independent of installed packages. The output could be in the form of pkgname\tpkgbase\tpkgver\n, the same with null-separation (cf. pacman --machinereadable) or perhaps in JSON. It could also (optionally) include all PKGBUILD dependencies, i.e. including those outside the AUR.

In case of cycles or no possible solutions, the exit status could be >0.

Case and duplicate issues with no_notification_unknown_packages

I tried to disable the notifications for a package that contains mixed case in its name: however I type the name (with or without the uppercase characters), it has no effect and the notifications are still shown. Moreover, aurman throws an error when a package is listed several times; maybe it should just ignore the duplicates.

Add a newline before the 'Y/n user prompt'

I PM'd you on Reddit before but I'll just do it here again in case you didn't see it (sorry for bugging you with minor stuff...)

As you can see in this image of pacman, there's an empty line separation between the whole 'package' part and the 'Y/n user prompt' line. Whereas for aurman in this image, the 'package' parts are separated pretty nicely, but the 'Y/n user prompt' line is not separated from the 'package' parts at all. An empty line before the user prompt line would make the output look much better.

Error parsing pacman.conf

Aurman seems to have problems with bash comments in pacman.conf.

I get the following error:

2018-03-26 11:13:09,359 - main - main - ERROR -
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/aurman/main.py", line 517, in main
    process(argv[1:])
  File "/usr/lib/python3.6/site-packages/aurman/main.py", line 290, in process
    upstream_system = System(System.get_repo_packages())
  File "/usr/lib/python3.6/site-packages/aurman/classes.py", line 1183, in get_repo_packages
    return Package.get_packages_from_expac("-S", (), PossibleTypes.REPO_PACKAGE)
  File "/usr/lib/python3.6/site-packages/aurman/classes.py", line 262, in get_packages_from_expac
    repos = Package.get_known_repos()
  File "/usr/lib/python3.6/site-packages/aurman/classes.py", line 240, in get_known_repos
    return [db.name for db in PacmanConfig(conf="/etc/pacman.conf").initialize_alpm().get_syncdbs()]
  File "/usr/lib/python3.6/site-packages/pycman/config.py", line 160, in __init__
    self.load_from_file(conf)
  File "/usr/lib/python3.6/site-packages/pycman/config.py", line 165, in load_from_file
    for section, key, value in pacman_conf_enumerator(filename):
  File "/usr/lib/python3.6/site-packages/pycman/config.py", line 119, in pacman_conf_enumerator
    raise InvalidSyntax(f.name, 'invalid key for repository configuration', line)
pycman.config.InvalidSyntax: unable to parse /etc/pacman.conf, invalid key for repository configuration: '[ownstuff] # mingw32-64 packages'

The error does not occur if I place that comment above the [ownstuff] line.

AUR packages providings without specifying the versions

See: https://aur.archlinux.org/packages/ffmpeg-libfdk_aac

A couple of .so are being provided, but without specifying the versions.
If you compare with the ffmpeg package https://www.archlinux.org/packages/extra/x86_64/ffmpeg/
the versions are specified.

This is really annoying... Assume you want to install dolphin-emu and ffmpeg-libfdk_aac.
It is possible to install those packages, but aurman does not find a solution since dolphin-emu depends on e.g. libavcodec.so=57-64 but that is not specified by ffmpeg-libfdk_aac, it is just libavcodec.so specified. So aurman dep solving assumes that it is not possible, which is correct from the standpoint of the solver. But pacman uses the .so versions which are known after building the package, e.g. after building ffmpeg-libfdk_aac. If you install this package, the pacman -Qi ffmpeg-libfdk_aac output yields:

Provides        : libavcodec.so=57-64  libavdevice.so=57-64
                  libavfilter.so=6-64  libavformat.so=57-64
                  libavresample.so=3-64  libavutil.so=55-64
                  libpostproc.so=54-64  libswresample.so=2-64
                  libswscale.so=4-64  ffmpeg=3.4.2

Manually one could do the following: Install ffmpeg and dolphin-emu with aurman, that is no problem.
Then install ffmpeg-libfdk_aac with aurman. aurman will say that dolphin-emu is going to be deleted because of unfulfilled deps, but since aurman is not deleting anything by itself, nothing will happen, because pacman knows the .so versions after installing ffmpeg-libfdk_aac and hence does not remove dolphin-emu. So, it is not a real problem, but I am really, really unhappy with that.

Any ideas for what to do? Or really just to do nothing since ffmpeg-libfdk_aac could just specify the versions?

Fail to install mingw-w64-gcc

I've succesfully installed mingw-w64-gcc with trizen and other managers, but aurman fails to solve dependency tree:

~~ analyzing installed packages...
~~ fetching upstream repo packages...
~~ fetching needed aur packages...
~~ calculating solutions...

!! While searching for solutions the following errors occurred:
:: Conflicts between: mingw-w64-gcc-7.3.0-1, mingw-w64-gcc-base-4.9.2-1
Way to conflict: mingw-w64-gcc-7.3.0-1 -> mingw-w64-crt-5.0.3-1 -> mingw-w64-gcc-base-4.9.2-1
:: Dep cycle: mingw-w64-gcc-7.3.0-1 -> mingw-w64-crt-5.0.3-1 -> mingw-w64-gcc-7.3.0-1

2018-02-27 14:34:20,393 - classes - validate_and_choose_solution - ERROR - No valid solutions found
!! we could not find a solution.
!! if you think that there should be one, rerun aurman with the --deep_search flag

I have also tried to install it with --deep_search:

~~ analyzing installed packages...
~~ fetching upstream repo packages...
~~ fetching needed aur packages...
~~ calculating solutions...

!! While searching for solutions the following errors occurred:
:: Dep cycle: mingw-w64-gcc-7.3.0-1 -> zlib-1:1.2.11-2 -> glibc-2.26-11 -> linux-api-headers-4.14.8-1 -> tzdata-2018c-1 -> filesystem-2017.10-2 -> iana-etc-20180221-1 -> libmpc-1.1.0-1 -> mpfr-4.0.1-1 -> gmp-6.1.2-1 -> gcc-libs-7.3.0-1 -> bash-4.4.019-1 -> readline-7.0.003-1 -> ncurses-6.1-3 -> mingw-w64-crt-5.0.3-1 -> mingw-w64-gcc-7.3.0-1
:: Conflicts between: mingw-w64-gcc-7.3.0-1, mingw-w64-gcc-base-4.9.2-1
Way to conflict: mingw-w64-gcc-7.3.0-1 -> zlib-1:1.2.11-2 -> glibc-2.26-11 -> linux-api-headers-4.14.8-1 -> tzdata-2018c-1 -> filesystem-2017.10-2 -> iana-etc-20180221-1 -> libmpc-1.1.0-1 -> mpfr-4.0.1-1 -> gmp-6.1.2-1 -> gcc-libs-7.3.0-1 -> bash-4.4.019-1 -> readline-7.0.003-1 -> ncurses-6.1-3 -> mingw-w64-crt-5.0.3-1 -> mingw-w64-gcc-base-4.9.2-1

Traceback if a package appears in more than one repo

I get this:
[haawda@frege blis]$ LANG=C aurman -Suy
:: Synchronizing package databases...
core is up to date
extra is up to date
community is up to date
xyne-x86_64 is up to date
my is up to date
:: Starting full system upgrade...
there is nothing to do

analyzing installed packages...
fetching upstream repo packages...
2018-02-25 13:06:03,193 - classes - append_packages - ERROR - Package reflector-2017.11-1 already known
2018-02-25 13:06:03,194 - main - main - ERROR -
Traceback (most recent call last):
File "/usr/lib/python3.6/site-packages/aurman/main.py", line 281, in main
process(argv[1:])
File "/usr/lib/python3.6/site-packages/aurman/main.py", line 140, in process
upstream_system = System(System.get_repo_packages())
File "/usr/lib/python3.6/site-packages/aurman/classes.py", line 823, in init
self.append_packages(packages)
File "/usr/lib/python3.6/site-packages/aurman/classes.py", line 834, in append_packages
raise InvalidInput("Package {} already known".format(package))
aurman.own_exceptions.InvalidInput: Package reflector-2017.11-1 already known

reflectore is in [community] and in [xyne-any].

Support for comment fetching

Reading comments for packages before installation can be informative, similar to checking news before making upgrades.

Support aur/ prefix

Currently, I cannot do this:

aurman -S aur/ttf-impallari-cabin-font

This is unexpected and unconvenient, aurman provides lists of packages in this format:

…
   aur/ttf-impallari-cabin-font        1.5-1                   ->  2.2-1
…

Being able to specify AUR explicitely as a package source is sometimes necessary. For example, when using a third-party repository that contains AUR packages. In some cases, it is desired to not use the packaged version but compile the package on the target machine.

Cannot install packages from AUR

I'm trying to use aurman to manage my AUR packages, but can't install nothing from it.
Always gives this error:

sudo aurman -S package
...
2018-03-16 11:49:48,920 - wrappers - makepkg - ERROR - makepkg query makepkg --prints

Tried to install tt-ms-fonts, insomnia and others. All have been later correctly installed through:

makepgk -si

Maybe is a problem in my Arch install and I'm missing some deps.

Zsh, Fish completion?

Do you plan to add completions for Zsh and Fish?

  • Completions for ZSH
  • Completions for Fish

Make solver errors explicit

One aspect of pacaur that is quite useful is that the solver pinpoints encountered errors, helping the user to know which package should be fixed by its maintainer. This is especially useful when upgrading a set of AUR packages, with one of them having an erroneous dependency deeply hidden in the tree.

Note that I'm using a very simple case here, but a more extreme case has been decribed here.

Compare:

$ pacaur -S aura
:: Package aura not found in repositories, trying AUR...
:: resolving dependencies...
:: no results found for haskell-aur>=6.0 (dependency tree: aura haskell-aur)
$ aurman -S --pk aura

analyzing installed packages...
fetching upstream repo packages...
fetching needed aur packages...
calculating solutions...
2018-02-17 15:36:47,561 - classes - validate_and_choose_solution - ERROR - No valid solutions found
we could not find a solution.
if you think that there should be one, rerun aurman with the --deep_search flag

Note: Using the --deep_search flag produces the same output.

I'd suggest adding more explicit error messages with the following objectives:

  • make it easy to locate the faulty PKGBUILD
  • determine which is the target requiring that dependency, so it can be --ignored allowing the update of the others packages
  • instead of stopping at the first detected error, find all errors at once then stops

Installation fails when install file doesn't exist

After a successful build, the package fails to install. I assume this happens only when the package doesn't have a .install file.

$ python main.py -Su
:: Starting full system upgrade...
 there is nothing to do
AUR Packages: nlohmann-json auracle-git
Repo Packages: 
Do you want to install these packages? Y/n: y
Do you want to view the changes of PKGBUILD of nlohmann-json ? N/y: y
Do you want to edit PKGBUILD? N/y: y
Do you want to use the files as they are now? Y/n: y
==> Making package: nlohmann-json 3.1.0-1 (Thu  8 Feb 10:31:52 CET 2018)
....
==> Cleaning up...
2018-02-08 10:38:59,298 - package_classes - install - ERROR - install file of nlohmann-json not available
2018-02-08 10:38:59,298 - main - <module> - ERROR - Unknown exception occurred.
Traceback (most recent call last):
  File "main.py", line 167, in <module>
    process(argv[1:])
  File "main.py", line 162, in process
    package.install(args_with_asdeps)
  File "/home/remy/code/aurman/src/package_classes.py", line 134, in install
    raise InvalidInput()
own_exceptions.InvalidInput

Suppressing not_repo_not_aur_packages_list warning in config

I was wondering if there's any way to suppress the not_repo_not_aur_packages_list info for selected packages. I have a few -dummy packages installed for tools I manage outside of pacman, but provide targets for pacman to use. Telling me that these packages don't exist inside the usual repos each time aurman is run isn't helpful in this instance (although I do see the reason to provide this for other packages that have been dropped for whatever reason).

I attempted to use the pacman.conf IgnorePkg variable; both that and sending the packages directly to the --ignore flag didn't remove the warning.

Error when aborting on main prompt

On 0.33.3:

$ python main.py -S --packages pacaur-git
AUR Packages: pacaur-git
Repo Packages:
Do you want to install these packages? Y/n: n
2018-02-08 12:46:51,918 - main - <module> - ERROR - Unknown exception occurred.
Traceback (most recent call last):
  File "main.py", line 167, in <module>
    process(argv[1:])
  File "main.py", line 123, in process
    exit(1)
SystemExit: 1

aurman -V

Should it behave this way?

$ aurman --version
2018-04-02 18:17:01,419 - wrappers - expac - ERROR - expac query expac -Q '%v' aurman-git failed
2018-04-02 18:17:01,419 - main - main - ERROR -
Traceback (most recent call last):
File "/usr/lib/python3.6/site-packages/aurman/main.py", line 517, in main
process(argv[1:])
File "/usr/lib/python3.6/site-packages/aurman/main.py", line 55, in process
aurman_note(expac("-Q", ("v",), ("aurman-git",))[0])
File "/usr/lib/python3.6/site-packages/aurman/wrappers.py", line 72, in expac
raise InvalidInput("expac query {} failed".format(query))
aurman.own_exceptions.InvalidInput: expac query expac -Q '%v' aurman-git failed

No option to bypass 'multiple providers' prompt

I am able to install vim by script using pacman -S --noconfirm --noedit --needed vim but cannot do something similar with aurman:

$ aurman -S --noconfirm --noedit --needed vim
~~ initializing aurman...
:: We found multiple providers for vim
Choose one by entering the corresponding number.
Number 1: extra/vim
Number 2: extra/gvim
?? Enter the number: 

Is there a way I can instruct aurman to automatically select the package with the exact name given?

Do not print empty operations

aurman prints a verbose operation output even when there is no operation to do.

For example:

$> aurman -S aurman-git

analyzing installed packages...
fetching upstream repo packages...
fetching needed aur packages...
calculating solutions...

The following 0 package(s) are getting installed:



The following 0 package(s) are getting removed:



The following 1 package(s) are getting updated:

aurman-git-1.5.2.r0.g5f459c1-1 -> aurman-git-1.5.r0.g2faec5c-1


The following 0 packages(s) are just getting reinstalled:



Do you want to continue? Y/n: 

It should not print the output of unused operations (in this case install, remove, reinstall).

Doesn't detect spl/zfs packages correctly when updating.

That happens when i do aurman -Syu

:: Synchronising package databases...
 core is up to date
 extra                                                                                                1603.5 KiB  2009K/s 00:01 [#############################################################################] 100%
 community                                                                                               4.2 MiB  11.6M/s 00:00 [#############################################################################] 100%
 multilib                                                                                              170.7 KiB  23.8M/s 00:00 [#############################################################################] 100%
:: Starting full system upgrade...
 there is nothing to do

~~ initializing aurman...
~~ the following packages are neither in known repos nor in the aur
:: libcloudproviders-0.2.5+9+g93dc5ea-1
~~ calculating solutions...

:: The following 2 package(s) are getting updated:
   aur/spl-dkms-git        0.7.0_r31_g43983eb-1     ->  0.7.0_rc1_r3_gcb81c0c-1
   aur/spl-utils-dkms-git  0.7.0_r31_g43983eb-1     ->  0.7.0_rc1_r3_gcb81c0c-1

:: The following 1 package(s) are getting removed:
   aur/zfs-dkms-git        0.7.0_r372_gde4f8d5d2-1  ->  /
:: Dependency spl-dkms-git of package zfs-dkms-git is not fulfilled

?? Do you want to continue? Y/n:

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.