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

Add scenario in info dict of every molotov events #103

Open
douardda opened this issue Jan 25, 2018 · 4 comments
Open

Add scenario in info dict of every molotov events #103

douardda opened this issue Jan 25, 2018 · 4 comments

Comments

@douardda
Copy link

When writing a molotov event handler (like in example6.py), it would make life easier to have a reference to the scenario in sending_request or response_received events (as it is done for scenario_xxx events).

@tarekziade
Copy link
Owner

tarekziade commented Jan 25, 2018

That would be cool indeed. It requires two things:

would you like to takle it ? :)

@douardda
Copy link
Author

I'm currently digging it, yes

@tarekziade
Copy link
Owner

Notice that since we are in async mode, the scenario value should be linked to the request object, not the session, because the session deals with many requests in parallel

@douardda
Copy link
Author

I've seen that, and that makes life a bit harder since the request object is instanciated deep inside the ClientSession._request coroutine...

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

No branches or pull requests

2 participants