Release notes

v4.5.2 Release (2014-04-06)

New Functionality

  • Improved analysis in client application: Choose ruleset in quick analysis, ability to select custom ruleset and start rule set editor
  • Improved result view in client application: Ability to copy/paste error messages
  • Save all reports: Added function to save all generated reports in client application to a given folder
  • New separate tools SPCop, SPDepend, SPMetrics and SPInventory
  • New report type DOCX (Microsoft Word)
  • Added new output arguments to TFS build activity (e.g. number of critical errors, errors etc.) to react on occured issues during build workflow
  • Added new rule: SPC060113 DoNotDeployMSIFiles
  • Added new rule: SPC050237 DoNotUseFieldCollectionByIndex
  • Added new rule: SPC050238 DoNotUseSPWebGetListFromUrl
  • Added new rule: SPC062103 DoNotDeployFeatureMultipleTimes
  • Added new rule: SPC062104 DoNotDeployFeatureWithSameIDMultipleTimes
  • Added new rule: SPC016102 DeployMissingControlAssembly
  • Added new rule: SPC016103 DeployMissingControlTemplate
  • Updated list of SharePoint assemblies in check for deprecated types, members and interfaces

Fixes

  • Dependency SPD015403 fixed issue with NullPointerException
  • Rule SPC030202 DoNotUseReflectionToAccessSharePointAPI fixed issue with NullPointerException
  • Function "Show Error help" in Visual Studio works for custom rules
  • Dependency SPD015301 ModuleReferencedElementFiles, fixed issue when ElementFiles are deployed as TemplateFiles
  • Rule SPC060402 DeployOnlyImageToImagesFolder, Added BMP as allowed image file
  • Dependency SPD016102 ControlReferencesControlTemplate, fixed issue with missing '~' for ControlSrc
  • Fixed CheckIds for SPInventory to match the CheckId conventions
  • Rule SPC030101 DoNotOverrideSystemFiles. fixed to securely detect overwritten system files
  • Dependency SPD016102 ControlReferencesControlTemplate, fixed issue with ControlTemplates path
  • Rule SPC050233 UseRowLimitInQueries, ignores now created SPQuery with SPView as argument
  • WPF client crashed on RDP sessions when session window is closed and opened again
  • Integration of CAT.NET failed in certain situations: results did not show up in the reports
  • Rule SPC010221 DoNotCallDeprecatedMethods: improved check depending on method parameters

Changes

  • Removed JSHint analysis from rule set "Extended Recommended" due to performance issues. Use rule set "All Rules" to enable JSHint.
  • Client application: Reports are not displayed inline within the client app. Reports are opened directly in the browser or local application.
  • Changed sorting of violations in report (previously first criteria was severity, now it is the category to have same sorting in all reports).
  • Better exception handling: If an exception occurs during report generation the analysis is not stopped. Instead the analysis finishes and the failed report is excluded.
  • The max. number of elements listed in the inventory is now limited to 1000. Otherwise reports size may increase drastically and the reports cannot be handled anymore.
  • Removed rule SPC042105: Declare attribute 'SolutionId' in Feature (automatically set by SharePoint)
  • Removed rule SPC045202: Declare attribute 'FeatureId' in ContentTypes (automatically set by SharePoint)

v4.3.5 Release (2013-11-30)

Changes

  • Analysis runs now multi-threaded
  • Reduced memory consumption during analysis
  • Disabled FxCopMetrics by default in rulesets due to exception in FxCop metrics (missing assemblies)
  • Optimized speed with WPF application
  • Setup now provides retry function if Visual Studio is running
  • Send report form in client application contains text box for email address of the user (optional)
  • Replaced StructureMap with custom solution to load SPCAF assemblies

Fixes

  • Error during load of project file with hexadecimal characters
  • SPC050224 DoNotUseListItemsByIndex false positives and changed implementation of the rule
  • SPC010104 RemoveUnusedFilesFromPackage now also checks Assembly.ClassResources
  • SPC015701 DeclareRequiredAttributesInCustomAction Title is not required if Location is 'ScriptLink'
  • SPC026901 DoNotUseInlineCodeInASPXPage excluded files in _layouts folder from rule
  • SPC015702 DefineUniqueIDInCustomAction fixed error message to show correct name of feature

v4.1.1 Release (2013-10-20)

Fixes

  • SPC015404 DeployMissingListTemplateForListInstance failed for FeatureId with brackets
  • SPC046401 DeclareTitleAndDescriptionInWebPart failed for webparts without properties
  • SPC015108 DeclareAllRecommendedAttributesInFields will ignore Fields in ListDefinitions
  • SPCAF.Sdk.Model.FieldDefinition returned source code of parent Feature instead of ElementManifest
  • SPCAF.Sdk.Model.ModuleDefinition returned source code of parent Feature instead of ElementManifest
  • SPC015212 DefineInheritsToFalseInContentTypeWithForms detected false positive for imported ContentTypes with SharePoint forms
  • Evaluation of attribute SharePointVersion of rules failed
  • Disabled generation of serializion assembly in Visual Studio package during analysis build

Changes

  • CheckId of rule SPC106101 DoNotDeployControl (was SPC106701)
  • Path to license file changed to user AppData folder (instead of Program Files)
  • Updated severity of several rules, updated definition of severities CriticalError and Error

v4.1.0 Release (2013-10-04)

New Functionality

  • Syntax highlighting for source code in rule reports
  • New argument for command line tools: Verbosity to reduce content in output window and in build logs
  • New argument for command line tools: LogFile to provide a path to a log file
  • Added ability to exclude files from analysis (like 'jqery.js,Telerik*.dll'): configuration parameter 'IgnoredFiles' contains the list of excluded files
  • Name of created project file is configurable (via output argument)
  • Improved logging capabilities in custom rules

New Rules

  • Category Correctness
    • SPC010703: DoNotAddDependencyToWebAppFeatureInSiteDefinition
    • SPC017601: DeployMissingAssemblyInWCFWebService
    • SPC010212: DoNotCallSPSiteCatchAccessDeniedException
    • SPC010213: DoNotCallSPSiteReadLocked
    • SPC010223: DoNotImplementDeprecatedInterfaces
    • SPC010224: DoNotInheritFromDeprecatedTypes
    • SPC010225: DoNotUseDeprecatedTypes
  • Best Practices
    • SPC050250: AssignSPQueryRowLimitInLimitedRange
  • Deployment
    • SPC062111: DoNotDeployEmptyElementManifests
    • SPC060111: DoNotDeployBatchFiles
    • SPC060112: DoNotDeployPowerShellScripts

New Depedency Checks

  • SPD010705: SiteTemplateConfigurationReferencesVisibilityFeatureDependency
  • SPD037601: WCFWebServiceReferencesAssembly

Fixes

  • Improved error message and guidance to make it easier to solve issues
  • Fixed issues with message Unhandled exception: System.Exception: Exception ReFormatXmlDocument
  • Fixed AddTranslationForResourceKey not working for feature with DefaultResourceFile
  • Fixed DeployMissingImageOfListTemplate with schema.xml deployed as Resource file and not Elementfile
  • Fixed issues with calling SPCAF.exe via DOS path: providing error message in this case
  • Fixed issues when unloadable assemblies crashed SPCAF

v4.0.7 BETA (2013-09-04)

New Functionality

  • Custom rules created with older versions of SPCAF can now be loaded by newer SPCAF versions (no recompile needed)
  • Ability to save configuration properties in ruleset files (previous Dictonary.xml not required anymore)
  • Ability to add comments in the ruleset files (which will be added to the reports)
  • New Parameter "Help" in the custom rule metadata can be used to override the URL for help
  • Added analysis of ListDefinitions
  • Integration of CSSLint for analysis of CSS files
  • Integration of JSHint for analysis of JavaScript files
  • Reduced minimum .NET Framework version to 4.0
  • Support for Visual Studio 2013 Preview
  • Renamed default FxCop ruleset from SPCAF.ruleset to MSOCAF.ruleset
  • Aligned MSOCAF.ruleset with current MSOCAF rules
  • Inventory: Added ContentType Group to ContentType inventory
  • Client Application: New function to send error reports to SPCAF support

