Uploading conan package to gitlab registry results in an internal server 500 error
Summary
In version 13.2 conan package upload was working normaly, with 13.3 the upload is now failing with 500 error.
Steps to reproduce
- Have a working Conan package upload CI?CD pipeline
- Upgrade to 13.3 and run pipeline
Example Project
A Premium (large) Customer reported issue in ZD internal only
What is the current bug behavior?
POST api call fail with 500 error.
What is the expected correct behavior?
POST api call succeeds.
Relevant logs and/or screenshots
{
"time": "2020-09-07T11:10:46.635Z",
"severity": "INFO",
"duration_s": 0.03451,
"db_duration_s": 0.00782,
"view_duration_s": 0.02669,
"status": 500,
"method": "POST",
"path": "/api/v4/packages/conan/v1/conans/ConanPckg/3.0/example-group+conan/beta/upload_urls",
"params": [
{
"key": "conanfile.py",
"value": null
},
{
"key": "conanmanifest.txt",
"value": null
}
],
"host": "gitlab.example.com",
"remote_ip": "10.1.2.3, 10.1.2.4, 127.0.0.1",
"ua": "Conan/1.29.0 (Python 3.8.1) python-requests/2.24.0",
"route": "/api/:version/packages/conan/v1/conans/:package_name/:package_version/:package_username/:package_channel/upload_urls",
"user_id": 2982,
"username": "auser",
"exception.class": "NoMethodError",
"exception.message": "undefined method `string' for #<Unicorn::TeeInput:0x00007f2ee811fad0>",
"exception.backtrace": [
"lib/api/helpers/packages/conan/api_helpers.rb:142:in `file_names'",
"lib/api/helpers/packages/conan/api_helpers.rb:33:in `recipe_upload_urls'",
"lib/api/conan_packages.rb:231:in `block (3 levels) in <class:ConanPackages>'",
"ee/lib/gitlab/middleware/ip_restrictor.rb:14:in `block in call'",
"ee/lib/gitlab/ip_address_state.rb:10:in `with'",
"ee/lib/gitlab/middleware/ip_restrictor.rb:13:in `call'",
"lib/gitlab/metrics/elasticsearch_rack_middleware.rb:16:in `call'",
"lib/gitlab/middleware/rails_queue_duration.rb:33:in `call'",
"lib/gitlab/metrics/rack_middleware.rb:16:in `block in call'",
"lib/gitlab/metrics/transaction.rb:61:in `run'",
"lib/gitlab/metrics/rack_middleware.rb:16:in `call'",
"lib/gitlab/request_profiler/middleware.rb:17:in `call'",
"ee/lib/gitlab/jira/middleware.rb:19:in `call'",
"lib/gitlab/middleware/go.rb:20:in `call'",
"lib/gitlab/etag_caching/middleware.rb:13:in `call'",
"lib/gitlab/middleware/multipart.rb:140:in `call'",
"lib/gitlab/middleware/read_only/controller.rb:51:in `call'",
"lib/gitlab/middleware/read_only.rb:18:in `call'",
"lib/gitlab/middleware/same_site_cookies.rb:27:in `call'",
"lib/gitlab/middleware/basic_health_check.rb:25:in `call'",
"lib/gitlab/middleware/handle_ip_spoof_attack_error.rb:25:in `call'",
"lib/gitlab/middleware/request_context.rb:23:in `call'",
"config/initializers/fix_local_cache_middleware.rb:9:in `call'",
"lib/gitlab/metrics/requests_rack_middleware.rb:60:in `call'",
"lib/gitlab/middleware/release_env.rb:12:in `call'"
],
"queue_duration_s": 0.005428,
"correlation_id": "1234567890",
"meta.user": "auser",
"meta.project": "auser-group/conan",
"meta.root_namespace": "auser-group",
"meta.caller_id": "/api/:version/packages/conan/v1/conans/:package_name/:package_version/:package_username/:package_channel/upload_urls"
}
Output of checks
Results of GitLab environment info
version 13.2 upgraded to 13.3
Possible fixes
Possibly related to Allow dynamic files for Conan package uploads