code: def get_package_versions(package_name):
      url = f"https://pypi.python.org/pypi/{package_name}/json"
      with urllib.request.urlopen(url) as res:
          data = json.load(res)
  
      def is_dev_or_pre_release(version_str):
          v = Version(version_str)
          return v.is_devrelease or v.is_prerelease
  
      return [
          version
          for version, dist_files in data["releases"].items()
          if len(dist_files) > 0 and not is_dev_or_pre_release(version)
      ]
  
file_path: mlflow/dev/update_ml_package_versions.py
imports: import json
  import re
  import urllib.request
  from pathlib import Path
  import yaml
  from packaging.version import Version
label_desc: Use image node_id 3 for calling a global function with example usage: get_package_versions(package_name) and returns: unknown, unknown