What will be the username and password for mflix for code validation

Please help me on it. What will be the username and password for mflix for code validation

Hi @rajesh_50804,

Please elaborate your query.

If you are asking the username/password for cluster, then it is the credentials for the user you might have created when you were following the instructions of README file.

Username: m220student
Password: m220password

Kanika

No i want to see validation code after run python run.py command.
Than for it what will be the username and password

Hi @rajesh_50804,

Please let me know if the below points help:

  • You need to update your .ini file with your cluster connection string.
  • Then run pytest -m connection from your terminal / command line.
  • Then if it succeeds, then run python run.py.
  • There is no username or password required when you run run.py program. It is just a helper program that runs flask to provide a local webpage.
  • After that, open http://localhost:5000 in your browser like Safari / Chrome etc.
  • Then click on “STATUS” from top header.

Let me know if I have misinterpreted your query. Also, if you can provide a screenshot, it will help me to understand.

Kanika

Thanks for clear me. but my url is coming http://127.0.0.1:5000 not http://localhost:5000. So, where i need to modify , than it came localhost

this kind of error i am getting

File “C:\Users\abc\Anaconda3\lib\site-packages\flask\app.py”, line 1540, in ha
ndle_exception
reraise(exc_type, exc_value, tb)
File “C:\Users\abc\Anaconda3\lib\site-packages\flask_compat.py”, line 33, in
reraise
raise value
File “C:\Users\abc\Anaconda3\lib\site-packages\flask\app.py”, line 1982, in ws
gi_app
response = self.full_dispatch_request()
File “C:\Users\abc\Anaconda3\lib\site-packages\flask\app.py”, line 1614, in fu
ll_dispatch_request
rv = self.handle_user_exception(e)
File “C:\Users\abc\Anaconda3\lib\site-packages\flask_cors\extension.py”, line
161, in wrapped_function
return cors_after_request(app.make_response(f(*args, **kwargs)))
File “C:\Users\abc\Anaconda3\lib\site-packages\flask\app.py”, line 1517, in ha
ndle_user_exception
reraise(exc_type, exc_value, tb)
File “C:\Users\abc\Anaconda3\lib\site-packages\flask_compat.py”, line 33, in
reraise
raise value
File “C:\Users\abc\Anaconda3\lib\site-packages\flask\app.py”, line 1612, in fu
ll_dispatch_request
rv = self.dispatch_request()
File “C:\Users\abc\Anaconda3\lib\site-packages\flask\app.py”, line 1598, in di
spatch_request
return self.view_functionsrule.endpoint
File “C:\Users\abc\Downloads\mflix-python\mflix\api\movies.py”, line 26, in ap
i_get_movies
None, page=0, movies_per_page=MOVIES_PER_PAGE)
File “C:\Users\abc\Downloads\mflix-python\mflix\db.py”, line 220, in get_movie
s
cursor = db.movies.find(query).sort(sort)
File “C:\Users\abc\Anaconda3\lib\site-packages\werkzeug\local.py”, line 348, i
n getattr
return getattr(self._get_current_object(), name)
File “C:\Users\abc\Anaconda3\lib\site-packages\werkzeug\local.py”, line 307, i
n _get_current_object
return self.__local()
File “C:\Users\abc\Downloads\mflix-python\mflix\db.py”, line 47, in get_db
MFLIX_DB_URI,
File “C:\Users\abc\Anaconda3\lib\site-packages\pymongo\mongo_client.py”, line
494, in init
res = uri_parser.parse_uri(entity, port, warn=True)
File “C:\Users\abc\Anaconda3\lib\site-packages\pymongo\uri_parser.py”, line 39
9, in parse_uri
nodes = _get_dns_srv_hosts(fqdn)
File “C:\Users\abc\Anaconda3\lib\site-packages\pymongo\uri_parser.py”, line 28
9, in _get_dns_srv_hosts
raise ConfigurationError(str(exc))
pymongo.errors.ConfigurationError: The DNS operation timed out after 30.00151038
169861 seconds

It is the same thing. You can open http://127.0.0.1:5000.

Please check your connection string in .ini file.

Kanika