mozilla-releng / firefox-infra-changelog

Automated tool which builds a changelog of commits happening on git and hg that could affect Firefox CI Infra.
2 stars 8 forks source link

[OOP] Garbage Collector #460

Open danlabici opened 5 years ago

danlabici commented 5 years ago

As we reach the end of development, we need to implement some cleaning strategy for our Git and Mercurial objects.

An example of proprieties with don't need (in each object) is:

This needs to be implemented as a method in each class. At the end, we only want a clean (and focused) object that has only the data we actually care about.

mutterroland commented 5 years ago

Regards cleaning FICMercurial: Do we still need changeset_index , commit_author and so on from FICDataVault into FicMercurial class? I mean everything is built within the class without using those attributes. We can still build methods that will return a value each time it is called inside the loop that builds the final .json file but does that makes a difference?

Example:


         self.commit_author = self.changesets_json.get("pushes").get(push).get("changesets")[commit]["author"]
         return self.commit_author```