sclorg / rpm-list-builder

RPM List Builder helps you to build a list of defined RPM packages including Software Collection from the recipe file
GNU General Public License v2.0
4 stars 8 forks source link

bootstrap_position in pacakge_dict object #78

Closed junaruga closed 7 years ago

junaruga commented 7 years ago

Right now "'bootstrap_position': None" is always set in package_dict object. When user fails to build a package, the package_dict is dumped as a error message.

For example.

$ rpmlb \
  --build something \
...
  ../rhscl-rebuild-recipes/ror.yml \
  rh-ror50
...
RuntimeError: pacakge_dict: {'name': 'rubygem-puma', 'bootstrap_position': None}, num: 094, work_dir: /home/jaruga/tmp/rpmlb_work_dir

However I suppose that NOT keeping bootstrap_position element in the object might be better, if bootstrap_position does not have the value. Because when user build a collection that is not related to bootstrapping or Koji, maybe user do not want to know the information.

khardix commented 7 years ago

I do not think we want to (or need to) hide that information. From the looks of it, this error is pretty much debugging info – and in that case, we want to show user all the info we know. The user can always choose to ignore it…

I think here it would be better to change the error message to something informative (i.e. why the build failed), and log the package_dict and others as DEBUG messages. This means that user of the rpmlb gets an (hopefully) understandable error, and developer of the recipe can turn on debugging messages and get all the information.

junaruga commented 7 years ago

@khardix okay. I agree with you. Thanks for your comment. I would close this ticket.