Bug 1752075

Summary: Cannot build local module
Product: [Fedora] Fedora Reporter: Gwyn Ciesla <gwync>
Component: module-build-serviceAssignee: cqi
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: unspecified    
Version: 30CC: cqi, fvalder, jkaluza, mkonecny, mprahl, vmaljuli
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: module-build-service-2.28.2-1.fc31 module-build-service-2.28.2-1.fc29 module-build-service-2.28.2-1.fc30 module-build-service-2.30.3-1.fc31 module-build-service-2.30.3-1.fc29 module-build-service-2.30.3-1.fc30 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-11-19 01:35:24 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1762826    
Attachments:
Description Flags
Logs from attempted ricochet build none

Description Gwyn Ciesla 2019-09-13 16:00:26 UTC
I'm running f30. I was working on a new module, and the build failed in a way I'd never seen. I've confirmed that it happens on modules I know worked before, and updating to 2.27.0 didn't help.

nfo: State transition: 'done' -> 'ready', <ModuleBuild hedgewars, id=2, stream=master, version=3020190913152119, scratch=False, state 'ready', batch 3, state_reason None>
info: Scheduling shutdown.
Traceback (most recent call last):
  File "/usr/bin/mbs-manager", line 11, in <module>
    load_entry_point('module-build-service==2.26.0', 'console_scripts', 'mbs-manager')()
  File "/usr/lib/python3.7/site-packages/module_build_service/manage.py", line 272, in manager_wrapper
    manager.run()
  File "/usr/lib/python3.7/site-packages/flask_script/__init__.py", line 417, in run
    result = self.handle(argv[0], argv[1:])
  File "/usr/lib/python3.7/site-packages/flask_script/__init__.py", line 386, in handle
    res = handle(*args, **config)
  File "/usr/lib/python3.7/site-packages/flask_script/commands.py", line 216, in __call__
    return self.run(*args, **kwargs)
  File "/usr/lib/python3.7/site-packages/module_build_service/manage.py", line 199, in build_module_locally
    if any(module.state == models.BUILD_STATES["failed"] for module in modules_list):
  File "/usr/lib/python3.7/site-packages/module_build_service/manage.py", line 199, in <genexpr>
    if any(module.state == models.BUILD_STATES["failed"] for module in modules_list):
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/attributes.py", line 282, in __get__
    return self.impl.get(instance_state(instance), dict_)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/attributes.py", line 705, in get
    value = state._load_expired(state, passive)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/state.py", line 660, in _load_expired
    self.manager.deferred_scalar_loader(self, toload)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/loading.py", line 913, in load_scalar_attributes
    "attribute refresh operation cannot proceed" % (state_str(state))
sqlalchemy.orm.exc.DetachedInstanceError: Instance <ModuleBuild at 0x7f5566241410> is not bound to a Session; attribute refresh operation cannot proceed (Background on this error at: http://sqlalche.me/e/bhk3)

error: mbs-manager build_module_locally failed
error: log: /home/gwyn/modulebuild/builds/module-hedgewars-master-3020190913152119/mbs.log

Comment 2 Fedora Update System 2019-09-17 17:44:09 UTC
FEDORA-2019-33d2315efb has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-33d2315efb

Comment 3 Fedora Update System 2019-09-17 17:44:15 UTC
FEDORA-2019-6a3bd79eca has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2019-6a3bd79eca

Comment 4 Gwyn Ciesla 2019-09-17 18:05:07 UTC
New error. I just upgraded to f31 Beta so I'm not sure if this is mbs or an artifact of that.

gwyn@gwythsefyll hedgewars]$ flatpak-module local-build
2019-09-17 13:03:33,121 - MainThread - moksha.hub - WARNING - Cannot find qpid python module. Make sure you have python-qpid installed.
2019-09-17 13:03:33,414 - MainThread - MBS.utils.greenwave - WARNING - Greenwave is not configured or configured improperly
BUILDING MODULE
===============
warning: Greenwave is not configured or configured improperly
info: Starting resolving with following input modules: ['platform:f30:6:00000000', 'flatpak-common:f30:3020190906121330:548d4c8d', 'flatpak-runtime:f30:3020190906113054:a5b0195c', 'flatpak-runtime:f30:3020190906113054:a5b0195c']
info: Resolving done, possible requires: {frozenset({'flatpak-runtime:f30:3020190906113054:a5b0195c:x86_64', 'hedgewars:master:20190917180335:0:src', 'platform:f30:6:00000000:x86_64', 'flatpak-common:f30:3020190906121330:548d4c8d:x86_64'})}
info: Module platform:f30:6:00000000 imported
name: hedgewars
stream: master
version: 3020190917180335
modulemd: /home/gwyn/fedora/git/mod/hedgewars/hedgewars.yaml
log: /home/gwyn/modulebuild/builds/module-hedgewars-master-3020190917180335/mbs.log

info: Getting tag for hedgewars:master:3020190917180335
info: Start to handle hedgewars:master:3020190917180335:f1d02342 which is in init state.
info: Finding the default modules to include as buildrequires
info: The base module platform:f30:6:00000000 has no default modules
info: Setting build arches of hedgewars:master:3020190917180335:f1d02342 to ['x86_64'] based on the buildrequired module <ModuleBuild platform, id=1, stream=f30, version=6, scratch=False, state 'ready', batch 0, state_reason None>.
info: Finding any buildrequired modules that collide with the RPMs in the base modules
error: list_of_args and list_of_kwargs must be list or None.
Traceback (most recent call last):
  File "/usr/lib/python3.7/site-packages/module_build_service/scheduler/handlers/modules.py", line 193, in init
    handle_collisions_with_base_module_rpms(mmd, arches)
  File "/usr/lib/python3.7/site-packages/module_build_service/scheduler/default_modules.py", line 244, in handle_collisions_with_base_module_rpms
    bm_rpms = _get_rpms_from_tags(koji_session, bm_tags, arches)
  File "/usr/lib/python3.7/site-packages/module_build_service/scheduler/default_modules.py", line 292, in _get_rpms_from_tags
    koji_session, koji_session.listTaggedRPMS, tags, kwargs,
  File "/usr/lib/python3.7/site-packages/module_build_service/utils/general.py", line 153, in inner
    return function(*args, **kwargs)
  File "/usr/lib/python3.7/site-packages/module_build_service/builder/KojiModuleBuilder.py", line 154, in koji_retrying_multicall_map
    return koji_multicall_map(*args, **kwargs)
  File "/usr/lib/python3.7/site-packages/module_build_service/builder/KojiModuleBuilder.py", line 83, in koji_multicall_map
    raise ProgrammingError("list_of_args and list_of_kwargs must be list or None.")
module_build_service.errors.ProgrammingError: list_of_args and list_of_kwargs must be list or None.
info: State transition: 'init' -> 'failed', <ModuleBuild hedgewars, id=2, stream=master, version=3020190917180335, scratch=False, state 'failed', batch 0, state_reason 'An unknown error occurred while validating the modulemd'>
info: Scheduling shutdown.
info: Calling failed: MBSModule, 2
info: Scheduling shutdown.
Traceback (most recent call last):
  File "/usr/bin/mbs-manager", line 11, in <module>
    load_entry_point('module-build-service==2.28.0', 'console_scripts', 'mbs-manager')()
  File "/usr/lib/python3.7/site-packages/module_build_service/manage.py", line 286, in manager_wrapper
    manager.run()
  File "/usr/lib/python3.7/site-packages/flask_script/__init__.py", line 417, in run
    result = self.handle(argv[0], argv[1:])
  File "/usr/lib/python3.7/site-packages/flask_script/__init__.py", line 386, in handle
    res = handle(*args, **config)
  File "/usr/lib/python3.7/site-packages/flask_script/commands.py", line 216, in __call__
    return self.run(*args, **kwargs)
  File "/usr/lib/python3.7/site-packages/module_build_service/manage.py", line 214, in build_module_locally
    raise RuntimeError("Module build failed")
RuntimeError: Module build failed

error: mbs-manager build_module_locally failed
error: log: /home/gwyn/modulebuild/builds/module-hedgewars-master-3020190917180335/mbs.log

Comment 5 Fedora Update System 2019-09-18 01:20:31 UTC
module-build-service-2.28.0-1.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-33d2315efb

Comment 6 Fedora Update System 2019-09-18 01:26:52 UTC
module-build-service-2.28.0-1.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-6a3bd79eca

Comment 7 cqi 2019-09-18 01:34:05 UTC
Created a Pagure issue https://pagure.io/fm-orchestrator/issue/1420 to track the new issue.

Comment 8 Fedora Update System 2019-09-18 02:00:33 UTC
module-build-service-2.28.0-1.fc31 has been pushed to the Fedora 31 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-6a9d2a0a83

Comment 9 Fedora Update System 2019-09-19 17:12:09 UTC
FEDORA-2019-43cd87997c has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2019-43cd87997c

Comment 10 Fedora Update System 2019-09-19 17:12:17 UTC
FEDORA-2019-b9a5feb671 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-b9a5feb671

Comment 11 Gwyn Ciesla 2019-09-19 20:21:47 UTC
Now it just hangs for hours.

wyn@gwythsefyll hedgewars]$ flatpak-module local-build
2019-09-19 13:33:55,976 - MainThread - moksha.hub - WARNING - Cannot find qpid python module. Make sure you have python-qpid installed.
2019-09-19 13:33:56,371 - MainThread - MBS.utils.greenwave - WARNING - Greenwave is not configured or configured improperly
BUILDING MODULE
===============
warning: Greenwave is not configured or configured improperly
info: Starting resolving with following input modules: ['platform:f30:6:00000000', 'flatpak-common:f30:3020190906121330:548d4c8d', 'flatpak-runtime:f30:3020190906113054:a5b0195c', 'flatpak-runtime:f30:3020190906113054:a5b0195c']
info: Resolving done, possible requires: {frozenset({'platform:f30:6:00000000:x86_64', 'flatpak-common:f30:3020190906121330:548d4c8d:x86_64', 'hedgewars:master:20190919183358:0:src', 'flatpak-runtime:f30:3020190906113054:a5b0195c:x86_64'})}
info: Module platform:f30:6:00000000 imported
name: hedgewars
stream: master
version: 3020190919183358
modulemd: /home/gwyn/fedora/git/mod/hedgewars/hedgewars.yaml
log: /home/gwyn/modulebuild/builds/module-hedgewars-master-3020190919183358/mbs.log

info: Getting tag for hedgewars:master:3020190919183358
info: Start to handle hedgewars:master:3020190919183358:f1d02342 which is in init state.
info: Setting build arches of hedgewars:master:3020190919183358:f1d02342 to ['x86_64'] based on the buildrequired module <ModuleBuild platform, id=1, stream=f30, version=6, scratch=False, state 'ready', batch 0, state_reason None>.
info: Finding the default modules to include as buildrequires
info: The base module platform:f30:6:00000000 has no default modules
info: Finding any buildrequired modules that collide with the RPMs in the base modules
Module yaml error: Document type was unspecified or unknown

Comment 12 Fedora Update System 2019-09-20 01:56:58 UTC
module-build-service-2.28.2-1.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-b9a5feb671

Comment 13 Fedora Update System 2019-09-20 02:57:01 UTC
module-build-service-2.28.2-1.fc31 has been pushed to the Fedora 31 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-e16fdc49b9

Comment 14 Fedora Update System 2019-09-20 03:02:03 UTC
module-build-service-2.28.2-1.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-43cd87997c

Comment 15 Fedora Update System 2019-09-22 01:21:52 UTC
module-build-service-2.28.2-1.fc31 has been pushed to the Fedora 31 stable repository. If problems still persist, please make note of it in this bug report.

Comment 16 Fedora Update System 2019-09-28 01:56:28 UTC
module-build-service-2.28.2-1.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.

Comment 17 Fedora Update System 2019-09-28 03:39:08 UTC
module-build-service-2.28.2-1.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.

Comment 18 cqi 2019-09-29 03:08:13 UTC
Hi Gwyn, an MBS issue[1] is created in project upstream site, from where developers are able to track the work easily.

[1] https://pagure.io/fm-orchestrator/issue/1443

Comment 19 Gwyn Ciesla 2019-10-12 17:11:32 UTC
I still can't build a local module.

Comment 20 Matt Prahl 2019-10-14 13:49:15 UTC
I tried a local build and the issue will be resolved by:
https://pagure.io/fm-orchestrator/c/72d2c3daf446934f91c02fd8a4a27943ea388c43?branch=master

Comment 21 Gwyn Ciesla 2019-10-22 13:51:48 UTC
When might this hit Fedora? I still can't build on f31 or f30.

Comment 22 Matt Prahl 2019-10-22 15:33:44 UTC
mikem is planning to cut a release within the next week.

Comment 23 Gwyn Ciesla 2019-11-05 16:16:47 UTC
Any ETA?

Comment 24 Fedora Update System 2019-11-05 20:28:53 UTC
FEDORA-2019-bbeb415240 has been submitted as an update to Fedora 31. https://bodhi.fedoraproject.org/updates/FEDORA-2019-bbeb415240

