Bug 1695642 - New bug for non-existing component: Can\'t call method "sub_component_count" on an undefined value
Summary: New bug for non-existing component: Can\'t call method "sub_component_count" ...
Keywords:
Status: CLOSED DUPLICATE of bug 1679385
Alias: None
Product: Bugzilla
Classification: Community
Component: Creating/Changing Bugs
Version: 5.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: PnT DevOps Devs
QA Contact: tools-bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-04-03 13:36 UTC by Viliam Križan
Modified: 2025-10-16 23:53 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2019-07-11 22:04:15 UTC
Embargoed:


Attachments (Terms of Use)

Description Viliam Križan 2019-04-03 13:36:11 UTC
Description of problem:

Server errors when a new bug is being created against non-existing component.  It looks like a bug in then code.

  Fault -32000: 'Can\'t call method "sub_component_count" on an undefined value at /var/www/html/bugzilla/extensions/SubComponents/Extension.pm line 931.\n'


Version-Release number of selected component (if applicable):

version 5.0.4.rh14

How reproducible:


Steps to Reproduce:
1. $ bugzilla new -p "Fedora" -c unknown --summary "test" --comment "test"

Actual results:

Errors out with subcomponent error.


Expected results:
 
Error explaining that the provided component is not existing.

Comment 1 Michal Konecny 2019-07-11 19:15:11 UTC
I'm now having the same issue on the-new-hotness which is creating issues in Bugzilla to notify Fedora maintainers about new versions.

Here is the full traceback from the-new-hotness:
```
raceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/fedora_messaging/twisted/protocol.py", line 239, in _read
    yield threads.deferToThread(consumer.callback, message)
  File "/usr/lib64/python3.7/site-packages/twisted/python/threadpool.py", line 250, in inContext
    result = inContext.theWork()
  File "/usr/lib64/python3.7/site-packages/twisted/python/threadpool.py", line 266, in <lambda>
    inContext.theWork = lambda: context.call(ctx, func, *args, **kw)
  File "/usr/lib64/python3.7/site-packages/twisted/python/context.py", line 122, in callWithContext
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
  File "/usr/lib64/python3.7/site-packages/twisted/python/context.py", line 85, in callWithContext
    return func(*args,**kw)
  File "/usr/local/lib/python3.7/site-packages/hotness/consumers.py", line 161, in __call__
    self.handle_anitya_version_update(msg)
  File "/usr/local/lib/python3.7/site-packages/hotness/consumers.py", line 206, in handle_anitya_version_update
    self._handle_anitya_update(upstream, pname, msg)
  File "/usr/local/lib/python3.7/site-packages/hotness/consumers.py", line 281, in _handle_anitya_update
    projectid, package, upstream, version, release, url
  File "/usr/local/lib/python3.7/site-packages/hotness/bz.py", line 133, in handle
    bug = self.create_bug(**kwargs)
  File "/usr/local/lib/python3.7/site-packages/hotness/bz.py", line 268, in create_bug
    new_bug = self.bugzilla.createbug(**bug_dict)
  File "/usr/lib/python3.7/site-packages/bugzilla/base.py", line 1741, in createbug
    rawbug = self._proxy.Bug.create(data)
  File "/usr/lib64/python3.7/xmlrpc/client.py", line 1112, in __call__
    return self.__send(self.__name, args)
  File "/usr/lib/python3.7/site-packages/bugzilla/transport.py", line 104, in _ServerProxy__request
    self)._ServerProxy__request(methodname, params)
  File "/usr/lib64/python3.7/xmlrpc/client.py", line 1452, in __request
    verbose=self.__verbose
  File "/usr/lib/python3.7/site-packages/bugzilla/transport.py", line 201, in request
    return self._request_helper(url, request_body)
  File "/usr/lib/python3.7/site-packages/bugzilla/transport.py", line 179, in _request_helper
    return self.parse_response(response)
  File "/usr/lib/python3.7/site-packages/bugzilla/transport.py", line 154, in parse_response
    return unmarshaller.close()
  File "/usr/lib64/python3.7/xmlrpc/client.py", line 656, in close
    raise Fault(**self._stack[0])
xmlrpc.client.Fault: <Fault -32000: 'Can\'t call method "sub_component_count" on an undefined value at /var/www/html/bugzilla/extensions/SubComponents/Extension.pm line 931.\n'>
```

I'm trying to create a bug for component `golang-github-Masterminds-vcs`, which is already created here https://bugzilla.redhat.com/show_bug.cgi?id=1435628, but instead of getting error that the bug is already existing I'm getting above error.

Additional info:
This isn't happening on staging version of the-new-hotness which is communicating with http://partner-bugzilla.redhat.com/ instead of bugzilla.redhat.com.

Comment 2 Jeff Fearn 🐞 2019-07-11 22:04:15 UTC

*** This bug has been marked as a duplicate of bug 1679385 ***


Note You need to log in before you can comment on or make changes to this bug.