File tree Expand file tree Collapse file tree
src/NuGetGallery/Controllers Expand file tree Collapse file tree Original file line number Diff line number Diff line change 99using System . Web . Http ;
1010using System . Web . Http . OData ;
1111using System . Web . Http . OData . Query ;
12+ using Microsoft . Data . OData ;
1213using NuGet . Frameworks ;
1314using NuGet . Services . Entities ;
1415using NuGet . Versioning ;
@@ -121,6 +122,10 @@ public async Task<IHttpActionResult> Get(
121122 customQuery = true ;
122123 }
123124 }
125+ catch ( ODataException ex ) when ( ex . InnerException != null && ex . InnerException is FormatException )
126+ {
127+ // Sometimes users make invalid requests. It's not exceptional behavior, don't trace.
128+ }
124129 catch ( Exception ex )
125130 {
126131 // Swallowing Exception intentionally. If *anything* goes wrong in search, just fall back to the database.
@@ -634,4 +639,4 @@ internal IQueryable<Package> GetAll()
634639 return _readWritePackagesRepository . GetAll ( ) ;
635640 }
636641 }
637- }
642+ }
You can’t perform that action at this time.
0 commit comments