New Rules

  • Category Correctness
    • SPC015404: DeployMissingListTemplateForListInstance
    • SPC015405: RemoveCurlyBracketsFromFeatureIdInListInstance
    • SPC015406: DeployMissingCustomSchemaForListInstance
    • SPC015705: DeployMissingRibbonImageOfCustomAction
    • SPC015706: DeployMissingRibbonCommandUIHandlerOfCustomAction
    • SPC015212: DefineInheritsToFalseInContentTypeWithForms
    • SPC016503: DefineFieldRefInCorrectCasing
  • Category Design
    • SPC046902: AvoidInlineJavaScriptInASPXPage
    • SPC046903: AvoidInlineCSSInASPXPage
  • Category Best Practice
    • SPC052101: DoNotActivateFeaturesViaAPI
    • SPC050223: DoNotCallSPItemEventPropertiesOpenWeb
  • Category Deployment
    • SPC067601: DoNotDeployWCFWebServiceToLAYOUTS
    • SPC067602: DoNotDeployWCFAdministrationWebServiceToADMIN
  • Category Memory Disposal
    • SPC110201: Dispose created SPSite objects
    • SPC110203: Dispose SPWeb objects created with SPSite.OpenWeb
    • SPC110204: Dispose SPSite objects created with SPSite.SelfServiceCreateSite
    • SPC110205: Dispose SPWeb created by SPLimitedWebPartManager
    • SPC110211: Dispose SPSite created by SPSiteCollection.Add
    • SPC110212: Dispose SPSite created by SPSiteCollection[] index operator
    • SPC110213: Dispose SPWeb created by SPWebCollection.Add
    • SPC110214: Dispose SPWeb created by SPWebCollection[] index operator
    • SPC110231: Do not dispose SPListEventProperties.Web
    • SPC110232: Do not dispose SPWebEventProperties.Web
    • SPC110233: Do not dispose SPItemEventProperties.Web
    • SPC110234: Do not dispose SPItemEventProperties.ListItem.Web
    • SPC110235: Do not dispose SPItemEventProperties.Web.Site
    • SPC110236: Do not dispose SPItemEventProperties.ListItem.Web.Site
    • SPC110237: Do not dispose SPFeatureReceiverProperties.Feature.Parent
    • SPC110241: Do not dispose SPSite.RootWeb
    • SPC110242: Do not dispose SPWeb.ParentWeb
    • SPC110243: Do not dispose SPList.ParentWeb
    • SPC110244: Do not dispose SPSite returned by SPControl.GetContextSite
    • SPC110245: Do not dispose SPWeb returned by SPControl.GetContextWeb
    • SPC110246: Do not dispose SPSite returned by SPContext.Current.Site
    • SPC110247: Do not dispose SPWeb returned by SPContext.Current.Web
    • SPC110261: Close PublishingWeb created by PublishingWeb.GetPublishingWebs[] index operator
    • SPC110262: Close PublishingWeb created by PublishingWeb.GetVariation
    • SPC110263: Close PublishingWeb created by PublishingWebCollection.Add
    • SPC110281: Dispose SPSite created with UserProfiles.PersonalSite

New Depedency Checks

  • SPD015302: ModuleReferencedTemplateFiles
  • SPD027504: ListDefinitionContentTypeReferencesContentType

