Comments (8)
Hi @Qwertyn, would you mind giving the master branch a try? I believe I've finally fixed this issue, at least for POST data, but it's possible it would crop up somewhere else - please let me know if you still encounter it with this version.
from httplog.
I've published v0.2.15 which should fix this at the cost of no longer unescaping URI-encoded data.
from httplog.
I tried master branch.
Error is reproduced.
The thing is that these characters are found in a response.
Response is handled by log_body:
# httplog/lib/httplog/http_log.rb
module HttpLog
...
class << self
...
def log_body(body, encoding = nil)
...
else
log("Response:\n#{body.to_s.force_encoding('UTF-8')}") # <<<< It helped me
end
end
end
end
end
Even better, in my opinion, do it all in one place
def log(msg)
# here
from httplog.
@trusche, Say what?
#29 - in my opinion, also a good solution
from httplog.
Yep, I'm combining yours with his, hopefully that'll do it. Thanks for your patience.
from httplog.
👍 Thanks!
We are waiting for version update on rubygems :-)
from httplog.
👍
from httplog.
@cavneb just to be sure - are you saying you're still encountering this issue? Or that you like the fix? :)
from httplog.
Related Issues (20)
- Is it possible to check programmatically if any external HTTP requests were made after a run? HOT 1
- Exception `Errno::ESPIPE` with chunked transfer encoding and pipe-io as body HOT 1
- Need to require Json even if config.json_log = false
- Crash on frozen string during force_encoding HOT 2
- How to stop logging a PNG binary
- Dependency Dashboard
- Binary body logged HOT 1
- Is adding require 'httplog' necessary? HOT 1
- NoMethodError (undefined method `log' for nil:NilClass)
- No logs and `undefined method [] for nil:NilClass`, Rails 7 HOT 7
- Version 1.6 Changelog Documentation HOT 2
- Allow/block the logging on runtime HOT 3
- Allow regexp on params filter HOT 2
- '(not showing binary data)' when the content-type is text/html HOT 1
- config.severity doesn't change log level HOT 2
- Bug: Ethon adapter fails when response headers are empty HOT 2
- question: is blacklisting supposed to prevent the request from being sent? HOT 2
- Support for production? HOT 1
- Action Required: Fix Renovate Configuration
- HTTP gem does not work with this gem HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from httplog.