     "SimpleXMLRPCServer" "site" "sitecustomize" "smtpd" "smtplib" "socket"
     "SocketServer" "sqlite3" "string" "StringIO" "struct" "subprocess" "sys"
     "sysconfig" "tabnanny" "tarfile" "tempfile" "textwrap" "threading" "time"
-    "timeit" "trace" "traceback" "typing" "unittest" "urllib" "urllib2" "urlparse"
+    "timeit" "trace" "traceback" "typing" "typing_extensions" "unittest" "urllib" "urllib2" "urlparse"
     "usercustomize" "uuid" "warnings" "weakref" "webbrowser" "whichdb" "xml"
     "xmlrpclib" "zipfile" "zipimport" "zlib" "builtins" "__builtin__"))
 

(defun ds/python-importable-symbols (path)
  (when (f-exists-p path)
    (with-temp-buffer
      (shell-command (concat "sed -n -e 's/^def \\([a-zA-Z][a-zA-Z0-9_]*\\).*/\\1/p' -e 's/^class \\([a-zA-Z][a-zA-Z0-9_]*\\).*/\\1/p' " path) t "*python-importable-symbols-errors*")
      (--> (buffer-substring (point-min) (point-max))
           (s-split "\n" it)))))


(defun ds/pick-import-location ()
  (save-excursion
    (goto-char (point-min))
    (re-search-forward "^def\\|^class" nil 'noerror)
    (re-search-backward "^import\\|^from" nil 'noerror)
    (beginning-of-line)
    (point)))

