View previous topic :: View next topic |
Author |
Message |
Chymera Apprentice


Joined: 13 Sep 2007 Posts: 245 Location: Zürich
|
Posted: Wed Aug 02, 2017 8:47 pm Post subject: app-vim/jedi (new ebuild) |
|
|
Hi guys,
I am trying to emerge this ebuild:
Code: | # Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
EAPI=5
PYTHON_COMPAT=(python{2_7,3_4})
inherit vim-plugin git-2 python-r1 python-utils-r1
DESCRIPTION="Jedi Python autocompletion with VIM"
HOMEPAGE="https://github.com/davidhalter/jedi-vim"
SRC_URI=""
EGIT_REPO_URI="git://github.com/davidhalter/${PN}-vim.git"
LICENSE="LGPL-3+"
KEYWORDS=""
IUSE=""
RDEPEND="dev-python/jedi[${PYTHON_USEDEP}]"
DEPEND="app-editors/vim[${PYTHON_USEDEP},python]"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
src_prepare() {
python_copy_sources
}
src_install() {
python_foreach_impl python_domodule jedi_vim.py
vim-plugin_src_install
} |
But I get the following dependency conflict from portage:
Code: | zenbookhost ~ # emerge -av app-vim/jedi
These are the packages that would be merged, in order:
Calculating dependencies... done!
emerge: there are no ebuilds built with USE flags to satisfy "app-editors/vim[python_targets_python2_7(-)?,python_targets_python3_4(-)?,-python_single_target_python2_7(-),-python_single_target_python3_4(-),python]".
!!! One of the following packages is required to complete your request:
- app-editors/vim-8.0.0386-r1::gentoo (Change USE: -python_single_target_python3_4, this change violates use flag constraints defined by app-editors/vim-8.0.0386-r1: 'luajit? ( lua ) python? ( exactly-one-of ( python_single_target_python2_7 python_single_target_python3_4 python_single_target_python3_5 python_single_target_python3_6 ) python_single_target_python2_7? ( python_targets_python2_7 ) python_single_target_python3_4? ( python_targets_python3_4 ) python_single_target_python3_5? ( python_targets_python3_5 ) python_single_target_python3_6? ( python_targets_python3_6 ) )')
(dependency required by "app-vim/jedi-9999::chymeric" [ebuild])
(dependency required by "app-vim/jedi" [argument]) |
I can't understand the issue here here, i.e. why two SINGLE_TARGETs would be required all of a sudden.
If I delete the python3_4 compatibility from the ebuild, dependency resolution works, but the build crashes (in a fashion that makes me suspect I need python3_4 support somehow):
Code: | zenbookhost ~ # cat /home/chymera/src/overlay/app-vim/jedi/jedi-9999.ebuild
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
EAPI=5
PYTHON_COMPAT=(python2_7)
inherit vim-plugin git-2 python-r1 python-utils-r1
DESCRIPTION="Jedi Python autocompletion with VIM"
HOMEPAGE="https://github.com/davidhalter/jedi-vim"
SRC_URI=""
EGIT_REPO_URI="git://github.com/davidhalter/${PN}-vim.git"
LICENSE="LGPL-3+"
KEYWORDS=""
IUSE=""
RDEPEND="dev-python/jedi[${PYTHON_USEDEP}]"
DEPEND="app-editors/vim[${PYTHON_USEDEP},python]"
#REQUIRED_USE="${PYTHON_REQUIRED_USE}"
src_prepare() {
python_copy_sources
}
src_install() {
python_foreach_impl python_domodule jedi_vim.py
vim-plugin_src_install
}
zenbookhost ~ # emerge -v app-vim/jedi
These are the packages that would be merged, in order:
Calculating dependencies... done!
[ebuild N *] app-vim/jedi-9999::chymeric PYTHON_TARGETS="python2_7" 0 KiB
Total: 1 package (1 new), Size of downloads: 0 KiB
>>> Verifying ebuild manifests
>>> Emerging (1 of 1) app-vim/jedi-9999::chymeric
>>> Unpacking source...
GIT update -->
repository: git://github.com/davidhalter/jedi-vim.git
at the commit: 6411de0cd1d2a2959f5a0bf977b3f8ecea2209d0
branch: master
storage directory: "/usr/portage/distfiles/egit-src/jedi-vim.git"
checkout type: bare repository
Cloning into '/var/tmp/portage/app-vim/jedi-9999/work/jedi-9999'...
done.
Branch branch-master set up to track remote branch master from origin.
Switched to a new branch 'branch-master'
>>> Unpacked to /var/tmp/portage/app-vim/jedi-9999/work/jedi-9999
>>> Source unpacked in /var/tmp/portage/app-vim/jedi-9999/work
>>> Preparing source in /var/tmp/portage/app-vim/jedi-9999/work/jedi-9999 ...
* Will copy sources from /var/tmp/portage/app-vim/jedi-9999/work/jedi-9999
* python2_7: copying to /var/tmp/portage/app-vim/jedi-9999/work/jedi-9999-python2_7
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/app-vim/jedi-9999/work/jedi-9999 ...
>>> Source configured.
>>> Compiling source in /var/tmp/portage/app-vim/jedi-9999/work/jedi-9999 ...
make -j5
py.test
============================================= test session starts ==============================================
platform linux2 -- Python 2.7.13, pytest-3.1.2, py-1.4.33, pluggy-0.4.0
rootdir: /var/tmp/portage/app-vim/jedi-9999/work/jedi-9999, inifile: pytest.ini
collected 7 items
test_integration.py ...FF.F
=================================================== FAILURES ===================================================
___________________________________________ test_integration[case3] ____________________________________________
test/completions.vim failed:
No protocol specified
ok 1 - completions smart import
ok 2 - completions no smart import after space=jedi#complete_opened(0)
=jedi#complete_opened(0)
ok 3 - completions import=jedi#complete_opened(0)
=jedi#complete_opened(0)
ok 4 - completions exception=jedi#complete_opened(0)
=jedi#complete_opened(0)
=jedi#complete_opened(0)
ok 5 - completions dot_open=jedi#complete_opened(0)
not ok 6 - completions cycling through entries
# Expected getline('.') == 'raise ImportWarning'
# Actual value: "raise imp"
# Expected value: "raise ImportWarning"
1..6
___________________________________________ test_integration[case4] ____________________________________________
case = <<class 'conftest.IntegrationTestFile'>: test/signatures.vim>
monkeypatch = <_pytest.monkeypatch.MonkeyPatch instance at 0x7f7e172eec68>
pytestconfig = <_pytest.config.Config object at 0x7f7e17ad7650>
def test_integration(case, monkeypatch, pytestconfig):
> case.run()
test_integration.py:2:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <<class 'conftest.IntegrationTestFile'>: test/signatures.vim>
def run(self):
output = subprocess.check_output(
[VSPEC_RUNNER, '.', VSPEC_FOLDER, self.path])
for line in output.splitlines():
if line.startswith(b'not ok') or line.startswith(b'Error'):
pytest.fail("{0} failed:\n{1}".format(
> self.path, output.decode('utf-8')), pytrace=False)
E UnicodeEncodeError: 'ascii' codec can't encode character u'\u2026' in position 2693: ordinal not in range(128)
conftest.py:25: UnicodeEncodeError
___________________________________________ test_integration[case6] ____________________________________________
test/goto.vim failed:
No protocol specified
3 more lines
not ok 1 - goto_simple goto_definitions
# Expected line('.') == 1
# Actual value: 3
# Expected value: 1
3 more lines
not ok 2 - goto_simple goto_assignments
# Expected line('.') == 2
# Actual value: 3
# Expected value: 2
ok 3 - goto_with_tabs follow_import
ok 4 - goto_with_tabs multi_definitions
Traceback (most recent call last):
File "/var/tmp/portage/app-vim/jedi-9999/work/jedi-9999/jedi_vim.py", line 123, in wrapper
return func(*args, **kwargs)
File "/var/tmp/portage/app-vim/jedi-9999/work/jedi-9999/jedi_vim.py", line 670, in new_buffer
vim_command('w')
File "/var/tmp/portage/app-vim/jedi-9999/work/jedi-9999/jedi_vim.py", line 76, in vim_command
_catch_exception(string, False)
File "/var/tmp/portage/app-vim/jedi-9999/work/jedi-9999/jedi_vim.py", line 71, in _catch_exception
raise VimError(result['exception'], result['throwpoint'], string)
jedi_vim.VimError: Vim(write):E32: No file name; created by: 'w'
not ok 5 - goto_with_buffers no_new_tabs
# function <SNR>1_main[9]..vspec#test[6]..<SNR>2_run_suites[9]..20, line 4
# Vim(python):E319: Sorry, the command is not available in this version: python jedi_vim.goto()
ok 6 - goto_with_buffers multi_definitions
not ok 7 - goto_with_splits follow_import
# Expected getline('.') == 'import subprocess'
# Actual value: "subprocess"
# Expected value: "import subprocess"
"/usr/lib64/python3.4/subprocess.py"
"/usr/lib64/python3.4/subprocess.py" [readonly] 1695L, 64352C
ok 8 - goto_wildignore restores_wildignore
"/usr/lib64/python3.4/subprocess.py"
"/usr/lib64/python3.4/subprocess.py" [readonly] 1695L, 64352C
ok 9 - goto_wildignore not_using_tagstack
1..9
====================================== 3 failed, 4 passed in 6.45 seconds ======================================
make: *** [Makefile:2: test] Error 1
* ERROR: app-vim/jedi-9999::chymeric failed (compile phase):
* emake failed
*
* If you need support, post the output of `emerge --info '=app-vim/jedi-9999::chymeric'`,
* the complete build log and the output of `emerge -pqv '=app-vim/jedi-9999::chymeric'`.
* The complete build log is located at '/var/tmp/portage/app-vim/jedi-9999/temp/build.log'.
* The ebuild environment file is located at '/var/tmp/portage/app-vim/jedi-9999/temp/environment'.
* Working directory: '/var/tmp/portage/app-vim/jedi-9999/work/jedi-9999'
* S: '/var/tmp/portage/app-vim/jedi-9999/work/jedi-9999'
>>> Failed to emerge app-vim/jedi-9999, Log file:
>>> '/var/tmp/portage/app-vim/jedi-9999/temp/build.log'
* Messages for package app-vim/jedi-9999:
* ERROR: app-vim/jedi-9999::chymeric failed (compile phase):
* emake failed
*
* If you need support, post the output of `emerge --info '=app-vim/jedi-9999::chymeric'`,
* the complete build log and the output of `emerge -pqv '=app-vim/jedi-9999::chymeric'`.
* The complete build log is located at '/var/tmp/portage/app-vim/jedi-9999/temp/build.log'.
* The ebuild environment file is located at '/var/tmp/portage/app-vim/jedi-9999/temp/environment'.
* Working directory: '/var/tmp/portage/app-vim/jedi-9999/work/jedi-9999'
* S: '/var/tmp/portage/app-vim/jedi-9999/work/jedi-9999'
*
* The following package has failed to build, install, or execute postinst:
*
* (app-vim/jedi-9999:0/0::chymeric, ebuild scheduled for merge), Log file:
* '/var/tmp/portage/app-vim/jedi-9999/temp/build.log'
*
|
_________________ Check out my initiative to bring Neuroscience software to Gentoo - NeuroGentoo! |
|
Back to top |
|
 |
Juippisi Developer


Joined: 30 Sep 2005 Posts: 625 Location: /home
|
Posted: Fri Aug 04, 2017 7:01 am Post subject: |
|
|
I think you need to use python-single-r1 instead of python-r1. Study your vim installation, what python_single_target and python_targets is being used. Or just simply force python3.4 usage and drop 2.7, if its your local ebuild and only meant to work in your own system. |
|
Back to top |
|
 |
Chymera Apprentice


Joined: 13 Sep 2007 Posts: 245 Location: Zürich
|
Posted: Fri Aug 04, 2017 6:01 pm Post subject: |
|
|
The dependency issue is resolved, if I remove PYTHON_USEDEP from the required flags for app-editors/vim. Also, the tests are apparently just broken, so blanking src_compile() is the way to go about that:
Code: |
EAPI=5
PYTHON_COMPAT=( python2_7 python3_4 )
inherit vim-plugin git-r3 python-r1 python-utils-r1
DESCRIPTION="Jedi Python autocompletion with VIM"
HOMEPAGE="https://github.com/davidhalter/jedi-vim"
SRC_URI=""
EGIT_REPO_URI="git://github.com/davidhalter/${PN}-vim.git"
LICENSE="LGPL-3+"
KEYWORDS=""
IUSE=""
RDEPEND="dev-python/jedi[${PYTHON_USEDEP}]"
DEPEND="app-editors/vim[python]"
#REQUIRED_USE="${PYTHON_REQUIRED_USE}"
src_prepare() {
python_copy_sources
}
#Makeflile calls tests, which are broken.
src_compile() { :; }
src_install() {
python_foreach_impl python_domodule jedi_vim.py
vim-plugin_src_install
}
|
I'm not sure whether this is the right way to go about this, as the installation I get from app-vim/jedi does not work. _________________ Check out my initiative to bring Neuroscience software to Gentoo - NeuroGentoo! |
|
Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|