TODO: Allow the use of fuzzy patching.

Open
#172 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
25/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Stale
Tech stack
java
Domain
tooling

Research direction

The issue names no files, tests, or entry points. Start by locating MCPConfig's existing patch application flow and comparing it with the primary Forge repo's fuzzy patching triggered by the Pupdating flag; done means patches can resolve shifted context and send unsuccessful applications to a rejects folder.

Written by the indexing model from the issue text.

Description

type: enhancement

So, we're thinking about snapshots.

In the primary Forge repo, we're using fuzzy patching (triggered by the Pupdating flag) to help automate the resolution of most patches to a changed and shifted file.

It works by finding the closest context match (the surrounding area around a patch hunk) if there is no exact match to target. If there is no "close" match, the patch goes to a rejects folder for manual resolution by a human operator.

This would help greatly in MCPConfig, perhaps with a lower threshold for failed applications so that common fuzzy patching issues (such as duplicated lines) are less likely to happen.

Switching to fuzzy patching, combined with incremental patches (described in another issue) will mean that the 1.19-pre1 to 1.19-rc2 update would have roughly 3 files rather than roughly 60.

Dominant language
Java
Stars
247
Forks
84
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from MinecraftForge/MCPConfig

All issues in MinecraftForge/MCPConfig

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.