ipykernel-helper 0.0.12__py3-none-any.whl → 0.0.13__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of ipykernel-helper might be problematic. Click here for more details.

@@ -1,2 +1,2 @@
1
- __version__ = "0.0.12"
1
+ __version__ = "0.0.13"
2
2
  from .core import *
ipykernel_helper/core.py CHANGED
@@ -166,7 +166,9 @@ def read_url(
166
166
  from urllib.parse import urlparse
167
167
  from bs4 import BeautifulSoup
168
168
 
169
- res = scrape_url(url).text
169
+ o = scrape_url(url)
170
+ res, ctype = o.text, o.headers.get('content-type').split(';')[0]
171
+
170
172
  soup = BeautifulSoup(res, "html.parser")
171
173
 
172
174
  if selector:
@@ -187,7 +189,7 @@ def read_url(
187
189
  current = current.next_sibling
188
190
  res = ''.join(str(el) for el in elements)
189
191
  else: res = ''
190
- if as_md: return get_md(res)
192
+ if as_md and ctype == 'text/html': return get_md(res)
191
193
  return res
192
194
 
193
195
  # %% ../nbs/00_core.ipynb
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ipykernel-helper
3
- Version: 0.0.12
3
+ Version: 0.0.13
4
4
  Summary: Helpers for ipykernel and friends
5
5
  Home-page: https://github.com/AnswerDotAI/ipykernel-helper
6
6
  Author: Jeremy Howard
@@ -0,0 +1,9 @@
1
+ ipykernel_helper/__init__.py,sha256=7byX0N8qjtMnanYWGgpBm__8aWTi6sy6Thzt4kYvjaQ,43
2
+ ipykernel_helper/_modidx.py,sha256=AEG4MccZfb25rQi8UWrOpUrs1VIYHbexKEQGWnwYkRg,3706
3
+ ipykernel_helper/core.py,sha256=uF7ELQgWEViESGFo1CzkSQ5AYwCRYXhiLBu-VFyCZfg,8238
4
+ ipykernel_helper-0.0.13.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
5
+ ipykernel_helper-0.0.13.dist-info/METADATA,sha256=n8MZrJA4m7URsD5JdenHMIwANHXDhGo4rSY_R_RXFaU,2709
6
+ ipykernel_helper-0.0.13.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
7
+ ipykernel_helper-0.0.13.dist-info/entry_points.txt,sha256=HWiK9xz75QtZUaPaYrwpyH5B8MbW0Ea_vi11UmwBImM,54
8
+ ipykernel_helper-0.0.13.dist-info/top_level.txt,sha256=_diD--64d9MauLE0pTxzZ58lkI8DvCrVc1hVAJsyc_Q,17
9
+ ipykernel_helper-0.0.13.dist-info/RECORD,,
@@ -1,9 +0,0 @@
1
- ipykernel_helper/__init__.py,sha256=NBQPBiYNpbwRh0tbd9ruOAJTKO2W4erG6F75QoavDZQ,43
2
- ipykernel_helper/_modidx.py,sha256=AEG4MccZfb25rQi8UWrOpUrs1VIYHbexKEQGWnwYkRg,3706
3
- ipykernel_helper/core.py,sha256=22E6FiiTI7Q8vPESVUHXyz8CoOWxDLkDe8tlSdJNEMQ,8150
4
- ipykernel_helper-0.0.12.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
5
- ipykernel_helper-0.0.12.dist-info/METADATA,sha256=EYR5VZ2ZiIDN_Jn_UAKqFqoKYVnnknoj_bT_9Th-x60,2709
6
- ipykernel_helper-0.0.12.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
7
- ipykernel_helper-0.0.12.dist-info/entry_points.txt,sha256=HWiK9xz75QtZUaPaYrwpyH5B8MbW0Ea_vi11UmwBImM,54
8
- ipykernel_helper-0.0.12.dist-info/top_level.txt,sha256=_diD--64d9MauLE0pTxzZ58lkI8DvCrVc1hVAJsyc_Q,17
9
- ipykernel_helper-0.0.12.dist-info/RECORD,,