Pytest -m connection

what should be the result of that command

If your setup is wrong it will print some error message.

If you do not have an error message you may processed with the next step.

I’ve several errors. The first one is:
File “C:\Users<my-user-name>\AppData\Roaming\Python\Python37\site-packages\”, line 397, in load_setuptools_entrypoints
plugin = ep.load()

Any suggestions?


Have you setup your .ini file as indicated. Please share its content.

Here is my .ini file

Ticket: Connection

Rename this file to .ini after filling in your MFLIX_DB_URI and your SECRET_KEY

Do not surround the URI with quotes

SECRET_KEY = super_secret_key_you_should_change
MFLIX_DB_URI = mongodb+srv://
MFLIX_NS = sample_mflix

SECRET_KEY = super_secret_testing_key
MFLIX_DB_URI = mongodb+srv://
MFLIX_NS = sample_mflix

Share a full screenshot of the command and the subsequent stack trace.

Thanks a lot for your help, I send the command + the whole response, as I understood that this is what you want to see

D:\dotnet\MongoDb\Courses\M220p\mflix-python>pytest -m connection
Traceback (most recent call last):
File “C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages\”, line 397, in load_setuptools_entrypoints
plugin = ep.load()
File “C:\ProgramData\Anaconda3\lib\site-packages\”, line 2444, in load
self.require(*args, **kwargs)
File “C:\ProgramData\Anaconda3\lib\site-packages\”, line 2467, in require
items = working_set.resolve(reqs, env, installer, extras=self.extras)
File “C:\ProgramData\Anaconda3\lib\site-packages\”, line 792, in resolve
raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.VersionConflict: (attrs 19.1.0 (c:\programdata\anaconda3\lib\site-packages), Requirement.parse(‘attrs>=19.2.0’))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “C:\ProgramData\Anaconda3\Scripts\”, line 10, in
File “C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages_pytest\”, line 50, in main
config = _prepareconfig(args, plugins)
File “C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages_pytest\”, line 160, in prepareconfig
pluginmanager=pluginmanager, args=args)
File "C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages\pluggy_init
.py", line 617, in call
return self._hookexec(self, self._nonwrappers + self.wrappers, kwargs)
File "C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages\pluggy_init
.py", line 222, in _hookexec
return self.inner_hookexec(hook, methods, kwargs)
File "C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages\pluggy_init
.py", line 216, in
File “C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages\pluggy\”, line 196, in _multicall
File “C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages_pytest\”, line 68, in pytest_cmdline_parse
config = outcome.get_result()
File “C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages\pluggy\”, line 76, in get_result
raise ex[1].with_traceback(ex[2])
File “C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages\pluggy\”, line 180, in _multicall
res = hook_impl.function(*args)
File “C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages_pytest\”, line 942, in pytest_cmdline_parse
File “C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages_pytest\”, line 1107, in parse
self._preparse(args, addopts=addopts)
File “C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages_pytest\”, line 1070, in preparse
File "C:\Users\itzhak.kagan\AppData\Roaming\Python\Python37\site-packages\pluggy_init
.py", line 402, in load_setuptools_entrypoints
“Plugin %r could not be loaded: %s!” % (, e))
pluggy.PluginValidationError: Plugin ‘hypothesispytest’ could not be loaded: (attrs 19.1.0 (c:\programdata\anaconda3\lib\site-packages), Requirement.parse(‘attrs>=19.2.0’))!

Yes, but I did say as a screenshot.

Run this command and send a screenshot of the output:
pip list | findstr /RI "attrs hypothesis pytest flask"

Thanks, sorry about that. Here is the screen shot
Hope it will be upload ok

Suggest you downgrade hypothesis:
pip install hypothesis==4.38.1

Thanks , Here is the screen shot of the installation
Is that OK?

0.7.0 for pytest-astropy

Thanks again, I did not understood what you mean. Should I run “pytest-astropy” command?

Install version 0.7.0 of pytest-astropy using pip

Thanks, I run the command “pip install pytest-astropy==0.7.0” and it was successfully installed.
Then I run “pytest -m connection”. Here is the result. Is it a desired result?

100% - looks good!

Thanks a lot for your help and for your patience, I really appreciate it !!!

:slightly_smiling_face: :+1: