Skip to content

Conversation

@MiYanni
Copy link
Contributor

@MiYanni MiYanni commented Feb 8, 2018

Description

This is for #3430. It is an initial sweep of the projects to clean up dependencies. It removed several unused references to WindowsAzure.Storage and also allowed RedisCache to no longer require WindowsAzure.Storage (by updating a reference). The RedisCache team should review their project's changes to make sure they are good.

I did a fairly thorough check for each project to make sure that the .csproj references, the package.config, and the .psd1 aligned properly, and made sense keeping Common.Dependencies.targets in mind for the references. But, I definitely could have missed something, so a thorough review is required.


This checklist is used to make sure that common guidelines for a pull request are followed. You can find a more complete discussion of PowerShell cmdlet best practices here.

General Guidelines

  • Title of the pull request is clear and informative.
  • There are a small number of commits, each of which have an informative message. This means that previously merged commits do not appear in the history of the PR. For more information on cleaning up the commits in your PR, see this page.
  • The pull request does not introduce breaking changes (unless a major version change occurs in the assembly and module).

Testing Guidelines

  • Pull request includes test coverage for the included changes.
  • PowerShell scripts used in tests should do any necessary setup as part of the test or suite setup, and should not use hard-coded values for locations or existing resources.

Cmdlet Signature Guidelines

  • New cmdlets that make changes or have side effects should implement ShouldProcess and have SupportShouldProcess=true specified in the cmdlet attribute. You can find more information on ShouldProcess here.
  • Cmdlet specifies OutputType attribute if any output is produced - if the cmdlet produces no output, it should implement a PassThru parameter.

Cmdlet Parameter Guidelines

  • Parameter types should not expose types from the management library - complex parameter types should be defined in the module.
  • Complex parameter types are discouraged - a parameter type should be simple types as often as possible. If complex types are used, they should be shallow and easily creatable from a constructor or another cmdlet.
  • Cmdlet parameter sets should be mutually exclusive - each parameter set must have at least one mandatory parameter not in other parameter sets.

@MiYanni
Copy link
Contributor Author

MiYanni commented Feb 8, 2018

@azuresdkci Retest this please

@cormacpayne cormacpayne assigned cormacpayne and unassigned MiYanni Feb 12, 2018
Copy link
Member

@cormacpayne cormacpayne left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MiYanni some comments to take a look at

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MiYanni it looks like the wxi was regenerated before the CleanupBuild.ps1 script was run and removed all of the extra assemblies

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@cormacpayne Are you referring to the last bullet in the guide? I didn't look at the changes to the Wxi file, because I wouldn't know what I'm looking for to be valid/invalid. I don't know Wxi files (not really something I'd assume most people are familiar with). It would probably make sense to require a clean repo prior to running the process instead of making a conditional check.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MiYanni it looks like there is still a reference to this package in the Commands.ApiManagement.ServiceManagement/packages.config file that should be removed

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good find.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MiYanni should this be removed since it was removed in the .csproj file?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@cormacpayne If the csproj doesn't need it, why would the package.config need it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MiYanni it looks like this wasn't removed in the corresponding packages.config file

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice one.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MiYanni it looks like this wasn't removed in the corresponding packages.config file

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MiYanni I don't think we need to add these references to Microsoft.Data.* and System.Spatial as they will get pulled in with WindowsAzure.Storage

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The assumption is incorrect. If it is not present in the packages.config, NuGet will not pull those packages. Dependent NuGet packages are not automatically pulled in. Instead, they simply state what other packages are required to be part of the packages.config file.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MiYanni I don't think we need to add these references to Microsoft.Data.* and System.Spatial as they will get pulled in with WindowsAzure.Storage

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The assumption is incorrect. If it is not present in the packages.config, NuGet will not pull those packages. Dependent NuGet packages are not automatically pulled in. Instead, they simply state what other packages are required to be part of the packages.config file.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MiYanni I don't think we need to add these references to Microsoft.Data.* and System.Spatial as they will get pulled in with WindowsAzure.Storage

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The assumption is incorrect. If it is not present in the packages.config, NuGet will not pull those packages. Dependent NuGet packages are not automatically pulled in. Instead, they simply state what other packages are required to be part of the packages.config file.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MiYanni I don't think we need to add these references to Microsoft.Data.* and System.Spatial as they will get pulled in with WindowsAzure.Storage

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The assumption is incorrect. If it is not present in the packages.config, NuGet will not pull those packages. Dependent NuGet packages are not automatically pulled in. Instead, they simply state what other packages are required to be part of the packages.config file.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MiYanni can we remove this?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The .csproj doesn't reference Moq directly. So, it should be fine to remove it from the packages.config.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

@maddieclayton
Copy link
Contributor

@MiYanni Looks like some merge conflicts have come up - can you resolve?

@MiYanni
Copy link
Contributor Author

MiYanni commented Feb 15, 2018

@cormacpayne Finally got the solutions/projects working again after additional changes based on your comments (and other findings). Squashed commits. Please re-review.

@maddieclayton
Copy link
Contributor

@MiYanni Can you fix the merge conflicts?

@MiYanni
Copy link
Contributor Author

MiYanni commented Feb 15, 2018

@azuresdkci Retest this please

@MiYanni
Copy link
Contributor Author

MiYanni commented Feb 15, 2018

@markcowl
Copy link
Member

markcowl commented Mar 1, 2018

@MiYanni Looks like a merge issue. Can you take a look?

@maddieclayton
Copy link
Contributor

# Conflicts:
#	src/ResourceManager/Compute/Commands.Compute/packages.config
@MiYanni
Copy link
Contributor Author

MiYanni commented Mar 2, 2018

# Conflicts:
#	src/ResourceManager/Storage/Commands.Management.Storage/packages.config
@MiYanni
Copy link
Contributor Author

MiYanni commented Mar 6, 2018

@azuresdkci Retest this please

2 similar comments
@MiYanni
Copy link
Contributor Author

MiYanni commented Mar 6, 2018

@azuresdkci Retest this please

@MiYanni
Copy link
Contributor Author

MiYanni commented Mar 7, 2018

@azuresdkci Retest this please

@markcowl
Copy link
Member

markcowl commented Mar 8, 2018

@maddieclayton
Copy link
Contributor

@maddieclayton maddieclayton merged commit 11e3477 into Azure:preview Mar 8, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants