def METHOD_NAME(business_units):
    outsys("\nRunning {}() ".format(who_am_i()))
    for internal_id, data in business_units.items():
        if data.get('category'):
            for name in data['benchmarknames']:
                outsys('.')
                new_bench, created = Benchmarkname.objects.get_or_create(name=name)
                if created:
                    log("Created bench: {pk}, {label}",
                        dict(
                            label=name,
                            pk=new_bench.id,
                            event=ACTION_BENCH_CREATE
                        )
                        )
                else:
                    log("Found existing bench: {pk}, {label}",
                        dict(
                            label=name,
                            pk=new_bench.id,
                            event=ACTION_BENCH_FOUND
                        )
                        )
                try:
                    data['category'].benchmarknames.add(new_bench)
                except Exception:
                    # we shouldn't end up here since we're testing for the existance of the category above
                    pass
        else:
            outsys('*')
            log(
                "No category set of business unit with internal ID {internal_id}",
                dict(
                    internal_id=internal_id,
                    event=ERROR_CATEGORY_MISSING
                )
            )