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

%2F is always replaced with backslash which may brakes CouchDB #186

Closed
wrazik opened this issue Oct 8, 2021 · 2 comments
Closed

%2F is always replaced with backslash which may brakes CouchDB #186

wrazik opened this issue Oct 8, 2021 · 2 comments

Comments

@wrazik
Copy link

wrazik commented Oct 8, 2021

Hi!
I'm trying to set up CouchDB data source with JSON API. I have a document in which "_id" contains backslashes, for example:

some/id

Full path to such object is:

localhost:5984/db_name/some%2Fid

Because of nature of CouchDB, below address is incorrect (it means "document with _id=some, field named 'id'")

localhost:5984/db_name/some/id

JSON API always replaces %2F with backslashes, so user can't setup address correctly.

There is a workaround for this - you have to encode % as html code %25:

localhost:5984/db_name/some%252Fid
@marcusolsson
Copy link
Contributor

marcusolsson commented Oct 13, 2021

I've had this reported in the past, and had to revert my fix at the time. I remember there seemed to be some inconsistencies with how the Grafana SDK interpreted encoded characters. For more information, check out #59.

If anyone wants to help debug this, I'd appreciate it, otherwise it might take a while before I take another stab at it.

@marcusolsson
Copy link
Contributor

Closing as duplicate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants