Default --app-dir makes __file__ ugly #1814
-
I use a slightly modified quickstart example to output value of the async def app(scope, receive, send):
print(__file__)
assert scope['type'] == 'http'
await send({
'type': 'http.response.start',
'status': 200,
'headers': [
[b'content-type', b'text/plain'],
],
})
await send({
'type': 'http.response.body',
'body': __file__.encode(),
}) When I run the app using I think that an empty string could be a better default value for this option. When I run the app using The empty string would be consistent with Python behavior:
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
If the behavior is the same, and you can point me out the discussion we had when it was introduced on a PR, I can review it. |
Beta Was this translation helpful? Give feedback.
If the behavior is the same, and you can point me out the discussion we had when it was introduced on a PR, I can review it.