Comment 25 Fedora Update System 2019-11-05 20:29:02 UTC
FEDORA-2019-eeacaf3e82 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-eeacaf3e82

Comment 26 Gwyn Ciesla 2019-11-05 20:53:32 UTC
Failing. Can be reproduced with any flatpak I've tried so far:

fedpkg clone flatpaks/foobillard
cd foobillard
[gwyn@gwythsefyll foobillard]$ flatpak-module local-build
2019-11-05 14:45:35,418 - MainThread - moksha.hub - WARNING - Cannot find qpid python module. Make sure you have python-qpid installed.
2019-11-05 14:45:35,803 - MainThread - MBS.utils.greenwave - WARNING - Greenwave is not configured or configured improperly
BUILDING MODULE
===============
warning: Greenwave is not configured or configured improperly
info: Starting resolving with following input modules: ['platform:f30:6:00000000', 'flatpak-common:f30:3020191105145610:548d4c8d', 'flatpak-runtime:f30:3020191105123105:a5b0195c', 'flatpak-runtime:f30:3020191105123105:a5b0195c']
info: Resolving done, possible requires: {frozenset({'foobillard:master:20191105204538:0:src', 'flatpak-runtime:f30:3020191105123105:a5b0195c:x86_64', 'flatpak-common:f30:3020191105145610:548d4c8d:x86_64', 'platform:f30:6:00000000:x86_64'})}
info: Module platform:f30:6:00000000 imported
name: foobillard
stream: master
version: 3020191105204538
modulemd: /home/gwyn/fedora/flatpaks/foobillard/foobillard.yaml
log: /home/gwyn/modulebuild/builds/module-foobillard-master-3020191105204538/mbs.log

info: Getting tag for foobillard:master:3020191105204538
info: Start to handle foobillard:master:3020191105204538:f1d02342 which is in init state.
info: Setting build arches of foobillard:master:3020191105204538:f1d02342 to ['x86_64'] based on the buildrequired module <ModuleBuild platform, id=1, stream=f30, version=6, scratch=False, state 'ready', batch 0, state_reason None>.
info: Finding the default modules to include as buildrequires
info: The base module platform:f30:6:00000000 has no default modules
warning: The necessary conflicts could not be generated due to RHBZ#1693683. Some RPMs from the base modules (platform) may end up being used over modular RPMs. This may result in different behavior than a production build.
info: State transition: 'init' -> 'wait', <ModuleBuild foobillard, id=2, stream=master, version=3020191105204538, scratch=False, state 'wait', batch 0, state_reason None>
info: Getting tag for foobillard:master:3020191105204538
info: Downloading 0 packages from Koji tag module-flatpak-runtime-f30-3020191105123105-a5b0195c to /home/gwyn/modulebuild/cache/koji_tags/module-flatpak-runtime-f30-3020191105123105-a5b0195c
info: Downloading 0 packages from Koji tag module-f30-build to /home/gwyn/modulebuild/cache/koji_tags/module-f30-build
info: Downloading 0 packages from Koji tag module-flatpak-common-f30-3020191105145610-548d4c8d to /home/gwyn/modulebuild/cache/koji_tags/module-flatpak-common-f30-3020191105145610-548d4c8d
info: Executing the command "rpmbuild -bs module-build-macros.spec --define _topdir /tmp/module_build_service-build-macros1a_024ln --define _sourcedir /tmp/module_build_service-build-macros1a_024ln/SOURCES", stdout log: /dev/null
info: Starting building artifact module-build-macros: /tmp/module_build_service-build-macros1a_024ln/SRPMS/module-build-macros-0.1-1.module+f30+2+86a9cbc7.src.rpm
info: Executing the command "mock -v -r /home/gwyn/modulebuild/builds/module-foobillard-master-3020191105204538/config/mock-PoolThread-twisted.internet.reactor-0.cfg --init", stdout log: /home/gwyn/modulebuild/builds/module-foobillard-master-3020191105204538/results/module-build-macros-mock-stdout.log, stderr log: /home/gwyn/modulebuild/builds/module-foobillard-master-3020191105204538/results/module-build-macros-mock-stderr.log
error: Error while building artifact module-build-macros: Command '['mock', '-v', '-r', '/home/gwyn/modulebuild/builds/module-foobillard-master-3020191105204538/config/mock-PoolThread-twisted.internet.reactor-0.cfg', '--init']' returned non-zero value 30, stdout log: /home/gwyn/modulebuild/builds/module-foobillard-master-3020191105204538/results/module-build-macros-mock-stdout.log, stderr log: /home/gwyn/modulebuild/builds/module-foobillard-master-3020191105204538/results/module-build-macros-mock-stderr.log
info: State transition: 'wait' -> 'build', <ModuleBuild foobillard, id=2, stream=master, version=3020191105204538, scratch=False, state 'build', batch 1, state_reason None>
info: Calling failed: KojiBuildChange, a faked internal message
info: State transition: 'build' -> 'failed', <ModuleBuild foobillard, id=2, stream=master, version=3020191105204538, scratch=False, state 'failed', batch 1, state_reason 'Failed to build artifact module in Koji'>
info: Scheduling shutdown.
info: Scheduling shutdown.
info: Scheduling shutdown.
info: Calling failed: MBSModule, 4
info: Scheduling shutdown.
Traceback (most recent call last):
  File "/usr/bin/mbs-manager", line 11, in <module>
    load_entry_point('module-build-service==2.30.0', 'console_scripts', 'mbs-manager')()
  File "/usr/lib/python3.7/site-packages/module_build_service/manage.py", line 265, in manager_wrapper
    manager.run()
  File "/usr/lib/python3.7/site-packages/flask_script/__init__.py", line 417, in run
    result = self.handle(argv[0], argv[1:])
  File "/usr/lib/python3.7/site-packages/flask_script/__init__.py", line 386, in handle
    res = handle(*args, **config)
  File "/usr/lib/python3.7/site-packages/flask_script/commands.py", line 216, in __call__
    return self.run(*args, **kwargs)
  File "/usr/lib/python3.7/site-packages/module_build_service/manage.py", line 193, in build_module_locally
    raise RuntimeError("Module build failed")
RuntimeError: Module build failed

error: mbs-manager build_module_locally failed
error: log: /home/gwyn/modulebuild/builds/module-foobillard-master-3020191105204538/mbs.log

Comment 27 Fedora Update System 2019-11-06 14:03:37 UTC
module-build-service-2.30.0-1.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-eeacaf3e82

Comment 28 Fedora Update System 2019-11-06 14:13:26 UTC
module-build-service-2.30.0-1.fc31 has been pushed to the Fedora 31 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-bbeb415240

Comment 29 Fedora Update System 2019-11-06 14:52:13 UTC
FEDORA-2019-6ac0548dee has been submitted as an update to Fedora 31. https://bodhi.fedoraproject.org/updates/FEDORA-2019-6ac0548dee

Comment 30 Fedora Update System 2019-11-06 14:52:20 UTC
FEDORA-2019-6571069b2c has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-6571069b2c

Comment 31 Gwyn Ciesla 2019-11-06 14:59:01 UTC
I get the same error with this version.

Comment 32 Matt Prahl 2019-11-06 15:02:32 UTC
Please clear your cache at `~/modulebuild` and try again. I am able to build your module successfully on Fedora 30.

Comment 33 Gwyn Ciesla 2019-11-06 15:10:49 UTC
Did that, failing on Fedora 31.

Comment 34 Matt Prahl 2019-11-06 15:16:50 UTC
Can you post any error logs?

Comment 35 Gwyn Ciesla 2019-11-06 15:29:06 UTC
Created attachment 1633353 [details]
Logs from attempted ricochet build

Comment 36 Fedora Update System 2019-11-06 16:11:32 UTC
module-build-service-2.30.0-1.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-889b2cf035

Comment 37 Matt Prahl 2019-11-06 16:26:14 UTC
I wasn't able to reproduce the issue on my Fedora 30 laptop, but I have an idea of what it could be. Could you apply the changes in this patch?
https://pagure.io/fm-orchestrator/pull-request/1495.patch

The path to that file on my system is /usr/lib/python3.7/site-packages/module_build_service/builder/MockModuleBuilder.py.

Comment 38 Gwyn Ciesla 2019-11-06 16:39:39 UTC
No change.

Comment 39 Fedora Update System 2019-11-07 01:44:40 UTC
module-build-service-2.30.1-1.fc31 has been pushed to the Fedora 31 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-6ac0548dee

Comment 40 Fedora Update System 2019-11-07 01:50:42 UTC
module-build-service-2.30.1-1.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-9eb0aba1e6

Comment 41 Fedora Update System 2019-11-07 02:27:28 UTC
module-build-service-2.30.1-1.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-6571069b2c

Comment 42 Matt Prahl 2019-11-07 16:20:50 UTC
Could you please try the following patch?
https://pagure.io/fm-orchestrator/pull-request/1501.patch

Comment 43 Gwyn Ciesla 2019-11-07 22:08:53 UTC
Progress! It build the module, but not the container:

Complete!
INFO: 
Finish: run
info: Cleaning and exporting filesystem
running: mock -q -r /home/gwyn/modulebuild/flatpaks/ricochet-master-3020191107185833/mock.cfg --copyin /home/gwyn/modulebuild/flatpaks/ricochet-master-3020191107185833/finalize.sh /root/finalize.sh
running: mock -q -r /home/gwyn/modulebuild/flatpaks/ricochet-master-3020191107185833/mock.cfg --shell /root/finalize.sh
Traceback (most recent call last):
  File "/usr/lib64/python3.7/tarfile.py", line 2289, in next
    tarinfo = self.tarinfo.fromtarfile(self)
  File "/usr/lib64/python3.7/tarfile.py", line 1095, in fromtarfile
    obj = cls.frombuf(buf, tarfile.encoding, tarfile.errors)
  File "/usr/lib64/python3.7/tarfile.py", line 1033, in frombuf
    raise TruncatedHeaderError("truncated header")
tarfile.TruncatedHeaderError: truncated header

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/bin/flatpak-module", line 11, in <module>
    load_entry_point('flatpak-module-tools==0.11.1', 'console_scripts', 'flatpak-module')()
  File "/usr/lib/python3.7/site-packages/click/core.py", line 763, in __call__
    return self.main(*args, **kwargs)
  File "/usr/lib/python3.7/site-packages/click/core.py", line 716, in main
    rv = self.invoke(ctx)
  File "/usr/lib/python3.7/site-packages/click/core.py", line 1136, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/usr/lib/python3.7/site-packages/click/core.py", line 955, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/usr/lib/python3.7/site-packages/click/core.py", line 554, in invoke
    return callback(*args, **kwargs)
  File "/usr/lib/python3.7/site-packages/flatpak_module_tools/cli.py", line 67, in local_build
    tarfile = container_builder.build()
  File "/usr/lib/python3.7/site-packages/flatpak_module_tools/container_builder.py", line 185, in build
    filesystem_tar, manifestfile = builder._export_from_stream(process.stdout, close_stream=False)
  File "/usr/lib/python3.7/site-packages/flatpak_module_tools/flatpak_builder.py", line 551, in _export_from_stream
    in_tf = tarfile.open(fileobj=export_stream, mode='r|')
  File "/usr/lib64/python3.7/tarfile.py", line 1603, in open
    t = cls(name, filemode, stream, **kwargs)
  File "/usr/lib64/python3.7/tarfile.py", line 1484, in __init__
    self.firstmember = self.next()
  File "/usr/lib64/python3.7/tarfile.py", line 2307, in next
    raise ReadError(str(e))
tarfile.ReadError: truncated header
[gwyn@gwythsefyll ricochet]$

Comment 44 Matt Prahl 2019-11-08 13:20:47 UTC
Great! I'm glad we made progress. The MBS team does not maintain the flatpak tooling, so I suggest you reach out to them separately for help with that. I'll cut a release with this patch though.

Comment 45 Fedora Update System 2019-11-08 13:47:28 UTC
FEDORA-2019-67ddbb00f0 has been submitted as an update to Fedora 31. https://bodhi.fedoraproject.org/updates/FEDORA-2019-67ddbb00f0

Comment 46 Fedora Update System 2019-11-08 13:47:39 UTC
FEDORA-2019-07014a8d24 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2019-07014a8d24

Comment 47 Fedora Update System 2019-11-08 13:47:46 UTC
FEDORA-2019-bd61f5f001 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-bd61f5f001

Comment 48 Fedora Update System 2019-11-09 23:21:05 UTC
module-build-service-2.30.2-1.fc31 has been pushed to the Fedora 31 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-67ddbb00f0

Comment 49 Fedora Update System 2019-11-10 00:39:59 UTC
module-build-service-2.30.2-1.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-bd61f5f001

Comment 50 Fedora Update System 2019-11-10 04:35:57 UTC
module-build-service-2.30.2-1.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-07014a8d24

Comment 51 Gwyn Ciesla 2019-11-11 14:43:41 UTC
This one has issues for me:

gwyn@gwythsefyll ricochet]$ flatpak-module build-module
2019-11-11 08:42:54,539 - MainThread - moksha.hub - WARNING - Cannot find qpid python module. Make sure you have python-qpid installed.
2019-11-11 08:42:54,841 - MainThread - MBS.utils.greenwave - WARNING - Greenwave is not configured or configured improperly
BUILDING MODULE
===============
warning: Greenwave is not configured or configured improperly
Traceback (most recent call last):
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/engine/base.py", line 2275, in _wrap_pool_connect
    return fn()
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 363, in connect
    return _ConnectionFairy._checkout(self)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 760, in _checkout
    fairy = _ConnectionRecord.checkout(pool)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 492, in checkout
    rec = pool._do_get()
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/impl.py", line 238, in _do_get
    return self._create_connection()
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 308, in _create_connection
    return _ConnectionRecord(self)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 437, in __init__
    self.__connect(first_connect_check=True)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 639, in __connect
    connection = pool._invoke_creator(self)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/engine/strategies.py", line 114, in connect
    return dialect.connect(*cargs, **cparams)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/engine/default.py", line 481, in connect
    return self.dbapi.connect(*cargs, **cparams)
sqlite3.OperationalError: unable to open database file

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/bin/mbs-manager", line 11, in <module>
    load_entry_point('module-build-service==2.30.2', 'console_scripts', 'mbs-manager')()
  File "/usr/lib/python3.7/site-packages/module_build_service/manage.py", line 267, in manager_wrapper
    manager.run()
  File "/usr/lib/python3.7/site-packages/flask_script/__init__.py", line 417, in run
    result = self.handle(argv[0], argv[1:])
  File "/usr/lib/python3.7/site-packages/flask_script/__init__.py", line 386, in handle
    res = handle(*args, **config)
  File "/usr/lib/python3.7/site-packages/flask_script/commands.py", line 216, in __call__
    return self.run(*args, **kwargs)
  File "/usr/lib/python3.7/site-packages/module_build_service/manage.py", line 174, in build_module_locally
    stream=str(stream), skiptests=skiptests
  File "/usr/lib/python3.7/site-packages/module_build_service/utils/submit.py", line 537, in submit_module_build_from_yaml
    return submit_module_build(db_session, username, mmd, params)
  File "/usr/lib/python3.7/site-packages/module_build_service/utils/submit.py", line 910, in submit_module_build
    mmds = generate_expanded_mmds(db_session, mmd, raise_if_stream_ambigous, default_streams)
  File "/usr/lib/python3.7/site-packages/module_build_service/utils/mse.py", line 415, in generate_expanded_mmds
    db_session, current_mmd, default_streams, raise_if_stream_ambigous)
  File "/usr/lib/python3.7/site-packages/module_build_service/utils/mse.py", line 338, in get_mmds_required_by_module_recursively
    base_module_mmds = get_base_module_mmds(db_session, mmd)
  File "/usr/lib/python3.7/site-packages/module_build_service/utils/mse.py", line 289, in get_base_module_mmds
    mmds = resolver.get_module_modulemds(name, stream)
  File "/usr/lib/python3.7/site-packages/module_build_service/resolver/MBSResolver.py", line 176, in get_module_modulemds
    local_modules = models.ModuleBuild.local_modules(self.db_session, name, stream)
  File "/usr/lib/python3.7/site-packages/module_build_service/models.py", line 728, in local_modules
    local_modules = db_session.query(ModuleBuild).filter_by(**filters).all()
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/query.py", line 3186, in all
    return list(self)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/query.py", line 3342, in __iter__
    return self._execute_and_instances(context)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/query.py", line 3364, in _execute_and_instances
    querycontext, self._connection_from_session, close_with_result=True
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/query.py", line 3379, in _get_bind_args
    mapper=self._bind_mapper(), clause=querycontext.statement, **kw
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/query.py", line 3357, in _connection_from_session
    conn = self.session.connection(**kw)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/session.py", line 1124, in connection
    execution_options=execution_options,
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/session.py", line 1130, in _connection_for_bind
    engine, execution_options
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/orm/session.py", line 431, in _connection_for_bind
    conn = bind._contextual_connect()
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/engine/base.py", line 2239, in _contextual_connect
    self._wrap_pool_connect(self.pool.connect, None),
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/engine/base.py", line 2279, in _wrap_pool_connect
    e, dialect, self
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/engine/base.py", line 1544, in _handle_dbapi_exception_noconnection
    util.raise_from_cause(sqlalchemy_exception, exc_info)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/util/compat.py", line 398, in raise_from_cause
    reraise(type(exception), exception, tb=exc_tb, cause=cause)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/util/compat.py", line 152, in reraise
    raise value.with_traceback(tb)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/engine/base.py", line 2275, in _wrap_pool_connect
    return fn()
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 363, in connect
    return _ConnectionFairy._checkout(self)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 760, in _checkout
    fairy = _ConnectionRecord.checkout(pool)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 492, in checkout
    rec = pool._do_get()
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/impl.py", line 238, in _do_get
    return self._create_connection()
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 308, in _create_connection
    return _ConnectionRecord(self)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 437, in __init__
    self.__connect(first_connect_check=True)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/pool/base.py", line 639, in __connect
    connection = pool._invoke_creator(self)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/engine/strategies.py", line 114, in connect
    return dialect.connect(*cargs, **cparams)
  File "/usr/lib64/python3.7/site-packages/sqlalchemy/engine/default.py", line 481, in connect
    return self.dbapi.connect(*cargs, **cparams)
sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) unable to open database file
(Background on this error at: http://sqlalche.me/e/e3q8)

error: mbs-manager build_module_locally failed
error: log: None

Comment 52 Matt Prahl 2019-11-11 16:21:06 UTC
Sorry about that. I made a release and wasn't aware a PR had been merged to master since I tested local builds. The following PR fixed the issue for me:
https://pagure.io/fm-orchestrator/pull-request/1503

I've kicked off builds for the new release.

Comment 53 Fedora Update System 2019-11-11 16:27:17 UTC
FEDORA-2019-420f93e96c has been submitted as an update to Fedora 32. https://bodhi.fedoraproject.org/updates/FEDORA-2019-420f93e96c

Comment 54 Fedora Update System 2019-11-11 16:27:26 UTC
FEDORA-2019-4ad4c294a6 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2019-4ad4c294a6

Comment 55 Fedora Update System 2019-11-11 16:27:33 UTC
FEDORA-2019-fa7c729fb4 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-fa7c729fb4

Comment 56 Fedora Update System 2019-11-11 16:27:40 UTC
FEDORA-2019-28f0726f26 has been submitted as an update to Fedora 31. https://bodhi.fedoraproject.org/updates/FEDORA-2019-28f0726f26

Comment 57 Gwyn Ciesla 2019-11-11 16:56:14 UTC
Excellent, thanks!

Comment 58 Fedora Update System 2019-11-12 03:08:02 UTC
module-build-service-2.30.3-1.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-fa7c729fb4

Comment 59 Fedora Update System 2019-11-12 04:26:17 UTC
module-build-service-2.30.3-1.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-4ad4c294a6

Comment 60 Fedora Update System 2019-11-13 04:56:40 UTC
module-build-service-2.30.3-1.fc31 has been pushed to the Fedora 31 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-28f0726f26

Comment 61 Michal Konecny 2019-11-13 12:26:32 UTC
I tested the 2.30.3-1.fc31 and got `sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) unable to open database file`

Comment 62 Matt Prahl 2019-11-13 15:23:04 UTC
Hi Michal,
I tried module-build-service-2.30.3-1.fc31.noarch.rpm [1] on a clean Fedora 31 VM and I can't reproduce the issue. Do you have a full traceback?


1 - https://kojipkgs.fedoraproject.org//packages/module-build-service/2.30.3/1.fc31/noarch/module-build-service-2.30.3-1.fc31.noarch.rpm

Comment 63 Michal Konecny 2019-11-13 16:22:38 UTC
Nevermind, I checked the package and I have module-build-service-2.30.2-1.fc31.noarch, so it is fault on my side.

But still I'm surprised that `sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2019-28f0726f26` doesn't update anything.

Comment 64 Fedora Update System 2019-11-19 01:35:24 UTC
module-build-service-2.30.3-1.fc31 has been pushed to the Fedora 31 stable repository. If problems still persist, please make note of it in this bug report.

Comment 65 Fedora Update System 2019-11-20 03:17:55 UTC
module-build-service-2.30.3-1.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.

Comment 66 Fedora Update System 2019-11-20 03:49:41 UTC
module-build-service-2.30.3-1.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.