Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

request.full_path property #1184

Closed
simonw opened this issue Jan 11, 2021 · 0 comments
Closed

request.full_path property #1184

simonw opened this issue Jan 11, 2021 · 0 comments

Comments

@simonw
Copy link
Owner

simonw commented Jan 11, 2021

I'll also add request.full_path for consistency with these:

@property
def path(self):
if self.scope.get("raw_path") is not None:
return self.scope["raw_path"].decode("latin-1")
else:
path = self.scope["path"]
if isinstance(path, str):
return path
else:
return path.decode("utf-8")
@property
def query_string(self):
return (self.scope.get("query_string") or b"").decode("latin-1")

Originally posted by @simonw in #1179 (comment)

@simonw simonw added the plugins label Jan 11, 2021
@simonw simonw closed this as completed in 649f48c Jan 11, 2021
simonw added a commit that referenced this issue Jan 19, 2021
@simonw simonw added this to the Datasette 0.54 milestone Jan 24, 2021
This was referenced Jan 25, 2021
simonw added a commit that referenced this issue Jan 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant