Skip to content

Commit

Permalink
Minor cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
abates committed Apr 30, 2024
1 parent 8ba4222 commit bc6c80b
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 23 deletions.
17 changes: 0 additions & 17 deletions nautobot_design_builder/design_job.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,23 +169,6 @@ def implement_design(self, context, design_file, commit):
design = self.render_design(context, design_file)
self.log_debug(f"New Design to be implemented: {design}")

# The design to apply will take into account the previous journal that keeps track (in the builder_output)
# of the design used (i.e., the YAML) including the Nautobot IDs that will help to reference them
# self.environment.builder_output[design_file] = copy.deepcopy(design)
# if last_journal and last_journal.builder_output:
# # The last design output is used as the reference to understand what needs to be changed
# # The design output store the whole set of attributes, not only the ones taken into account
# # in the implementation
# previous_design = last_journal.builder_output[design_file]
# self.log_debug(f"Design from previous Journal: {previous_design}")

# for key, new_value in design.items():
# old_value = previous_design[key]
# future_value = self.environment.builder_output[design_file][key]
# combine_designs(new_value, old_value, future_value, deprecated_design, key)

# self.log_debug(f"Design to implement after reduction: {design}")

self.environment.implement_design(design, commit)

def _setup_journal(self, instance_name: str):
Expand Down
6 changes: 0 additions & 6 deletions nautobot_design_builder/signals.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,3 @@ def load_pre_delete_signals():


load_pre_delete_signals()


# @receiver(signal=post_delete, sender=DesignInstance)
# def handle_post_delete_design_instance(sender, instance, **kwargs): # pylint: disable=unused-argument
# """Cleaning up the Tag created for a design instance."""
# Tag.objects.get(name=f"Managed by {instance}").delete()

0 comments on commit bc6c80b

Please sign in to comment.