New ThirdParty Analyzer Rules

  • JSHint
    • JSH318901: Remove debugger statements
    • JSH318902: Do not use bitwise operators
    • JSH318903: Use correct comparison
    • JSH318904: Use camelCase in variables
    • JSH318905: Use curly braces around blocks
    • JSH318906: Use correct === and !==
    • JSH318907: Use correct null comparisons
    • JSH318908: Do not use eval
    • JSH318909: Do not use a single expression
    • JSH318910: Use filter in for in loops
    • JSH318911: Use parens for immediate function invocations
    • JSH318912: Use correct indent
    • JSH318913: Define variable before it is used
    • JSH318914: Use correct line breakings
    • JSH318915: Use correct line breakings around commas
    • JSH318916: Do not make functions within a loop
    • JSH318917: Avoid multi line strings
    • JSH318918: Do not use empty blocks
    • JSH318920: Do not use 'new' for side effects
    • JSH318921: Use consistent of quotation marks
    • JSH318922: Do not use single case switch
    • JSH318923: Use regular expressions correctly
    • JSH318924: Avoid . in regexp literals
    • JSH318925: Declare variable before it is used
    • JSH318926: Avoid JavaScript URLs
    • JSH318927: Remove unused variables
    • JSH318928: Avoid redeclaring a variable
    • JSH318929: Avoid correct construction of objects and function
    • JSH318930: Avoid this in non-constructor functions
    • JSH318931: Do not use arguments.caller and arguments.callee
    • JSH318941: Use semicolon correctly
    • JSH318942: Define uppercase constructors
    • JSH318943: Do not use unary increment and decrement operators
    • JSH318944: Use semicolon in last statement
    • JSH318945: Use dot notation instead of []
    • JSH318946: Avoid trailing whitespaces
    • JSH318961: Do not exceed max number of formal parameters per function
    • JSH318962: Do not exceed max number of nested blocks in a function
    • JSH318963: Do not exceed max number of statements per function
    • JSH318964: Do not exceed max allowed cyclomatic complexity
    • JSH318965: Do not exceed max length of a line in code
  • CSSHint
    • CSL308801: Avoid unwanted box model sizing issues in CSS
    • CSL308802: Avoid properties that don't work based with the display property being used in CSS
    • CSL308803: Avoid duplicate properties in CSS
    • CSL308804: Avoid un anchored hovers in CSS
    • CSL308805: Avoid empty rules in CSS
    • CSL308806: Use only known properties in CSS
    • CSL308807: Avoid adjoining classes in CSS
    • CSL308808: Avoid property box-sizing in CSS
    • CSL308809: Use compatible vendor prefixes in CSS
    • CSL308810: Use all gradient definitions in CSS
    • CSL308811: Avoid negative text indent in CSS
    • CSL308812: Use standard property with vendor prefix in CSS
    • CSL308813: Use fallback colors in CSS
    • CSL308814: Avoid star hack in CSS
    • CSL308815: Avoid underscore hack in CSS
    • CSL308816: Use bulletproof font face in CSS
    • CSL308817: Do not use too many web fonts in CSS
    • CSL308818: Do not use @import in CSS
    • CSL308819: Avoid selectors that look like regular expressions in CSS
    • CSL308820: Do not use universal selector in CSS
    • CSL308821: Do not use unqualified attribute selectors in CSS
    • CSL308822: Do not use units for zero values in CSS
    • CSL308823: Avoid overqualified elements in CSS
    • CSL308824: Use shorthand properties in CSS
    • CSL308825: Do not use duplicate background images in CSS
    • CSL308826: Avoid too many floats in CSS
    • CSL308827: Do not use too many font size declarations in CSS
    • CSL308828: Do not use IDs in selectors in CSS
    • CSL308829: Do not use !important in CSS
    • CSL308830: Do not use outline:none in CSS
    • CSL308831: Do not use qualified headings in CSS
    • CSL308832: Define headings only once in CSS

Fixes

  • Custom Rules without Metadata will not crash SPCAF
  • Fix in rule SPC030203 Do not read ConnectionString from SPContentDatabase
  • Fixed: endless loop during loading of imported WebTemplate project
  • Fixed: SPCAF menu not enabled in Visual Studio when a project is unloaded

Changes

  • SPC016501: DeclareRequiredAttributesInFieldRef Remove DisplayName
  • SPC015105: DeclareAllRequiredAttributesInFields Removed check for attribute 'Required'
  • Help: Changed root URL for documentation to http://docs.spcaf.com/v4
  • Changed rule categories: Not loaded from SDK anymore

v4.0.6.1005 BETA (2013-05-10)

New Rules

  • Category Correctness
    • SPC010203: DeployReferencedAssemblyWithCorrectVersion
    • SPC015703: DeployMissingUrlActionFileOfCustomAction
  • Category Deployment
    • SPC060304: DoNotDeployRootFileMultipleTimes
    • SPC060404: DoNotDeployTemplateFileMultipleTimes
    • SPC062101: DeployMissingImageForFeature
    • SPC060303: DoNotDeployRootFileToTemplatesFolder

Fixes

  • Fix in SolutionDefinition: Handle schema errors in site definitions
  • Fix in Dependencies "FeatureReferencesImage" (SPD012112): Images not found if they contain slash
  • Fix in Dependencies "ASPXPageRegisterControlTemplate" (SPD036904): Controltemplates not referenced correctly

Changes

  • Change for Integration of third party analyzers like FxCop: Path to tools is now stored in Dictionary.xml (and not in app.config anymore). Reason: storing config values centrally for all components; app.config could not be read in Team Build Activity
  • Allow relative paths to third party analyzers (relative to SPCAF installation directory)
  • Disable FxCop and CAT.NET in all rulesets (due to large reports and negative impact on SPCAF performance). FxCop and CAT.NET need to be enabled manually in ruleset via RuleEditor.

v4.0.5.2504 BETA (2013-04-25)

New Functionality

  • Update notification for SPCAF new versions in Visual Studio (see Visual Studio Extension Manager)

Fixes

  • SPC015302 AddMissingModuleFileToFeature fixed issue that attribute 'Path' of Module was not included in search path
  • Fixed exception for missing webpart properties
  • SPC050225 DoNotUseListItemsCount fixed issue with wrongly detected violations

Changes

  • Setup: Check for required .NET Framework 4.5
  • General: Reduced strictness of default severity for several rules (e.g. we use CriticalError only for violations which are highly critical for SharePoint and may damage the farm)
  • SPC010102 DeclareSafeControlEntryForWebControls limited to non abstract types
  • Remove rules SPC050221 DoNotCallListItemsAddToAddItems (rule no present in MSDN anymore)

New Rules

  • Category Correctness
    • SPC015506 DefineUniqueListTemplateType (Category Correctness)
    • SPC017401 DeclareRequiredAttributesInFeatureActivationDependency
    • SPC017402 DefineOptionalAttributesInFeatureActivationDependencyCorrectly
    • SPC017411 DoNotAddActivationDependencyToHiddenFeature
    • SPC017412 DoNotAddActivationDependencyToMoreRestrictiveScope
    • SPC017413 DoNotAddCrossScopeActivationDependencyToHiddenFeature
    • SPC017414 DoNotChainActivationDependencies
    • SPC017415 DoNotCreateCircularChaingOfActivationDependencies
    • SPC012121 AddMissingAssemblyForFeatureReceiverAssembly
    • SPC012122 DeployFeatureReceiverAssemblyToGAC
  • Category Design
    • SPC042107 DefineFeatureReceiverAssemblyAsFQN
  • Category Deployment
    • SPC060401 DoNotDeployImagesToLayouts
    • SPC060402 DeployOnlyImageToImagesFolder
    • SPC060403 DeployBinaryFilesToClientBin
  • Category Best Practices
    • SPC050230 DoNotUseSPFolderItemsCount
  • Category SharePoint 2013 Compatibility
    • SPC150102 DeclareSharePointVersionInSolution
    • SPC150207 BuildAssemblyForFramework45
    • SPC150208 ReplaceReferencesToOlderHivesInCode
    • SPC159901 Reference15HiveInPages
    • SPC159902 Reference15HiveInMasterPages
    • SPC159903 Reference15HiveInScripts
    • SPC159904 Reference15HiveInStyles
    • SPC159905 Reference15HiveInControls
    • SPC159906 Reference15HiveInXSLT
    • SPC155701 Reference15HiveInURLsInCustomAction
    • SPC155702 Reference15HiveInURLActionInCustomAction
    • SPC155703 Reference15HiveInScriptSrcInCustomAction
    • SPC156101 Reference15HiveInControlSrcInControl
    • SPC155501 Reference15HiveInImageInListTemplate

v4.0.4.1804 BETA (2013-04-17)

New

  • Client App: New function 'Check for Updates' which notifies the user if updates are available
  • Metrics: New Metric for BDCModel und ClientWebPart
  • Help: Added functionality for comments to online documentation
  • Rules: New rules DeclareFileElementInModule (Checkid: SPC015303)

Changes

  • Help: Changed root URL for documentation to http://docs.spcaf.com/spcaf
  • Rules: Changed severity for rule DeclareSafeControlEntryForWebControls from Error to CriticalWarning

Fixes

  • Rules: Changed CheckId for Rule MasterPageShouldReferenceSharePointVersion15 to SPC157303
  • Setup: Added registration as addin for VS 2010 to setup
  • Analysis Engine: Fixed problem with long paths (PathTooLongException during project save)
  • Analysis Engine: Fixed problem with special characters in method names of assemblies (e.g. obfuscated assemblies)

v4.0.3.1546 BETA (2013-04-11)

  • First public beta release.
comments powered by Disqus