morlovich commented on issue #1556: Combined css returns truncated, mis-encoded body on cache hit URL: https://github.com/apache/incubator-pagespeed-ngx/issues/1556#issuecomment-391043955 Huh. But that's CSS filter, not combiner, and we shouldn't be copying those sorts of headers from input.... I wonder if we're aliasing something we shouldn't be. On Tue, May 22, 2018 at 3:53 AM Otto van der Schaaf < [email protected]> wrote: > So the following diff helps with the bad content-length and mismatching > c-e headers: > > diff --git a/net/instaweb/rewriter/css_filter.cc b/net/instaweb/rewriter/css_filter.cc > index 8f653cd..7724d5e 100644 > --- a/net/instaweb/rewriter/css_filter.cc > +++ b/net/instaweb/rewriter/css_filter.cc > @@ -253,6 +253,8 @@ bool CssFilter::Context::SendFallbackResponse( > MessageHandler* handler) { > // Do not set the content length, since we may need to mutate the > // content as we stream out the bytes to correct for URL changes. > + async_fetch->response_headers()->RemoveAll(HttpAttributes::kContentEncoding); > + async_fetch->response_headers()->RemoveAll(HttpAttributes::kContentLength); > async_fetch->HeadersComplete(); > > DCHECK_EQ(1, num_slots()); > > But I'm not sure that this is the right thing to do. > > Also, while testing this diff, I observed that the combined css response > alternates in size. It looks like the minified and non-minified version of > the combination alternate randomly when responses are served. This may be a > related problem, or a totally different problem, I'm not sure. > > — > You are receiving this because you were mentioned. > Reply to this email directly, view it on GitHub > <https://github.com/apache/incubator-pagespeed-ngx/issues/1556#issuecomment-390896994>, > or mute the thread > <https://github.com/notifications/unsubscribe-auth/ADl1RIOSY5nc2lTzMbcxtUsYishukXCIks5t08PxgaJpZM4T34G3> > . >
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
