GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — create_subprocess_exec treats env={} differently than vanilla asyncio · Issue #439 · MagicStack/uvloop Closed Description
When I set env={}, uvloop treats this as None and inherits all environment variables, while vanilla asyncio treats {} as an empty environment. import asyncio import os import pytest if os.environ.get("UVLOOP"): # Install uvloop event loop. import uvloop @pytest.fixture def event_loop(): loop = uvloop.new_event_loop() yield loop loop.close() @pytest.mark.asyncio async def test_env(): "This test passes under vanilla asyncio but fails under uvloop." proc = await asyncio.create_subprocess_exec( "/usr/bin/env", stdout=asyncio.subprocess.PIPE, env={}, ) result = await proc.communicate() # Under uvloop, stdout contains the full, inherited environment. assert result == (b"", None) Activity
MetadataMetadataAssigneesLabelsNo labels TypeProjectsMilestoneRelationshipsDevelopmentIssue actions |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |