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

Upgrade to NuGet.* v4.0.0 dependencies #3643

Merged
merged 3 commits into from
Mar 13, 2017
Merged

Conversation

xavierdecoster
Copy link
Member

This PR

  • upgrades our NuGet.* dependencies to version 4.0.0
  • consolidates Moq and Newtonsoft.Json dependencies to vLatest
  • leverages the now public field NuGet.Packaging.PackageIdValidator.MaxPackageIdLength instead of copy/paste + #sadpanda comment in the gallery code base

This PR will also facilitate other validation improvements that are required for semver2 work (and didn't want to pollute those PRs with this upgrade).

@skofman1
Copy link
Contributor

I have a PR changing gallery to .NET 4.6.2.. the merge conflicts I'm going to get break my ❤️

@@ -46,7 +43,7 @@ private static IEnumerable<ValidationResult> ValidateCore(PackageMetadata packag
}
else
{
if (packageMetadata.Id.Length > MaxPackageIdLength)
if (packageMetadata.Id.Length > NuGet.Packaging.PackageIdValidator.MaxPackageIdLength)
Copy link
Contributor

Choose a reason for hiding this comment

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

One thing to note--(last time I checked) the gallery accepts nupkgs with up to a 128 characters in the id. Probably good to switch this to use this here but I question why we have this validating against 100 characters when the gallery accepts 128.

Copy link
Member Author

Choose a reason for hiding this comment

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

@scottbommarito any pointers to where in the code base we accept 128 chars? I did not change the value in this PR, so perhaps we should log a separate issue to track that one.

Copy link
Contributor

Choose a reason for hiding this comment

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

public const int MaxPackageIdLength = 128;

I don't know if you need to change this, but using the constant was part of #3305 which was reverted.

Copy link
Member Author

Choose a reason for hiding this comment

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

Interesting. I think we should definitely look into that some day. If I understand correctly, the gallery db is more forgiving than the server and client validation (the other way around would 've been worse though). Will leave it in as part of this PR, as I believe the server should leverage and align with the client validation.

Copy link
Member Author

Choose a reason for hiding this comment

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

Tracked in issue #3647

<section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
</configSections>
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 --></configSections>
Copy link
Contributor

Choose a reason for hiding this comment

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

Did this comment get moved automatically?

Huge nit but I prefer where it was before.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, nuget did this 🙌

Copy link
Member Author

Choose a reason for hiding this comment

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

Reverted this auto-change in 4b62421

@xavierdecoster xavierdecoster merged commit 881769b into dev Mar 13, 2017
@xavierdecoster xavierdecoster deleted the dev-pkgid-validation branch March 13, 2017 19:28
@shishirx34 shishirx34 mentioned this pull request Mar 20, 2017
15 tasks
jozefizso added a commit to goit/NuGetGallery that referenced this pull request Apr 20, 2017
…7.03.27

* tag 'v2017.03.27': (205 commits)
  Revert UpdateIsLatest optimistic concurrency changes (NuGet#3707)
  UpdateIsLatest concurrent unlist fix (NuGet#3695)
  Change telemetry time to use correct format (NuGet#3690)
  Fix typo of "publically" (NuGet#3636)
  Fix regression (NuGet#3667)
  Add credential to Register and RequestPasswordReset audits (NuGet#3666)
  Functional test for temp keys (NuGet#3664)
  Telemetry for temp keys (NuGet#3662)
  Temp keys implementation (NuGet#3563) (NuGet#3646)
  Extracting code: single type per file (NuGet#3644)
  Telemetry for package push (NuGet#3649)
  Upgrade to NuGet.* v4.0.0 dependencies (NuGet#3643)
  Fix concurrent push test by disabling search hijacking on feed (NuGet#3641)
  Fixing Package Description truncation (NuGet#3638)
  Fix Microsoft Account removal (NuGet#3639)
  Send e-mail when a new API key is created (NuGet#3634)
  IsLatest Fix: wrong connection string passed to retry context (NuGet#3632)
  Update WindowsAzure.Storage to 7.0.0 (NuGet#3633)
  Depend on signed version of Elmah (NuGet#3609)
  Move AzureEntityList and TableErrorLog to NuGetGallery.Core (NuGet#3607)
  ...
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.

4 participants