Ignore:
Timestamp:
05/30/25 17:37:04 (4 days ago)
Author:
István Váradi <ivaradi@…>
Branch:
python3
Phase:
public
Tags:
tip
Message:

context is used instead of cafile in urlopen()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mlx/web.py

    r1181 r1191  
    66from . import rpccommon
    77
    8 from .common import MAVA_BASE_URL
     8from .common import MAVA_BASE_URL, sslContext
    99from .pirep import PIREP
    1010
     
    629629                "cookie": "akamai_pilotweb_access=true;"
    630630            });
    631             f = urllib.request.urlopen(request, timeout = 10.0, cafile=certifi.where())
     631            f = urllib.request.urlopen(request, timeout = 10.0,
     632                                       context = sslContext)
    632633            try:
    633634                data = f.read(16384)
     
    666667        try:
    667668            url += data
    668             f = urllib.request.urlopen(url, timeout = 10.0, cafile = certifi.where())
     669            f = urllib.request.urlopen(url, timeout = 10.0,
     670                                       context = sslContext)
    669671            try:
    670672                for line in f.readlines():
Note: See TracChangeset for help on using the changeset viewer.