Pierre-Yves David <pierre-yves.david@octobus.net> [Thu, 23 Nov 2023 20:09:34 +0100] rev 51348
delta-find: drop some dead debug code
Seems like it was never put to use, so lets simply remove it for now.
Pierre-Yves David <pierre-yves.david@octobus.net> [Sun, 07 Jan 2024 03:34:27 +0100] rev 51347
delta-find: introduce and use specialized _DeltaSearch class
For now, we introduce some very simple variant, but they are still useful to
display how having the class can helps keeping the simple case simple and
their special case out of more advanced logic.
Pierre-Yves David <pierre-yves.david@octobus.net> [Sun, 07 Jan 2024 01:05:10 +0100] rev 51346
delta-find: introduce a base class for _DeltaSearch
This prepare the introduction of specialized the class in the next changesets.
Pierre-Yves David <pierre-yves.david@octobus.net> [Sun, 07 Jan 2024 03:23:24 +0100] rev 51345
delta-find: simplify the delta checking function for snapshot
Since the function is all about snapshot, we can safely use an early return and
make the result simpler.
Pierre-Yves David <pierre-yves.david@octobus.net> [Sun, 07 Jan 2024 00:56:15 +0100] rev 51344
delta-find: move good delta code earlier in the class
Nothing change except the code location. This greatly helps readability of the
next future diff,
Pierre-Yves David <pierre-yves.david@octobus.net> [Thu, 04 Jan 2024 17:20:30 +0100] rev 51343
delta-find: split is_good_delta_info into more thematic function
Same logic as for candidate filtering, we group code into related sub method.
This will help clarifying later patches as some logic is pre-splitted
Pierre-Yves David <pierre-yves.david@octobus.net> [Thu, 04 Jan 2024 15:35:57 +0100] rev 51342
delta-find: clarify some comment and code in is_good_delta_info
We move the comment closer to the code it describ and we compute an
intermediate value without using the `textlen` variable, as it will stop being
defined in a future patch.
This will clarify future patches.
Pierre-Yves David <pierre-yves.david@octobus.net> [Thu, 04 Jan 2024 15:35:36 +0100] rev 51341
delta-find: move delta size check earlier in is_good_delta_info
This will clarify future patches by regrouping related logic before larger
movement.
Pierre-Yves David <pierre-yves.david@octobus.net> [Thu, 04 Jan 2024 15:04:10 +0100] rev 51340
delta-find: split the delta-chain part of `_pre_filter_rev` in a method
Since `_pre_filter_rev` contains logic from various sources of constraint, we
start splitting is in subfunction to clarify and document the grouping.
Pierre-Yves David <pierre-yves.david@octobus.net> [Thu, 04 Jan 2024 14:51:48 +0100] rev 51339
delta-find: split the "sparse" part of `_pre_filter_rev` in a method
Since `_pre_filter_rev` contains logic from various sources of constraint, we
start splitting is in subfunction to clarify and document the grouping.
Pierre-Yves David <pierre-yves.david@octobus.net> [Thu, 23 Nov 2023 18:56:31 +0100] rev 51338
delta-find: split the generic part of `_pre_filter_rev` in a method
Since `_pre_filter_rev` contains logic from various sources of constraint, we
start splitting is in subfunction to clarify and document the grouping.
Pierre-Yves David <pierre-yves.david@octobus.net> [Thu, 04 Jan 2024 14:39:10 +0100] rev 51337
delta-find: drop the temporary indent
Now that the complicated change is made, we can do the noisy one.
Pierre-Yves David <pierre-yves.david@octobus.net> [Thu, 23 Nov 2023 18:40:47 +0100] rev 51336
delta-find: move pre-filtering of individual revision in its own function
This goes one step further than the previous change by making the pre-filtering
of individual candicates revision in its own function. This will allow subclass
to easily configure this filtering with their own constrains.
The `if True:` part help the readability of this diff a lot and will be drop in
to the next changesets.
Pierre-Yves David <pierre-yves.david@octobus.net> [Thu, 23 Nov 2023 04:21:07 +0100] rev 51335
delta-find: move pre-filtering of candidates in its own function
This organise the code further and open the way to specialization via
sub-classing. Something important for the coming changes.