Kai, I'll look into this again soon as I get a moment, please bear with me

On Mon, Jan 22, 2018 at 6:39 PM, 'Kai Wang' via Google App Engine <
google-appengine@googlegroups.com> wrote:

> Cool.
>
> By saying "have to roll revert back", do you mean this issue is already
> solved in your current version of cloud sdk, without swapping
> urlfetch_cacerts.txt ?
>
> Thanks.
>
> On Monday, January 22, 2018 at 6:07:50 AM UTC-8, Richard Cheesmar wrote:
>>
>> kai,
>>
>> I will have to revert back to the old certs to reproduce it, I'll try to
>> provide some more information sometime this week if possible.
>>
>>
>>
>> On Sunday, January 21, 2018 at 11:25:36 PM UTC+3, Kai Wang wrote:
>>>
>>> The gcloud version is pretty new. But these information is not enough
>>> for reproducing.
>>>
>>> If you are running the app with dev_appserver
>>> <https://cloud.google.com/appengine/docs/standard/python/tools/using-local-server>,
>>> please *ATTACH A DEMO APP *for reproducing the issue.
>>> If not, please also give a guide of reproducing it.
>>>
>>> Otherwise, without even a stacktrace, it is hard to understand how the
>>> following is triggered:
>>>
>>>   File "/usr/local/google_appengine/google/appengine/api/urlfetch.py",
>>> line 467, in _get_fetch_result
>>>     'Invalid and/or missing SSL certificate for URL: ' + url)
>>> SSLCertificateError: Invalid and/or missing SSL certificate for URL:
>>> https://accounts.google.com/o/oauth2/token
>>>
>>>
>>> Your help will be sincerely appreciated.
>>>
>>>
>>>
>>>
>>> On Saturday, January 20, 2018 at 12:05:56 PM UTC-8, Richard Cheesmar
>>> wrote:
>>>>
>>>> Hi, kai,
>>>>
>>>> Chezs-MacBook-Air:google_appengine chez$ gcloud version
>>>> Google Cloud SDK 183.0.0
>>>> app-engine-python 1.9.64
>>>> beta 2017.09.15
>>>> bq 2.0.27
>>>> core 2017.12.08
>>>> gcloud
>>>> gsutil 4.28
>>>>
>>>>
>>>> Chezs-MacBook-Air:google_appengine chez$ openssl version
>>>> OpenSSL 0.9.8zh 14 Jan 2016
>>>>
>>>>
>>>>
>>>> On Saturday, January 20, 2018 at 8:04:36 PM UTC+3, Kai Wang wrote:
>>>>>
>>>>> Hi Richard,
>>>>>
>>>>>  error on the local dev machine when using googlecloudstorage to write
>>>>>> a file:
>>>>>
>>>>>
>>>>> Which development tool were you using?   Is it GAE's dev_appserver
>>>>> <https://cloud.google.com/appengine/docs/standard/python/tools/using-local-server>
>>>>>  ?
>>>>> Is it gsutil <https://cloud.google.com/storage/docs/quickstart-gsutil>
>>>>> ? Or else?
>>>>>
>>>>>
>>>>> I have some experience working on dev_appserver. AFAIK, apps running
>>>>> on dev_appserver have cloudstroage calls backed by a local fake.
>>>>> I found two docs mentioning dev_appserver with cloud storage [ 1
>>>>> <https://cloud.google.com/appengine/docs/standard/python/googlecloudstorageclient/app-engine-cloud-storage-sample>
>>>>> , 2
>>>>> <https://cloud.google.com/appengine/docs/standard/python/googlecloudstorageclient/setting-up-cloud-storage>
>>>>> ]
>>>>>
>>>>> Following the doc 1, I ran the attached demo app using
>>>>> dev_appserver.py;
>>>>> And hit "localhost:8080" returns:
>>>>>
>>>>>
>>>>> Demo GCS Application running from Version: None.873839430855777998
>>>>>
>>>>> Using bucket name: app_default_bucket
>>>>>
>>>>> Creating file /app_default_bucket/demo-testfile
>>>>>
>>>>>
>>>>> To be close to your code snippet, I especially changed main.py line 88
>>>>> to:
>>>>>
>>>>> with cloudstorage.open(filename, 'w', content_type='binary/octet-stream',
>>>>> options={b'x-goog-acl': b'public-read'}) as f:
>>>>>
>>>>>
>>>>> FYI, Digging into the urlfetch.py in our SDK, I found
>>>>> validate_certificate defaultly disabled.
>>>>>
>>>>>
>>>>> For trouble shooting, please DO update this thread with as much input
>>>>> as possible.
>>>>>
>>>>> Thanks.
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> On Thursday, January 4, 2018 at 5:04:40 AM UTC-8, Richard Cheesmar
>>>>> wrote:
>>>>>>
>>>>>> I'm getting the following error on the local dev machine when using
>>>>>> googlecloudstorage to write a file:
>>>>>>
>>>>>>   File "/usr/local/google_appengine/google/appengine/api/urlfetch.py",
>>>>>> line 467, in _get_fetch_result
>>>>>>     'Invalid and/or missing SSL certificate for URL: ' + url)
>>>>>> SSLCertificateError: Invalid and/or missing SSL certificate for URL:
>>>>>> https://accounts.google.com/o/oauth2/token
>>>>>>
>>>>>> import cloudstorage as gcs
>>>>>>
>>>>>> with gcs.open(filename, 'w', content_type=mime, options={b'x-goog-acl': 
>>>>>> b'public-read'}) as f:
>>>>>>     f.write(img)
>>>>>>     f.close()
>>>>>>
>>>>>> This was working perfectly and there have not been any code changes.
>>>>>> It also works on the live version.
>>>>>>
>>>>>>
>>>>>> Has anyone noticed the same?
>>>>>>
>>>>>> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Google App Engine" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/
> topic/google-appengine/TU3LwvRClCU/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> google-appengine+unsubscr...@googlegroups.com.
> To post to this group, send email to google-appengine@googlegroups.com.
> Visit this group at https://groups.google.com/group/google-appengine.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-appengine/6139c297-a900-4055-a083-
> a4185a789594%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/6139c297-a900-4055-a083-a4185a789594%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAOrJiXARp15f9YYVYGWkRg-fOL0kug9Fq_rjwL0XZGO3ewXtMA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to