René's URL Explorer Experiment


Title: Storage: TypeError: request() takes at least 3 arguments (3 given) · Issue #3666 · googleapis/google-cloud-python · GitHub

Open Graph Title: Storage: TypeError: request() takes at least 3 arguments (3 given) · Issue #3666 · googleapis/google-cloud-python

X Title: Storage: TypeError: request() takes at least 3 arguments (3 given) · Issue #3666 · googleapis/google-cloud-python

Description: Hi, I'm having trouble while using google.cloud for Storage. I start by trying to list blobs in a bucket. I'm trying to get threw the proxy of my organization. So I try to create my own http connection in order to specify the proxy, but ...

Open Graph Description: Hi, I'm having trouble while using google.cloud for Storage. I start by trying to list blobs in a bucket. I'm trying to get threw the proxy of my organization. So I try to create my own http connec...

X Description: Hi, I'm having trouble while using google.cloud for Storage. I start by trying to list blobs in a bucket. I'm trying to get threw the proxy of my organization. So I try to create my own htt...

Opengraph URL: https://github.com/googleapis/google-cloud-python/issues/3666

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Storage: TypeError: request() takes at least 3 arguments (3 given)","articleBody":"Hi,\r\n\r\nI'm having trouble while using google.cloud for Storage. I start by trying to list blobs in a bucket.\r\nI'm trying to get threw the proxy of my organization. So I try to create my own http connection in order to specify the proxy, but even with a simple urllib3.PoolManager(), I keep getting the error and stacktrace bellow:\r\n\r\nError:\r\nTypeError: request() takes at least 3 arguments (3 given)\r\n\r\nStacktrace:\r\n\r\n```\r\nTraceback (most recent call last)\r\n\u003cipython-input-9-a7bd2d0fcc13\u003e in \u003cmodule\u003e()\r\n      3 authed_http = AuthorizedHttp(credentials, http)\r\n      4 storage_client = storage.Client(_http=http)\r\n----\u003e 5 bucket = storage_client.get_bucket('mybucket')\r\n      6 blobs = bucket.list_blobs()\r\n      7 \r\n\r\n/gpfs/user/u515866/env_python2/lib/python2.7/site-packages/google/cloud/storage/client.pyc in get_bucket(self, bucket_name)\r\n    171         \"\"\"\r\n    172         bucket = Bucket(self, name=bucket_name)\r\n--\u003e 173         bucket.reload(client=self)\r\n    174         return bucket\r\n    175 \r\n\r\n/gpfs/user/u515866/env_python2/lib/python2.7/site-packages/google/cloud/storage/_helpers.pyc in reload(self, client)\r\n     97         api_response = client._connection.api_request(\r\n     98             method='GET', path=self.path, query_params=query_params,\r\n---\u003e 99             _target_object=self)\r\n    100         self._set_properties(api_response)\r\n    101 \r\n\r\n/gpfs/user/u515866/env_python2/lib/python2.7/site-packages/google/cloud/_http.pyc in api_request(self, method, path, query_params, data, content_type, headers, api_base_url, api_version, expect_json, _target_object)\r\n    297         response, content = self._make_request(\r\n    298             method=method, url=url, data=data, content_type=content_type,\r\n--\u003e 299             headers=headers, target_object=_target_object)\r\n    300 \r\n    301         if not 200 \u003c= response.status \u003c 300:\r\n\r\n/gpfs/user/u515866/env_python2/lib/python2.7/site-packages/google/cloud/_http.pyc in _make_request(self, method, url, data, content_type, headers, target_object)\r\n    191         headers['User-Agent'] = self.USER_AGENT\r\n    192 \r\n--\u003e 193         return self._do_request(method, url, headers, data, target_object)\r\n    194 \r\n    195     def _do_request(self, method, url, headers, data,\r\n\r\n/gpfs/user/u515866/env_python2/lib/python2.7/site-packages/google/cloud/_http.pyc in _do_request(self, method, url, headers, data, target_object)\r\n    221         \"\"\"\r\n    222         return self.http.request(uri=url, method=method, headers=headers,\r\n--\u003e 223                                  body=data)\r\n    224 \r\n    225     def api_request(self, method, path, query_params=None,\r\n\r\nTypeError: request() takes at least 3 arguments (3 given)\r\n```\r\n\r\n-------------\r\n\r\nMy code is the following:\r\n\r\n```python\r\nfrom google.oauth2 import service_account\r\nfrom google.cloud import storage\r\nimport urllib3\r\nfrom google.auth.transport.urllib3 import AuthorizedHttp\r\n\r\njson=\"pathtojson\"\r\n\r\ncredentials = service_account.Credentials.from_service_account_file(json)\r\nhttp = urllib3.PoolManager()\r\n#authed_http = AuthorizedHttp(credentials, http)\r\nstorage_client = storage.Client(_http=http)\r\nbucket = storage_client.get_bucket('mybucket')\r\nblobs = bucket.list_blobs()\r\n\r\nfor blob in blobs:\r\n    print(blob.name)\r\n```\r\n\r\nPython is 2.7.11.\r\nI'm using Jupyter (notebook server is 5.0.0).\r\n\r\n`pip freeze`:\r\n\r\n\u003cdetails\u003e\r\n  \u003csummary\u003eClick to expand\u003c/summary\u003e\r\n\u003cpre\u003e\r\nasn1crypto==0.22.0\r\nbackports-abc==0.5\r\nbackports.shutil-get-terminal-size==1.0.0\r\nbleach==2.0.0\r\ncachetools==2.0.0\r\ncertifi==2017.4.17\r\ncffi==1.10.0\r\nchardet==3.0.4\r\nconfigparser==3.5.0\r\ncx-Oracle==5.3\r\ndecorator==4.0.11\r\ndill==0.2.7.1\r\nentrypoints==0.2.3\r\nenum34==1.1.6\r\nfunctools32==3.2.3.post2\r\nfuture==0.16.0\r\nfutures==3.1.1\r\ngapic-google-cloud-datastore-v1==0.15.3\r\ngapic-google-cloud-error-reporting-v1beta1==0.15.3\r\ngapic-google-cloud-logging-v2==0.91.3\r\ngapic-google-cloud-pubsub-v1==0.15.4\r\ngapic-google-cloud-spanner-admin-database-v1==0.15.3\r\ngapic-google-cloud-spanner-admin-instance-v1==0.15.3\r\ngapic-google-cloud-spanner-v1==0.15.3\r\ngapic-google-cloud-speech-v1==0.15.3\r\ngapic-google-logging-v2==0.10.1\r\ngapic-google-pubsub-v1==0.10.1\r\ngoogle-api-python-client==1.6.2\r\ngoogle-auth==1.0.1\r\ngoogle-auth-httplib2==0.0.2\r\ngoogle-cloud==0.26.1\r\ngoogle-cloud-bigquery==0.25.0\r\ngoogle-cloud-bigtable==0.25.0\r\ngoogle-cloud-core==0.25.0\r\ngoogle-cloud-datastore==1.1.0\r\ngoogle-cloud-dns==0.25.0\r\ngoogle-cloud-error-reporting==0.25.1\r\ngoogle-cloud-happybase==0.21.0\r\ngoogle-cloud-language==0.25.0\r\ngoogle-cloud-logging==1.1.0\r\ngoogle-cloud-monitoring==0.25.0\r\ngoogle-cloud-pubsub==0.26.0\r\ngoogle-cloud-resource-manager==0.25.0\r\ngoogle-cloud-runtimeconfig==0.25.0\r\ngoogle-cloud-spanner==0.25.0\r\ngoogle-cloud-speech==0.26.0\r\ngoogle-cloud-storage==1.2.0\r\ngoogle-cloud-translate==0.25.0\r\ngoogle-cloud-videointelligence==0.25.0\r\ngoogle-cloud-vision==0.25.0\r\ngoogle-gax==0.15.13\r\ngoogle-resumable-media==0.2.1\r\ngoogleapis-common-protos==1.5.2\r\ngrpc-google-iam-v1==0.11.1\r\ngrpc-google-logging-v2==0.10.1\r\ngrpc-google-pubsub-v1==0.10.1\r\ngrpcio==1.4.0\r\nhtml5lib==0.999999999\r\nhttplib2==0.10.3\r\nidna==2.5\r\nipaddress==1.0.18\r\nipykernel==4.6.1\r\nipython==5.4.1\r\nipython-genutils==0.2.0\r\nipywidgets==6.0.0\r\nJinja2==2.9.6\r\njsonschema==2.6.0\r\njupyter==1.0.0\r\njupyter-client==5.1.0\r\njupyter-console==5.1.0\r\njupyter-core==4.3.0\r\nMarkupSafe==1.0\r\nmistune==0.7.4\r\nnbconvert==5.2.1\r\nnbformat==4.3.0\r\nnotebook==5.0.0\r\nnumpy==1.13.1\r\noauth2client==3.0.0\r\noauthclient==1.0.3\r\npandas==0.20.3\r\npandocfilters==1.4.1\r\npathlib2==2.3.0\r\npexpect==4.2.1\r\npickleshare==0.7.4\r\nply==3.8\r\nprompt-toolkit==1.0.14\r\nproto-google-cloud-datastore-v1==0.90.4\r\nproto-google-cloud-error-reporting-v1beta1==0.15.3\r\nproto-google-cloud-logging-v2==0.91.3\r\nproto-google-cloud-pubsub-v1==0.15.4\r\nproto-google-cloud-spanner-admin-database-v1==0.15.3\r\nproto-google-cloud-spanner-admin-instance-v1==0.15.3\r\nproto-google-cloud-spanner-v1==0.15.3\r\nproto-google-cloud-speech-v1==0.15.3\r\nprotobuf==3.3.0\r\nptyprocess==0.5.2\r\npyasn1==0.2.3\r\npyasn1-modules==0.0.9\r\npycparser==2.18\r\nPygments==2.2.0\r\npysqlite==2.8.3\r\npython-dateutil==2.6.1\r\npytz==2017.2\r\npyzmq==16.0.2\r\nqtconsole==4.3.0\r\nrequests==2.18.1\r\nrsa==3.4.2\r\nscandir==1.5\r\nsimplegeneric==0.8.1\r\nsingledispatch==3.4.0.3\r\nsix==1.10.0\r\nSQLAlchemy==1.1.11\r\nterminado==0.6\r\ntestpath==0.3.1\r\ntornado==4.5.1\r\ntraitlets==4.3.2\r\nuritemplate==3.0.0\r\nurllib3==1.21.1\r\nwcwidth==0.1.7\r\nwebencodings==0.5.1\r\nwidgetsnbextension==2.0.0\r\n\u003c/pre\u003e\r\n\u003c/details\u003e\r\n\r\nPlease feel free to reformat this issue if that could help.\r\n\r\nMany thanks.","author":{"url":"https://github.com/kipi78","@type":"Person","name":"kipi78"},"datePublished":"2017-07-25T10:25:36.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":34},"url":"https://github.com/3666/google-cloud-python/issues/3666"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:5eca8b8e-2022-a282-c2ac-fef120189381
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idE310:1EE1:5A00CC:782F9A:6A4D74B7
html-safe-nonce2ca44dfb6a163326ee94eb27886672c1486b15d196b498080fc5fa5feb566946
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFMzEwOjFFRTE6NUEwMENDOjc4MkY5QTo2QTRENzRCNyIsInZpc2l0b3JfaWQiOiI4NTAxNjI4NDcyNzQ0ODM0MjMxIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmacf3443882451f6b7bd0edb9231d35de858ebb50558e6e54efbf402442dcf59435
hovercard-subject-tagissue:245355662
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/googleapis/google-cloud-python/3666/issue_layout
twitter:imagehttps://opengraph.githubassets.com/660e18a0caffd7b8719f0729c8aa53dbccfc35bbb528eb36d8ea6a8b81cdd58a/googleapis/google-cloud-python/issues/3666
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/660e18a0caffd7b8719f0729c8aa53dbccfc35bbb528eb36d8ea6a8b81cdd58a/googleapis/google-cloud-python/issues/3666
og:image:altHi, I'm having trouble while using google.cloud for Storage. I start by trying to list blobs in a bucket. I'm trying to get threw the proxy of my organization. So I try to create my own http connec...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamekipi78
hostnamegithub.com
expected-hostnamegithub.com
Nonec78260c7b3f4ac4b0356c8208537f05406a3a2d46a9ec3f735b372dcc519c39e
turbo-cache-controlno-preview
go-importgithub.com/googleapis/google-cloud-python git https://github.com/googleapis/google-cloud-python.git
octolytics-dimension-user_id16785467
octolytics-dimension-user_logingoogleapis
octolytics-dimension-repository_id16316451
octolytics-dimension-repository_nwogoogleapis/google-cloud-python
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id16316451
octolytics-dimension-repository_network_root_nwogoogleapis/google-cloud-python
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release399fff412f48461d435721c009efc17ea44be72f
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/googleapis/google-cloud-python/issues/3666#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fissues%2F3666
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fissues%2F3666
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=googleapis%2Fgoogle-cloud-python
Reloadhttps://github.com/googleapis/google-cloud-python/issues/3666
Reloadhttps://github.com/googleapis/google-cloud-python/issues/3666
Reloadhttps://github.com/googleapis/google-cloud-python/issues/3666
Please reload this pagehttps://github.com/googleapis/google-cloud-python/issues/3666
googleapis https://github.com/googleapis
google-cloud-pythonhttps://github.com/googleapis/google-cloud-python
Notifications https://github.com/login?return_to=%2Fgoogleapis%2Fgoogle-cloud-python
Fork 1.7k https://github.com/login?return_to=%2Fgoogleapis%2Fgoogle-cloud-python
Star 5.3k https://github.com/login?return_to=%2Fgoogleapis%2Fgoogle-cloud-python
Code https://github.com/googleapis/google-cloud-python
Issues 439 https://github.com/googleapis/google-cloud-python/issues
Pull requests 130 https://github.com/googleapis/google-cloud-python/pulls
Discussions https://github.com/googleapis/google-cloud-python/discussions
Actions https://github.com/googleapis/google-cloud-python/actions
Projects https://github.com/googleapis/google-cloud-python/projects
Security and quality 0 https://github.com/googleapis/google-cloud-python/security
Insights https://github.com/googleapis/google-cloud-python/pulse
Code https://github.com/googleapis/google-cloud-python
Issues https://github.com/googleapis/google-cloud-python/issues
Pull requests https://github.com/googleapis/google-cloud-python/pulls
Discussions https://github.com/googleapis/google-cloud-python/discussions
Actions https://github.com/googleapis/google-cloud-python/actions
Projects https://github.com/googleapis/google-cloud-python/projects
Security and quality https://github.com/googleapis/google-cloud-python/security
Insights https://github.com/googleapis/google-cloud-python/pulse
Storage: TypeError: request() takes at least 3 arguments (3 given)https://github.com/googleapis/google-cloud-python/issues/3666#top
https://github.com/dhermes
api: storageIssues related to the Cloud Storage API.https://github.com/googleapis/google-cloud-python/issues?q=state%3Aopen%20label%3A%22api%3A%20storage%22
https://github.com/kipi78
kipi78https://github.com/kipi78
on Jul 25, 2017https://github.com/googleapis/google-cloud-python/issues/3666#issue-245355662
dhermeshttps://github.com/dhermes
api: storageIssues related to the Cloud Storage API.https://github.com/googleapis/google-cloud-python/issues?q=state%3Aopen%20label%3A%22api%3A%20storage%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.