Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TASK: Code a withdraw list of Parts, patchable by ModuleManager #258

Closed
Lisias opened this issue Jul 1, 2022 · 5 comments
Closed

TASK: Code a withdraw list of Parts, patchable by ModuleManager #258

Lisias opened this issue Jul 1, 2022 · 5 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@Lisias
Copy link

Lisias commented Jul 1, 2022

Some part sets choose to code things in a way that TweakScale can't cope without help.

While this help is not provided by a Companion (or 3rd party), TweakScale needs to withdraw itself from these parts even if someone had patched it intentionally.

The withdraw list must be maintainable by a ModuleManager patch, so the Companions can update it as the support is implemented.

The thing must be able to withdraw TweakScale from a part:

  • Based on the parentURL (see MM config cache) - with regex ✔︎
  • Based on the parentURL (see MM config cache) - with prefix (simpler than regex) ✔︎
  • Based on the partName - with regex ✔︎
  • Based on the presence of modules - NO regex on this one. ✔︎
  • Must have an option telling if ANY or ALL conditions should be met.

This task will supersede the checks from

@Lisias Lisias self-assigned this Jul 1, 2022
@Lisias Lisias added this to the 2.4.8.0 milestone Jul 1, 2022
@Lisias
Copy link
Author

Lisias commented Jul 8, 2022

The ANY or ALL conditions was dropped, as it would add significant complexity on the code. The implemented behaviour is similar to ALL.

Just break the rule into many smaller ones - simple code, complex data structures rules!

Lisias added a commit that referenced this issue Jul 8, 2022
@Lisias
Copy link
Author

Lisias commented Jul 8, 2022

The requirement "Based on the presence of modules - NO regex on this one." was already implemented while closing #254

@Lisias Lisias added the enhancement New feature or request label Jul 8, 2022
Lisias added a commit that referenced this issue Jul 8, 2022
@Lisias Lisias modified the milestones: 2.4.8.0, 2.4.7.0 Jul 8, 2022
Lisias added a commit that referenced this issue Jul 8, 2022
…For simple and straighforward checks and fixes that can be defined on GameData and, so, be patcheable by MM.

For:
* #258
* #260
Lisias added a commit that referenced this issue Jul 9, 2022
…he Jobs from scratch for every part? #facePalm

For:
* #258
* #260
Lisias added a commit that referenced this issue Jul 9, 2022
Lisias added a commit that referenced this issue Jul 10, 2022
… a dedicated class; saving some cycles by supressing Checks/Fixes when none is available on GameData for their Priority.

For:
* #258
* #260
@Lisias
Copy link
Author

Lisias commented Jul 10, 2022

Implemented on commits:

Tested. It works. :)

…
[LOG 00:23:42.709] [TweakScale.Sanitizer] INFO: ShowStoppers is checking KAXheavyGear (GT-580 Heavy Gear Assembly)...
[LOG 00:23:42.709] [TweakScale.Sanitizer] ERROR: **FATAL** Part KAXheavyGear (GT-580 Heavy Gear Assembly) has a fatal problem due having duplicated properties - see issue [#34]( https://github.com/net-lisias-ksp/TweakScale/issues/34 ). at error:0
[LOG 00:23:42.709] [TweakScale.Sanitizer] TRACE: KAXheavyGear was checked and it should stop the chain.
[LOG 00:23:42.709] [TweakScale.Sanitizer] INFO: CriticalFixes is checking KAXjumpJet (Jump Jet Engine)...
[LOG 00:23:42.709] [TweakScale.Sanitizer] DETAIL: KAXjumpJet (Jump Jet Engine) passed the sanity check Firespitter-Buoyancy
[LOG 00:23:42.709] [TweakScale.Sanitizer] DETAIL: KAXjumpJet (Jump Jet Engine) passed the sanity check B9PartSwitch-Conflicts
[LOG 00:23:42.709] [TweakScale.Sanitizer] ASSERT: Part KAXjumpJet (Jump Jet Engine) didn't passed the sanity check due . at error:0
[LOG 00:23:42.709] [TweakScale.Sanitizer] TRACE: KAXjumpJet was checked and it should not stop the chain.
[LOG 00:23:42.709] [TweakScale.Sanitizer] INFO: HotFixes is checking KAXjumpJet (Jump Jet Engine)...
[LOG 00:23:42.710] [TweakScale.Sanitizer] TRACE: KAXjumpJet was checked and it should not stop the chain.
[LOG 00:23:42.710] [TweakScale.Sanitizer] INFO: Overrules is checking KAXjumpJet (Jump Jet Engine)...
[LOG 00:23:42.710] [TweakScale.Sanitizer] TRACE: KAXjumpJet was checked and it should not stop the chain.
[LOG 00:23:42.710] [TweakScale.Sanitizer] INFO: ShowStoppers is checking KAXjumpJet (Jump Jet Engine)...
[LOG 00:23:42.710] [TweakScale.Sanitizer] ERROR: **FATAL** Part KAXjumpJet (Jump Jet Engine) has a fatal problem due having duplicated properties - see issue [#34]( https://github.com/net-lisias-ksp/TweakScale/issues/34 ). at error:0
...
[LOG 00:23:43.073] [TweakScale] INFO: WriteDryCost Concluded : 757 parts found; 0 DryCost failed; 0 parts with hotfixes; 16 Show Stoppers found; 0 parts with issues overruled; 0 critical fixes applied; 0 parts failed being checked; 236 unscalable parts.

screenshot64

@Lisias Lisias closed this as completed Jul 10, 2022
@Lisias Lisias reopened this Jul 10, 2022
@Lisias
Copy link
Author

Lisias commented Jul 10, 2022

Closed it prematurely.

Lisias added a commit that referenced this issue Jul 10, 2022
@Lisias
Copy link
Author

Lisias commented Jul 10, 2022

Implemented by commit f9f7a84 .

NOW I can close this. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant