Repository: sunpy/sunpy

Issue:
User warning when creating and instance of helio hec client
Get the following warning when creating a instance of the client, code works as expected just ugly warning and possibly worse performance.

    from sunpy.net.helio import hec
    hc = hec.HECClient()
    /Users/shane/.virtualenvs/gen/lib/python3.6/site-packages/bs4/__init__.py:181: UserWarning: No parser was explicitly specified, so I'm using the best available HTML parser for this system ("html.parser"). This usually isn't a problem, but if you run this code on another system, or in a different virtual environment, it may use a different parser and behave differently.

Fix make parser explicit since I think lxml is already a sunpy dependency use it or python's builtin

This [line](https://github.com/sunpy/sunpy/blob/master/sunpy/net/helio/parser.py#L107)

    soup = BeautifulSoup(endpoint_page)
could be change to

    soup = BeautifulSoup(endpoint_page, 'lxml')
or

    soup = BeautifulSoup(endpoint_page, 'html.parser')


Discussion:
Seem's that even though lxml is used [here](https://github.com/sunpy/sunpy/blob/master/sunpy/util/scraper.py) is not part of the dependencies in either setup.py or in any of the requirement files?
Yeah I don't really want to pick up a lxml dep just for this if we can avoid it.
So would you think leave as is or change to `BeautifulSoup(endpoint_page, 'html.parser')`?
This
https://github.com/sunpy/sunpy/blob/ae70bda1893f7129605d5dfc3357ba4281f3adbe/sunpy/util/scraper.py#L228
was added in https://github.com/sunpy/sunpy/commit/6675309a5b471991a1b24ccf745d168dd6265682 for fixing #1619. So maybe we do need `lxml`.

Resolving patch:
diff --git a/sunpy/net/helio/parser.py b/sunpy/net/helio/parser.py
--- a/sunpy/net/helio/parser.py
+++ b/sunpy/net/helio/parser.py
@@ -104,7 +104,7 @@ def endpoint_parser(link):
     endpoint_page = link_test(link)
     if endpoint_page is None:
         return None
-    soup = BeautifulSoup(endpoint_page)
+    soup = BeautifulSoup(endpoint_page, 'html.parser')
     endpoints = []
     for web_link in soup.find_all('a'):
         url = web_link.get('href')
diff --git a/sunpy/spectra/sources/callisto.py b/sunpy/spectra/sources/callisto.py
--- a/sunpy/spectra/sources/callisto.py
+++ b/sunpy/spectra/sources/callisto.py
@@ -69,7 +69,7 @@ def search(start, end, instruments=None, url=DEFAULT_URL):
         directory = url + day.strftime('%Y/%m/%d/')
         opn = urllib.request.urlopen(directory)
         try:
-            soup = BeautifulSoup(opn)
+            soup = BeautifulSoup(opn, 'html.parser')
             for link in soup.find_all("a"):
                 href = link.get("href")
                 for prefix, parser in PARSERS:
diff --git a/sunpy/util/scraper.py b/sunpy/util/scraper.py
--- a/sunpy/util/scraper.py
+++ b/sunpy/util/scraper.py
@@ -225,7 +225,7 @@ def filelist(self, timerange):
             try:
                 opn = urlopen(directory)
                 try:
-                    soup = BeautifulSoup(opn, "lxml")
+                    soup = BeautifulSoup(opn, "html.parser")
                     for link in soup.find_all("a"):
                         href = link.get("href")
                         if href.endswith(self.pattern.split('.')[-1]):


Test patch: