eddiebeazer / ue5-linter

MIT License
27 stars 10 forks source link

Errors when compiling project with Linter #7

Closed KristianKolev closed 9 months ago

KristianKolev commented 9 months ago

Hey I tried following the steps and compiling my project with the Linter files you provided. I tried both 5.1 and 5.2 but I am getting these errors:

1>[8/13] Compile [x64] Module.Linter.cpp 1>\Plugins\Linter\Source\Linter\Private\BatchRenameTool\BatchRenameTool.cpp(77): warning C4996: 'FAssetData::AssetClass': Class names are now represented by path names. Please use AssetClassPath. Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Engine\Source\Runtime\AssetRegistry\Public\AssetRegistryModule.h(6): warning : #include AssetRegistry/AssetRegistryModule.h instead of AssetRegistryModule.h 1>\Engine\Source\Runtime\AssetRegistry\Public\IAssetRegistry.h(6): warning : #include AssetRegistry/IAssetRegistry.h instead of IAssetRegistry.h 1>\Engine\Source\Runtime\AssetRegistry\Public\AssetData.h(6): warning : #include AssetRegistry/AssetData.h instead of AssetData.h 1>\Plugins\Linter\Source\Linter\Private\Linter.cpp(124): warning C4996: 'IAssetRegistry::GetAssetsByClass': Class names are now represented by path names. Please use a version of this function that uses FTopLevelAssetPath. Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Plugins\Linter\Source\Linter\Private\LinterCommandlet.cpp(133): warning C4996: 'FAssetData::ObjectPath': FName asset paths have been deprecated. Use GetSoftObjectPath to get the path this asset will use in memory when loaded or GetObjectPathString() if you were just doing ObjectPath.ToString() Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Plugins\Linter\Source\Linter\Private\LinterCommandlet.cpp(61): warning C4996: 'IAssetRegistry::GetAssetsByClass': Class names are now represented by path names. Please use a version of this function that uses FTopLevelAssetPath. Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>Plugins\Linter\Source\Linter\Private\LinterContentBrowserExtensions.cpp(89): warning C4996: 'FAssetData::AssetClass': Class names are now represented by path names. Please use AssetClassPath. Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Plugins\Linter\Source\Linter\Private\LinterContentBrowserExtensions.cpp(126): warning C4996: 'FAssetData::AssetClass': Class names are now represented by path names. Please use AssetClassPath. Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Plugins\Linter\Source\Linter\Private\LintRule.cpp(243): warning C4996: 'IAssetRegistry::GetAssetByObjectPath': Asset path FNames have been deprecated, use Soft Object Path instead. Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Plugins\Linter\Source\Linter\Private\LintRuleSet.cpp(82): warning C4996: 'FAssetData::ObjectPath': FName asset paths have been deprecated. Use GetSoftObjectPath to get the path this asset will use in memory when loaded or GetObjectPathString() if you were just doing ObjectPath.ToString() Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Plugins\Linter\Source\Linter\Private\UI\LintReport.cpp(285): warning C4996: 'FAssetData::ObjectPath': FName asset paths have been deprecated. Use GetSoftObjectPath to get the path this asset will use in memory when loaded or GetObjectPathString() if you were just doing ObjectPath.ToString() Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Plugins\Linter\Source\Linter\Private\UI\LintReportRuleDetails.cpp(63): warning C4996: 'IAssetRegistry::GetAssetByObjectPath': Asset path FNames have been deprecated, use Soft Object Path instead. Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>Plugins\Linter\Source\Linter\Private\UI\LintReportRuleError.cpp(42): warning C4996: 'FAssetData::ObjectPath': FName asset paths have been deprecated. Use GetSoftObjectPath to get the path this asset will use in memory when loaded or GetObjectPathString() if you were just doing ObjectPath.ToString() Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Plugins\Linter\Source\Linter\Private\UI\LintWizard.cpp(33): warning C4005: 'LOCTEXT_NAMESPACE': macro redefinition 1>\Plugins\Linter\Source\Linter\Private\UI\LintReportAssetError.cpp(14): note: see previous definition of 'LOCTEXT_NAMESPACE' 1>\Plugins\Linter\Source\Linter\Private\UI\LintWizard.cpp(273): warning C4996: 'FARFilter::ClassNames': Class names are now represented by path names. Please use ClassPaths. Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Plugins\Linter\Source\Linter\Private\UI\LintWizard.cpp(284): warning C4996: 'FAssetData::ObjectPath': FName asset paths have been deprecated. Use GetSoftObjectPath to get the path this asset will use in memory when loaded or GetObjectPathString() if you were just doing ObjectPath.ToString() Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Plugins\Linter\Source\Linter\Private\UI\LintWizard.cpp(52): warning C4996: 'IAssetRegistry::GetAssetsByClass': Class names are now represented by path names. Please use a version of this function that uses FTopLevelAssetPath. Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile. 1>\Plugins\Linter\Source\Linter\Private\UI\SAssetLinkWidget.cpp(29): warning C4996: 'FAssetData::ObjectPath': FName asset paths have been deprecated. Use GetSoftObjectPath to get the path this asset will use in memory when loaded or GetObjectPathString() if you were just doing ObjectPath.ToString() Please update your code to the new API before upgrading to the next release, otherwise your project will no longer compile.

Is it something on my end/version or do these files need to be updated?

eddiebeazer commented 9 months ago

How did you download it? I added new instructions yesterday in the readme. Can you give those a shot and see if they work for you?

KristianKolev commented 9 months ago

I actually tried it on the day you uploaded the new instructions. A few hours after you'd uploaded the new .zip files.

So I tried the following again today.

  1. Created a new empty blueprint project in 5.2.
  2. Created a new C++ class file inside the UE editor.
  3. Created a /Plugins folder inside my new project directory
  4. Downloaded the new Linter.5.2.zip from here
  5. Extracted contents of .zip into the /plugins folder for the project (Linter folder is there)
  6. Right click on my Project.uproject and clicked Generate Visual Studio project files
  7. Started Project
  8. I get a prompt window "The following modules are missing or built with a different engine version" Linter GamemakinLinter MarketplaceLinter Would you like to rebuild them now?
  9. If I click No, it doesn't open the project, so I click Yes.
  10. It rebuilds and project opens with an error message "The summary for the package '/Linter/MarketplaceLinter/MarketplaceLintRuleSet' is invalid. Check that the file is of the expected type and not corrupted."
  11. I can use Linter's batch rename functionality for example, but if I try to scan a folder the editor crashes.
  12. When I open the .sln file and rebuild solution the from there I get the same error log as I posted above.
eddiebeazer commented 9 months ago

You have the same issue as #6. Can you go to this link and follow the instructions, it should fix it for you.

https://github.com/eddiebeazer/ue5-linter/issues/6#issuecomment-1734326404. Please let me know if that works, not sure how it got all screwy. For 5.4 I'll most likely try to rebuild those packages in LFS

KristianKolev commented 9 months ago

Hey I just got around to doing it today. I replaced my plugins/linter/content folder with the one you've provided and everything seems to be working fine. Thanks :)