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

[QUESTION] Supported on WSL? #294

Open
juamarCas opened this issue Nov 17, 2021 · 2 comments
Open

[QUESTION] Supported on WSL? #294

juamarCas opened this issue Nov 17, 2021 · 2 comments

Comments

@juamarCas
Copy link

Hi!
I want to verify if this is supported on WSL because when I run a test code I made its output is:

"terminate called after throwing an instance of 'sw::redis::Error'
what(): unknown error code: Failed to connect to Redis: U
Aborted
"_

this is the code I'm trying to run:

#include <iostream>
#include "sw/redis++/redis++.h"
int main(){
   
    sw::redis::ConnectionOptions conn_options; 
    conn_options.host = "127.0.0.1"; 
    conn_options.port = 6379; 
    auto redis = sw::redis::Redis(conn_options);

    
    redis.command<void>("set", "grumpy", "cat"); 
   
    return 0; 
}

Thanks for your answer and help.

@sewenew
Copy link
Owner

sewenew commented Nov 18, 2021

What's the version of hiredis, and redis-plus-plus you used? The error message, i.e. unknown error code, shows that the hiredis returns an error code that redis-plus-plus cannot recognize.

Regards

@juamarCas
Copy link
Author

What's the version of hiredis, and redis-plus-plus you used? The error message, i.e. unknown error code, shows that the hiredis returns an error code that redis-plus-plus cannot recognize.

Regards

Hi sewnew, I am using the last one since I cloned the repositories and did the installation manually. I tested the code in a Linux machine I had around and worked perfectly. Maybe is something with the WSL or some security problems.

Thank you.

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