Conan package not found on project level remote during install, but found by a search
Summary
Installing Conan packages from project level remotes results in a "not found" error although a conan search and the WebUI shows that the package is available. Repeating the same procedure with instance level remotes works.
Steps to reproduce
I used Conan version 1.30.1 on Windows 10. Conan was installed using Miniconda.
Setting log level to 10
$ set CONAN_LOGGING_LEVEL=10
Add project level remote to conan
$ conan remote add gitlab https://gitlab.com/api/v4/projects/21898642/packages/conan
DEBUG :conan_api.py [178]: INIT: Using config 'C:\Data\Miniconda3\envs\conan\share\.conan\conan.conf' [2020-10-20 14:33:59,725]
DEBUG :tracer.py [156]: CONAN_API: remote_add() [2020-10-20 14:33:59,732]
Add deploy token
$ conan user gitlab+deploy-token-257070 -r gitlab -p <token>
DEBUG :conan_api.py [178]: INIT: Using config 'C:\Data\Miniconda3\envs\conan\share\.conan\conan.conf' [2020-10-20 14:38:40,482]
DEBUG :tracer.py [156]: CONAN_API: authenticate(remote_name=gitlab,password=**********,skip_auth=False) [2020-10-20 14:38:40,500]
DEBUG :conan_api.py [178]: INIT: Using config 'C:\Data\Miniconda3\envs\conan\share\.conan\conan.conf' [2020-10-20 14:38:40,506]
DEBUG :tracer.py [156]: CONAN_API: get_remote_by_name() [2020-10-20 14:38:40,511]
DEBUG :rest_client_common.py[156]: REST: ping: https://gitlab.com/api/v4/projects/21898642/packages/conan/v1/ping [2020-10-20 14:38:40,569]
DEBUG :rest_client.py [58]: REST: Cached capabilities for the remote: [] [2020-10-20 14:38:41,386]
DEBUG :rest_client_common.py[90]: REST: Authenticate to get access_token: https://gitlab.com/api/v4/projects/21898642/packages/conan/v1/users/authenticate [2020-10-20 14:38:41,388]
Changed user of remote 'gitlab' from 'None' (anonymous) to 'gitlab+deploy-token-257070'
Upload package to remote
$ conan upload tinyxml/0.1@tbrosch/stable -r gitlab
DEBUG :conan_api.py [178]: INIT: Using config 'C:\Data\Miniconda3\envs\conan\share\.conan\conan.conf' [2020-10-20 14:39:38,895]
DEBUG :tracer.py [156]: CONAN_API: upload(pattern=tinyxml/0.1@tbrosch/stable,package=None,query=None,remote_name=gitlab,all_packages=False,policy=None,confirm=False,retry=None,retry_wait=None,integrity_check=False,parallel_upload=False) [2020-10-20 14:39:38,902]
Uploading to remote 'gitlab':
Uploading tinyxml/0.1@tbrosch/stable to remote 'gitlab'
DEBUG :rest_client_common.py[156]: REST: ping: https://gitlab.com/api/v4/projects/21898642/packages/conan/v1/ping [2020-10-20 14:39:39,035]
DEBUG :rest_client.py [58]: REST: Cached capabilities for the remote: [] [2020-10-20 14:39:39,860]
DEBUG :rest_client_common.py[183]: REST: get: https://gitlab.com/api/v4/projects/21898642/packages/conan/v1/conans/tinyxml/0.1/tbrosch/stable/digest [2020-10-20 14:39:39,861]
DEBUG :rest_client_common.py[29]: REST ERROR: <class 'conans.errors.NotFoundException'> [2020-10-20 14:39:40,163]
DEBUG :rest_client_common.py[148]: REST: Check credentials: https://gitlab.com/api/v4/projects/21898642/packages/conan/v1/users/check_credentials [2020-10-20 14:39:40,169]
DEBUG :rest_client_common.py[183]: REST: get: https://gitlab.com/api/v4/projects/21898642/packages/conan/v1/conans/tinyxml/0.1/tbrosch/stable [2020-10-20 14:39:40,437]
DEBUG :rest_client_common.py[177]: REST: post: https://gitlab.com/api/v4/projects/21898642/packages/conan/v1/conans/tinyxml/0.1/tbrosch/stable/upload_urls [2020-10-20 14:39:40,738]
Uploaded conanfile.py -> tinyxml/0.1@tbrosch/stable [1.05k]
Uploaded conanmanifest.txt -> tinyxml/0.1@tbrosch/stable [0.06k]
DEBUG :rest_client_v1.py[183]: UPLOAD:
All uploaded! Total time: 3.017055034637451
[2020-10-20 14:39:44,093]
Uploaded conan recipe 'tinyxml/0.1@tbrosch/stable' to 'gitlab': https://gitlab.com/api/v4/projects/21898642/packages/conan
DEBUG :uploader.py [238]: UPLOAD: Time manager upload: 5.216641 [2020-10-20 14:39:44,123]
Remove package from local cache
$ conan remove tinyxml/0.1@tbrosch/stable
DEBUG :conan_api.py [178]: INIT: Using config 'C:\Data\Miniconda3\envs\conan\share\.conan\conan.conf' [2020-10-20 14:40:49,165]
DEBUG :tracer.py [156]: CONAN_API: remove(pattern=tinyxml/0.1@tbrosch/stable,query=None,packages=None,builds=None,src=False,force=False,remote_name=None,outdated=False) [2020-10-20 14:40:49,171]
Are you sure you want to delete from 'tinyxml/0.1@tbrosch/stable' (yes/no): yes
DEBUG :remover.py [16]: REMOVE: folder C:\Data\Miniconda3\envs\conan\share\.conan\data\tinyxml\0.1\tbrosch\stable\source [2020-10-20 14:40:52,134]
DEBUG :remover.py [16]: REMOVE: folder C:\Data\Miniconda3\envs\conan\share\.conan\data\tinyxml\0.1\tbrosch\stable\scm_source [2020-10-20 14:40:52,136]
DEBUG :remover.py [16]: REMOVE: folder C:\Data\Miniconda3\envs\conan\share\.conan\data\tinyxml\0.1\tbrosch\stable\export [2020-10-20 14:40:52,138]
DEBUG :remover.py [16]: REMOVE: folder C:\Data\Miniconda3\envs\conan\share\.conan\data\tinyxml\0.1\tbrosch\stable\export_source [2020-10-20 14:40:52,148]
DEBUG :remover.py [16]: REMOVE: folder C:\Data\Miniconda3\envs\conan\share\.conan\data\tinyxml\0.1\tbrosch\stable\build [2020-10-20 14:40:52,154]
DEBUG :remover.py [16]: REMOVE: folder C:\Data\Miniconda3\envs\conan\share\.conan\data\tinyxml\0.1\tbrosch\stable\package [2020-10-20 14:40:52,156]
DEBUG :remover.py [24]: REMOVE: file C:\Data\Miniconda3\envs\conan\share\.conan\data\tinyxml\0.1\tbrosch\stable\system_reqs\system_reqs.txt [2020-10-20 14:40:52,158]
DEBUG :remover.py [16]: REMOVE: folder C:\Data\Miniconda3\envs\conan\share\.conan\data\tinyxml\0.1\tbrosch\stable [2020-10-20 14:40:52,164]
Find package on remote
$ conan search tinyxml -r gitlab
DEBUG :conan_api.py [178]: INIT: Using config 'C:\Data\Miniconda3\envs\conan\share\.conan\conan.conf' [2020-10-20 14:41:30,027]
DEBUG :tracer.py [156]: CONAN_API: search_recipes(remote_name=gitlab,case_sensitive=False) [2020-10-20 14:41:30,055]
DEBUG :rest_client_common.py[156]: REST: ping: https://gitlab.com/api/v4/projects/21898642/packages/conan/v1/ping [2020-10-20 14:41:30,178]
DEBUG :rest_client.py [58]: REST: Cached capabilities for the remote: [] [2020-10-20 14:41:31,009]
DEBUG :rest_client_common.py[183]: REST: get: https://gitlab.com/api/v4/projects/21898642/packages/conan/v1/conans/search?q=tinyxml [2020-10-20 14:41:31,010]
DEBUG :conan_api.py [178]: INIT: Using config 'C:\Data\Miniconda3\envs\conan\share\.conan\conan.conf' [2020-10-20 14:41:31,366]
DEBUG :tracer.py [156]: CONAN_API: get_remote_by_name() [2020-10-20 14:41:31,375]
Existing package recipes:
tinyxml/0.1@tbrosch/stable
Install package fails
$ conan install tinyxml/0.1@tbrosch/stable -r gitlab --build
DEBUG :conan_api.py [178]: INIT: Using config 'C:\Data\Miniconda3\envs\conan\share\.conan\conan.conf' [2020-10-20 14:42:07,177]
DEBUG :tracer.py [156]: CONAN_API: install_reference(settings=None,options=None,env=None,profile_names=None,profile_build=ProfileData(profiles=None, settings=None, options=None, env=None),remote_name=gitlab,verify=None,manifests=None,manifests_interactive=None,build=[],update=False,generators=None,install_folder=None,lockfile=None,lockfile_out=None) [2020-10-20 14:42:07,183]
DEBUG :profile_loader.py[116]: PROFILE LOAD: C:\Data\Miniconda3\envs\conan\share\.conan\profiles\default [2020-10-20 14:42:07,190]
INFO :settings_preprocessor.py[57]: Setting 'compiler.runtime' not declared, automatically adjusted to 'MD' [2020-10-20 14:42:07,325]
Configuration:
[settings]
arch=x86_64
arch_build=x86_64
build_type=Release
compiler=Visual Studio
compiler.runtime=MD
compiler.version=15
os=Windows
os_build=Windows
[options]
[build_requires]
[env]
tinyxml/0.1@tbrosch/stable: Retrieving from server 'gitlab'
tinyxml/0.1@tbrosch/stable: Trying with 'gitlab'...
DEBUG :rest_client_common.py[156]: REST: ping: https://gitlab.com/api/v4/projects/21898642/packages/conan/v1/ping [2020-10-20 14:42:07,431]
DEBUG :rest_client.py [58]: REST: Cached capabilities for the remote: [] [2020-10-20 14:42:08,316]
DEBUG :rest_client_common.py[183]: REST: get: https://gitlab.com/api/v4/projects/21898642/packages/conan/v1/conans/tinyxml/0.1/tbrosch/stable/download_urls [2020-10-20 14:42:08,321]
ERROR: tinyxml/0.1@tbrosch/stable was not found in remote 'gitlab'
Example Project
Tested using this project: https://gitlab.com/brosch.tom/conan. It also contains an example conanfile.py, but the project was mainly used as a Conan package repository.
What is the current bug behavior?
The install command reports that the package wasn't found, although a search shows, that the package is actually available. The package is also shown in the WebUI.
What is the expected correct behavior?
The installation of the package should start.
Relevant logs and/or screenshots
See steps to reproduce.
Output of checks
This bug happens on GitLab.com