[google-appengine] Curious about Cloud Functions or Cloud Run?

2022-03-23 Thread wesley chun
I know we have lots of App Engine users here (duh), but if you were curious
about our other pair of serverless products (Cloud Functions
<http://cloud.google.com/functions> and Cloud Run <http://cloud.run/>), I'm
giving a real short (~20-min) high-level serverless
<http://cloud.google.com/serverless> overview at GDG Cloud Indy this Fri 9a
PDT/12n EDT/4p GMT. Online & free; register at Meetup
<http://meetup.com/GDGCloudIndy/events/284431016>; more info on LinkedIn
<http://linkedin.com/feed/update/urn:li:share:6908565837956145152> or the event
website <https://gdg.community.dev/e/m8azyv>.

Cheers,
--Wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google
<https://cloud.google.com/developers/advocates/wesley-chun/> by day; at
night: Core Python <http://amzn.com/dp/0132269937>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA4KTrvkWMLgEpeywFR-roP1a_VWFXT8miDS3fvN%3DLxiPg%40mail.gmail.com.


Re: [google-appengine] Entities Not Visible in Developer Console

2022-03-05 Thread wesley chun
Sounds good Dave... glad you were able to access your Entities again. In
general, console.*developers*.google.com is just a shortcut to the API
manager, and that's the only time that link should be used. For everything
else, you should be using console.*cloud*.google.com.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google
<https://cloud.google.com/developers/advocates/wesley-chun/> by day; at
night: Core Python <http://amzn.com/dp/0132269937>



On Tue, Mar 1, 2022 at 5:45 AM 'Dave Howes' via Google App Engine <
google-appengine@googlegroups.com> wrote:

> Thanks for this response - it turned out that I was using the wrong URL -
> I was going to https://console.developer.google.com/datastore
> <https://console.cloud.google.com/datastore> ( and have been for years )
> - changing to https://console.cloud.google.com/datastore fixed things
>
> Dave
>
> On Sunday, 27 February 2022 at 23:02:42 UTC Wesley C (Google) wrote:
>
>> There have been no changes AFAIK (as far as I know). Going to
>> https://console.cloud.google.com/datastore brings up all my DS entities
>> as expected.
>>
>> However, people sometimes run into problems if they have >1 Google login,
>> say accounts for work, personal, school, etc. Click on your avatar in the
>> upper-right corner to ensure you're logged into the correct account, or
>> select the right one from there if you're not.
>>
>>
>> On Sun, Feb 27, 2022 at 10:03 AM 'Dave Howes' via Google App Engine <
>> google-a...@googlegroups.com> wrote:
>>
>>> I have an application that has been running on App Engine Standard
>>> edition for a number of years. Today, when I went to the Datastore page of
>>> the developers console, I can't see any Entity kinds, and get the following
>>> message :
>>>
>>> "Request had invalid authentication credentials. Expected OAuth 2 access
>>> token, login cookie or other valid authentication credential. See
>>> https://developers.google.com/identity/sign-in/web/devconsole-project.";
>>>
>>> When I go to that page, it seems to be asking me to integrate Google
>>> SignIn with my application, which doesn't seem relevant.
>>>
>>> Has something changed regarding authentication that I have missed?
>>>
>>> Dave
>>>
>>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA4hyh_PC59x81fJsX4c%2BcnhnthrWda%3DYjB3aEOh9yw5sw%40mail.gmail.com.


Re: [google-appengine] Entities Not Visible in Developer Console

2022-02-27 Thread wesley chun
There have been no changes AFAIK (as far as I know). Going to
https://console.cloud.google.com/datastore brings up all my DS entities as
expected.

However, people sometimes run into problems if they have >1 Google login,
say accounts for work, personal, school, etc. Click on your avatar in the
upper-right corner to ensure you're logged into the correct account, or
select the right one from there if you're not.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google
<https://cloud.google.com/developers/advocates/wesley-chun/> by day; at
night: Core Python <http://amzn.com/dp/0132269937>



On Sun, Feb 27, 2022 at 10:03 AM 'Dave Howes' via Google App Engine <
google-appengine@googlegroups.com> wrote:

> I have an application that has been running on App Engine Standard edition
> for a number of years. Today, when I went to the Datastore page of the
> developers console, I can't see any Entity kinds, and get the following
> message :
>
> "Request had invalid authentication credentials. Expected OAuth 2 access
> token, login cookie or other valid authentication credential. See
> https://developers.google.com/identity/sign-in/web/devconsole-project.";
>
> When I go to that page, it seems to be asking me to integrate Google
> SignIn with my application, which doesn't seem relevant.
>
> Has something changed regarding authentication that I have missed?
>
> Dave
>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/33388dfa-ae44-4f4c-9952-928d82fde5d7n%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/33388dfa-ae44-4f4c-9952-928d82fde5d7n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA4cSr0gb1no-z%3DCFrgXRjdy6MWb8m9oeCsAyNx6VLVHRg%40mail.gmail.com.


Re: [google-appengine] Updates from the Google App Engine team (Fall 2021)

2022-01-08 Thread wesley chun
Reviving this for a bit: @Joshua: are you able to try out Python 3.8 (or
3.9) vs. 3.7 on App Engine? Several performance enhancements went into 3.8
<https://docs.python.org/3/whatsnew/3.8.html#demos-and-tools>, and I'm
curious whether that helps with what you've been experiencing. Also any
updates from your side?

Cheers,
--Wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google
<https://cloud.google.com/developers/advocates/wesley-chun/> by day; at
night: Core Python <http://amzn.com/dp/0132269937>



On Sat, Nov 6, 2021 at 7:12 AM Joshua Smith 
wrote:

> I'll put it on my to-do list to make a mock application that just does
> this hammer-on-startup thing. That seems pretty easy. (And it'll be
> interesting to see if a trivial mock app takes 5s to start up, or if
> there's some import I'm doing that's weighing things down.)
>
> -Joshua
>
> On Nov 5, 2021, at 6:39 PM, Jason Collins 
> wrote:
>
> Yes, it is the same scheduler (this is all on GAE Standard, right?) Of
> course, that scheduler has lots of knobs.
>
> If you can build a repro, can you work with support? If anything, the
> concurrency of GAE Python 3 should be better than GAE Python 2.
>
> On Fri, Nov 5, 2021 at 3:36 PM Joshua Smith 
> wrote:
>
>> I don't have threadsafe in my 3.7 app's app.yaml. Just runtime and
>> instance class. (I do have it in my 2.7 app, of course.)
>>
>> I'll try playing with max concurrent threads, but if I bump it from 10
>> (the default) to 16, that really just changes it from 6 request to start an
>> instance, to 9. Hard to see how that would make any difference.
>>
>> As I said, the 2.7 only starts one more instance when I hammer it, and it
>> doesn't end up giving it any work. That's very different behavior from the
>> 3.7 app which starts a bunch of instances and spreads the work to all of
>> them (resulting in all the requests taking at least 5 seconds to fulfill,
>> since the instance takes 5s to start up). This is clearly visible in the
>> logs I included in the first message.
>>
>> You're positive the scheduler is the same?
>>
>> -Joshua
>>
>> On Nov 5, 2021, at 5:08 PM, Jason Collins 
>> wrote:
>>
>> The scheduler is the same.
>>
>> This might have to do with `threadsafe` in app.yaml, which is complicated
>> and confusing. I'd suggest removing `threadsafe` if it's present, then try
>> setting the max_concurrent_requests to something higher (like 2x your
>> number of workers):
>> https://cloud.google.com/appengine/docs/standard/python/config/appref#max_concurrent_requests
>>
>>
>> On Fri, Nov 5, 2021 at 1:48 PM Joshua Smith 
>> wrote:
>>
>>> I figured out from the logs (since it prints a message for each worker
>>> it starts) that 3.7 is starting 8 workers by default. So adding the
>>> entrypoint with defaults has no effect.
>>>
>>> However, I did some experiments and I think I can characterize the
>>> difference between 2.7 and 3.7 when it comes to scaling.
>>>
>>> When first landing on my app's page it shows a list of thumbnails. These
>>> come from the datastore, with each thumbnail making a HTTP request (GET
>>> /image?which=1, GET /image?which=2, etc.). If we:
>>>
>>> 1. Query for all of these at once so the server gets hammered with
>>> simultaneous requests:
>>> - 2.7 starts one extra instance, and while that's happening the images
>>> are all served by the instance that already existed; the new instance never
>>> actually serves any of those image requests.
>>> - 3.7 starts a lot of instances; it dumps a bunch of requests to each of
>>> them (one per worker thread, I presume), all of which are going to take 5
>>> seconds because that's how long it takes each instance to start.
>>>
>>> The net result is the user of the 2.7 app sees all the images load right
>>> away, while the 3.7 app gets them over the course of 15 seconds or so, and
>>> sometimes there are timeout errors.
>>>
>>> 2. Query for these with a delay that's long enough to avoid overlapping
>>> requests:
>>> - Neither starts extra instances.
>>>
>>> The user sees all the images load pretty quick, but not quite as quick
>>> as 2.7 with the first approach.
>>>
>>> My conclusion is tha

Re: [google-appengine] Re: When will GAE Python 2.7 be shutdown

2022-01-08 Thread wesley chun
Hi again,

   1. *dev_appserver*: I replied in my other email that the tool currently
   is available for Python 3 but still requires some components from 2.7 to
   function properly and suggested you can file an external bug to make it
   fully functional in 3.x.
   2. *bundled services*: Google has made available as many of the bundled
   services as possible, but unfortunately there's currently no plan on making
   search available in the next generation runtimes. It is currently
   recommended to migrate to Elastic Search using a Compute Engine VM
   
<https://cloudplatform.googleblog.com/2015/01/Deploy-Elasticsearch-on-Google-Compute-Engine.html>
as
   recommended here
   
<https://cloud.google.com/appengine/docs/standard/python/migrate-to-python3/migrating-services#search>.
   The goal is not "to move people away from App Engine," but to make
   developers' apps more portable, so they can take their apps elsewhere if
   App Engine isn't the right fit for their needs (removing the notion of
   "vendor lock-in") by encouraging developers to migrate away from those
   legacy bundled services. They are strickly a migration tool to ease
   upgrading to Python 3 and will not receive any new features... all of the
   innovation is going into any standalone Cloud equivalent services.
   3. *2.x support*: As Alejandro alluded to, there are no current plans to
   shutdown the Python 2 runtime, even with the sunset of Python 2
   <http://python.org/doc/sunset-python-2/>, older Java, PHP 5, and Go
   versions older than 1.11, by their respective communities. Google Cloud has
   assured users by expressing continued long-term support of these legacy
   runtimes
   <https://cloud.google.com/appengine/docs/standard/long-term-support>,
   including maintaining the Python 2 runtime
   <https://cloud.google.com/python/docs/python2-sunset>. So while there is
   no requirement for users to migrate to Python 3 at this time, developers
   like you are expressing interest in updating their applications to the
   latest language releases.

Best regards,
--Wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
    Developer Advocate at Google
<https://cloud.google.com/developers/advocates/wesley-chun/> by day; at
night: Core Python <http://amzn.com/dp/0132269937>



On Fri, Jan 7, 2022 at 11:38 PM Sajal Gupta  wrote:

> Thanks Alejandro.
>
> *dev_appserver*: The challenge seems to be that it needs python 2
> installation for it to support python 3.x. So, looks like dev_appserver is
> still not "native" to python 3.x.And possibly due to this, I am not able to
> run dev_appserver in debugger mode for python 3.x applications.  That is
> what I meant about dev_appserver not being available fully for python 3.x.
>
> *Bundled services: *Yes, I looks like now memcache and task queue is
> being made available for python 3.x and these seem to be in beta as of now.
> However, from what I understand, *search * is not available as yet unless
> there is a concrete plan to make it available for 3.x. The current
> suggestion for search seems to be host our own on Kubernetes, which defeats
> the whole purpose of someone using Google App Engine - which hides all the
> infra from the developers.
>
> So, unless, the unstated intent of Google team is to move people away from
> App Engine eventually, current, proposed migration path is not helping.
>
> *Notice of termination of python 2.x*: Thank you. This helps.
>
> Regards
>
> Sajal
> On Friday, January 7, 2022 at 9:24:48 PM UTC+5:30 Alejandro L wrote:
>
>> Hello,
>>
>> Thank you for your message.
>>
>> As you mention, Python has ended support for versions 2.x, and we do
>> encourage our users to use a 3.x version. However, I would like to answer
>> all your questions, point by point:
>>
>> 0 - Dev_appserver does indeed have support for Python 3, which you can
>> find here
>> <https://cloud.google.com/appengine/docs/standard/python3/tools/using-local-server>
>> [1].
>>
>> 1 - GAE still supports many 2.x bundled services in the Python 3 runtime,
>> including memcache and task queue. You can find more information about this
>> in this paragraph
>> <https://cloud.google.com/appengine/docs/standard/python/migrate-to-python3#services>
>> [2] from the migrate to Python 3 page, and in this link
>> <https://cloud.google.com/appengine/docs/standard/python3/services/access>
>> [3]. However, currently, the recommendation is to consider migrating to 
>> unbundled
>> Google Cloud products
>> <https://cloud

Re: [google-appengine] Debugger in Python 3

2022-01-08 Thread wesley chun
Hi, there are several issues at play here:

1. *missing pdb section in the 3.x docs*: this section may be missing
possibly because it doesn't work in Python 3 or hasn't been tested or
validated. The best thing to do here is to go to the Python 3 page you
linked to, scroll down to the bottom, and click the blue "Send feedback"
button, then specify the Python 2 page PDB section link like you did in
your email and ask why this section is missing from *this* (Python 3) page.

2. *dev_appserver.py running on Python 3 still requires the presence of a
2.7 interpreter*: Look specifically at the blue sidebar on this page:
https://cloud.google.com/appengine/docs/standard/python3/tools/using-local-server#running_the_local_development_server
which tells you how to specify the location of your Python 3 interpreter.
While there is an internal bug created against removing final 2.x
dependencies (for a purely 3.x version), I don't see an equivalent external
bug for an App Engine dev_appserver issue
<https://issuetracker.google.com/issues?q=status:open%20dev_appserver> yet,
so if you want there to be a public record tracking this work, please file
a new bug in that same component
<https://issuetracker.google.com/issues/new?component=187227&template=1162615>
.

Depending on how you feel, you can take either (or both) of the above
actions.

Best regards,
--Wesley

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google
<https://cloud.google.com/developers/advocates/wesley-chun/> by day; at
night: Core Python <http://amzn.com/dp/0132269937>



On Sat, Jan 8, 2022 at 1:17 AM Sajal Gupta  wrote:

> Hello,
>
> I am trying to use debugger in python 3 in localhost - using
> dev_appserver. While I find documentation for python debugger usage in
> python 2.7 documentation, there is no similar section for python 3.
>
> See the url below for python 2:
> https://cloud.google.com/appengine/docs/standard/python/tools/using-local-server#debugging_with_pdb
>
> But corresponding section for python 3 is missing:
> https://cloud.google.com/appengine/docs/standard/python3/tools/using-local-server
>
> IDE's own debugger doesn't seem to work - I am using pycharm. Trying to
> use it gives the following error:
> ===
> /usr/bin/python2.7 "/Applications/PyCharm
> CE.app/Contents/plugins/python-ce/helpers/pydev/pydevd.py" --multiproc
> --qt-support=auto --client 127.0.0.1 --port 57002 --file
> /Users/sajal/google-cloud-sdk/bin/dev_appserver.py
> --runtime_python_path=/usr/bin/python3 --support_datastore_emulator=yes
> Connected to pydev debugger (build 213.6461.77)
>
> *ERROR: (dev_appserver) python2: command not found*
> Process finished with exit code 1
> 
>
> Could you please advise.
>
> Thank you.
>
> Sajal
>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/17f597c9-ce21-4a28-a6d7-bf8e26b5d935n%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/17f597c9-ce21-4a28-a6d7-bf8e26b5d935n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA53uPMNzgTLBFxN7f%3DRtQcB8yU4UCztjxhHd2EqyMNFzQ%40mail.gmail.com.


[google-appengine] App Engine PHP developers… the Google Cloud team needs you!

2021-11-10 Thread wesley chun
Six weeks ago, the Google Cloud serverless team released many of the
original App Engine APIs/bundled services
<https://cloud.google.com/blog/products/serverless/support-for-app-engine-services-in-second-generation-runtimes>
for most of the second-generation runtimes (Python 3, Java 11, Go 1.12+),
and PHP 7 is next! To ensure product readiness for customer workloads,
we're seeking App Engine app developers ready to upgrade their apps to PHP
7. Here is a chart illustrating the available services (Datastore,
Memcache, Task Queues, URLfetch, Mail, Users):


Please sign-up at this form <https://forms.gle/5r4RH2kKUnWJ5EDt5> to
request access to the private preview program. After registering, we will
grant access to the private preview, its documentation, and the
announcements mailing list. For more information, see this thread
<https://reddit.com/o9wr72> in the App Engine Subreddit.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google
<https://cloud.google.com/developers/advocates/wesley-chun/> by day; at
night: Core Python <http://amzn.com/dp/0132269937>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA7do5GqLRr6K9e6%3DgieByBT%3DeRj%2BxyfkfTDkjmJMz2BvA%40mail.gmail.com.


[google-appengine] Updates from the Google App Engine team (Fall 2021)

2021-11-04 Thread wesley chun
   great alternative; it also supports event-driven workloads
   -

   For those leveraging containerization as part of their app modernization
   or software development workflows or wish to avoid some of the constraints
   from App Engine or Cloud Functions, consider Cloud Run <http://cloud.run>
   .


Both Cloud Functions and Cloud Run have similar execution profiles, are
pay-per-use, deploy quickly, and autoscale as needed, just like what you're
used to from App Engine. Providing a more complete serverless product suite
that meets all your use cases and workloads is one of the goals of the Google
Cloud serverless <http://cloud.google.com/serverless> team.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google
<https://cloud.google.com/developers/advocates/wesley-chun/> by day; at
night: Core Python <http://amzn.com/dp/0132269937>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA5wxyv%3DKKtg3Ea4d3eV3y29pPvPx6sKR8Z%3DQ%3D9DfWROgg%40mail.gmail.com.


Re: [google-appengine] Re: local development server (dev_appserver.py) not running in http://localhost:8080/

2021-11-01 Thread wesley chun
A 500 generally indicates an issue w/the application code. Can you paste
your entrypoint code here as well as any other log entries that may be
useful so people can help debug? (Less relevant: any reason for not using
Python 3?)

On Mon, Nov 1, 2021 at 3:05 AM Supratik Nag  wrote:

> Hi,
>
> I didnt install those packages in first place. Now those are installed.
> But still same thing. Firefox shows a blank page and chrome the below
> messages:
> *This page isn’t working*
>
> *localhost is currently unable to handle this request.*
> *HTTP ERROR 500*
>
> (.venvp2) snag@mx-Xfce ~> pip list
> DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020.
> Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0
> will drop support for Python 2.7 in January 2021. More details about Python
> 2 support in pip can be found at
> https://pip.pypa.io/en/latest/development/release-process/#python-2-support
> pip 21.0 will remove support for this functionality.
> PackageVersion
> -- ---
> Jinja2 2.11.3
> MarkupSafe 1.1.1
> pip20.3.4
> setuptools 44.1.1
> webapp22.5.2
> wheel  0.37.0
> (.venvp2) snag@mx-Xfce ~>
>
> Thaks.
> On Saturday, 30 October 2021 at 01:05:40 UTC+5:30 NoCommandLine wrote:
>
>>
>> Your link has a Dependencies section which lists Jinja2 and Webapp2. Did
>> you install those dependencies?
>>
>> *Note:* The Dependencies also mentions "Twitter Bootstrap" but there is
>> a folder for it which means you don't have to download it
>>
>>
>>
>>  * .* NoCommandLine *..*
>>  https://nocommandline.com
>>
>> *A GUI for Google App Engine*
>>
>> On Friday, October 29, 2021 at 4:57:37 AM UTC-5 sna...@gmail.com wrote:
>>
>>> Hello,
>>>
>>> I have followed the instructions mentioned in the below page:
>>>
>>> https://cloud.google.com/appengine/docs/standard/python/getting-started/creating-guestbook
>>>
>>> Local configuration:
>>>
>>>- Debian (10) Linux
>>>- Python 2.7.16
>>>- Google Cloud SDK 362.0.0
>>>-
>>>- cat /etc/hosts
>>>   - 127.0.0.1 localhost
>>>   - 127.0.0.1   mx-Xfce
>>>
>>> I have tried 2 running the app in 2 different ways:
>>>
>>>1. From inside Python2.7 virtualenv: *sudo
>>>/opt/google-cloud-sdk/bin/dev_appserver.py ./app.yaml*
>>>2. From inside gc sdk bin directory: *python dev_appserver.py
>>>/home//appengine-guestbook-python/app.yaml*
>>>
>>> I get below messages in terminal:
>>> INFO 2021-10-28 21:21:28,722 devappserver2.py:316] Skipping SDK
>>> update check.
>>> INFO 2021-10-28 21:21:28,832 :383] Starting API server at:
>>> http://localhost:37783
>>> INFO 2021-10-28 21:21:28,900 dispatcher.py:281] Starting module
>>> "default" running at: http://localhost:8080
>>> INFO 2021-10-28 21:21:28,900 admin_server.py:150] Starting admin
>>> server at: http://localhost:8000
>>> INFO 2021-10-28 21:21:30,910 instance.py:294] Instance PID: 2803
>>>
>>> admin server http://localhost:8000 runs fine but default
>>> http://localhost:8080 does not:
>>> http://localhost:8080 says:
>>> *This page isn’t working*
>>>
>>> *localhost is currently unable to handle this request.*
>>> *HTTP ERROR 500*
>>>
>>> Please help to understand me what am I doing wrong here.
>>>
>>> Thanks,
>>> Supratik
>>>
>>> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/55a7a7c4-a73d-459c-9496-763317399884n%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/55a7a7c4-a73d-459c-9496-763317399884n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA4_%3DFr4yex%2BXP6gS5sHGaGNjZ9v3WmJHQK%3DbaqU3psVWA%40mail.gmail.com.


Re: [google-appengine] Re: Flask deployment

2021-10-05 Thread wesley chun
emy/pool/base.py",
>> line 767, in _checkout fairy = _ConnectionRecord.checkout(pool) File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/pool/base.py",
>> line 425, in checkout rec = pool._do_get() File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/pool/impl.py",
>> line 146, in _do_get self._dec_overflow() File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/util/langhelpers.py",
>> line 70, in __exit__ compat.raise_( File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/util/compat.py",
>> line 207, in raise_ raise exception File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/pool/impl.py",
>> line 143, in _do_get return self._create_connection() File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/pool/base.py",
>> line 253, in _create_connection return _ConnectionRecord(self) File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/pool/base.py",
>> line 368, in __init__ self.__connect() File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/pool/base.py",
>> line 611, in __connect pool.logger.debug("Error on connect(): %s", e) File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/util/langhelpers.py",
>> line 70, in __exit__ compat.raise_( File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/util/compat.py",
>> line 207, in raise_ raise exception File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/pool/base.py",
>> line 605, in __connect connection = pool._invoke_creator(self) File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/engine/create.py",
>> line 578, in connect return dialect.connect(*cargs, **cparams) File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/sqlalchemy/engine/default.py",
>> line 584, in connect return self.dbapi.connect(*cargs, **cparams) File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/MySQLdb/__init__.py",
>> line 130, in Connect return Connection(*args, **kwargs) File
>> "/layers/google.python.pip/pip/lib/python3.9/site-packages/MySQLdb/connections.py",
>> line 185, in __init__ super().__init__(*args, **kwargs2)
>> sqlalchemy.exc.OperationalError: (MySQLdb._exceptions.OperationalError)
>> (2003, "Can't connect to MySQL server on '34.152.7.115' (110)")"
>> timestamp: "2021-08-28T18:50:33.109645Z"
>>
>> The way I tried to configure the connection was using the following code
>> in my main.py file :
>>
>> database_name = 'edge_test'
>>
>>
>> app.config['SQLALCHEMY_DATABASE_URI'] = f'mysql://root:password@database_ip
>> /{database_name}'
>> app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = False
>>
>> db = SQLAlchemy(app)
>>
>> db_config = {
>> "pool_size": 5,
>> "max_overflow": 2,
>> "pool_timeout": 30,
>> "pool_recycle": 1800
>> }
>>
>> db_socket_dir = '/cloudsql'
>> db_connection_name = 'edge-321919:northamerica-northeast1:sam-edge-mysql'
>>
>> pool = create_engine(
>> # Equivalent URL:
>>
>> # 
>> mysql+pymysql://:@/?unix_socket=/
>> engine.url.URL.create(
>> drivername="mysql",
>> username='root',
>> password='MSSam20fred18',
>> database=database_name,
>> query={
>> "unix_socket": "{}/{}".format(
>> db_socket_dir,  # e.g. "/cloudsql"
>> db_connection_name)
>> }
>> ),
>> **db_config
>> )
>>
>> Any ideas why I am getting the error ?
>>
>> Thanks a lot in advance, I am very new to this and there is so much to
>> learn it is pretty overwhelming !
>>
>> Sam
>>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/003e4aec-c160-4255-823c-6a4fe788917fn%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/003e4aec-c160-4255-823c-6a4fe788917fn%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA5csLEzdSrPE1HTmbDwMLXAY9d6oxSFpX%2BuT6_A0v4wmA%40mail.gmail.com.


Re: [google-appengine] Google Translate API & Permissions

2021-09-28 Thread wesley chun
All, I'm happy to announce that I've finally published the blog post
<http://developers.googleblog.com/2021/09/exploring-serverless-with-nebulous-app.html?utm_source=blog&utm_medium=partner&utm_campaign=CDR_wes_aap-serverless_nebserv_sms_201028>
(Tweet
<http://twitter.com/googledevs/status/1442903087497183233?utm_source=twitter&utm_medium=unpaidsoc&utm_campaign=CDR_wes_aap-serverless_nebserv_sms_201028&utm_content=->
& FB post
<http://facebook.com/967415219957038/posts/456979724079?utm_source=facebook&utm_medium=unpaidsoc&utm_campaign=CDR_wes_aap-serverless_nebserv_sms_201028&utm_content=->
for sharing) I promised. Summarizing the 2 things that would've improved
Joshua's initial experience:

   1. Awareness of the *Google Cloud client libraries* (he used the Google
   APIs client libraries, lower-level and somewhat more challenging) — I'm
   working on a follow-up post explaining why we have two different types of
   client libraries and when you'd use one vs. the other.
   2. Awareness of *default service accounts* — these exist for all our
   serverless platforms and come pre-baked w/enough IAM permissions to get a
   prototype working; that gives you more time to research specific IAM
   roles/perms the app will need when you get closer to production.

The point is to make products that people can get started on without much
friction but also allow for more sophisticated usage as needed. I've also
provided Joshua's feedback directly to folks on our serverless platform
teams. Anyway, hope this helps and please let me know if you have any
questions; also reshare as desired to your developer social networks! (BTW,
thx for the kind words Eric!)

Cheers,
--Wesley

On Sat, May 8, 2021 at 6:09 AM Eric Hardy  wrote:

> Thank you Wesley.  I appreciate your efforts.  I want to spend more time
> site building than wrestling with a cloud platform.  I will follow the
> above mentioned links to nut this out.
>
> On Sat, May 8, 2021 at 9:20 AM wesley chun  wrote:
>
>> @Joshua: your inquiry inspired me to do some research into this issue
>> over the past few months resulting in the following:
>>
>> 1. *Use Cloud client libraries:* yep, your experience was not fun for
>> any developer looking to use a Cloud API (whether App Engine or a simple
>> cmd-line script). One solution is to avoid the Google APIs client library
>> <https://developers.google.com/api-client-library> and use the Google
>> Cloud client libraries
>> <http://cloud.google.com/apis/docs/cloud-client-libraries> instead, and
>> in your case just the one for Cloud Translation
>> (basic/v2
>> <https://cloud.google.com/translate/docs/reference/libraries/v2/python> or
>> advanced/v3
>> <https://cloud.google.com/translate/docs/reference/libraries/v3/python>).
>> (I'm also working on a blog post to outline the differences between these 
>> *platform
>> vs. product* client libraries, so stay tuned for that.) With the Cloud
>> Translation client library (which hides a lot of low-level details), your
>> code sample can be as simple as:
>>
>> from __future__ import print_function
>> import google.auth
>> from google.cloud import translate
>>
>> TRANSLATE = translate.TranslationServiceClient()
>> _, PROJECT_ID = google.auth.default()
>> PARENT = 'projects/{}'.format(PROJECT_ID)
>> TARGET_LANG = 'es'
>> TEXT = 'Hello world'
>> DATA = {
>> 'parent': PARENT,
>> 'contents': [TEXT],
>> 'target_language_code': TARGET_LANG,
>> }
>> try:# Python 3/advanced/v3
>> rsp = TRANSLATE.translate_text(request=DATA)
>> except TypeError:   # Python 2/basic/v2
>> rsp = TRANSLATE.translate_text(**DATA)
>> print(TEXT, '=', rsp.translations[0].translated_text)
>>
>> It works in Python 2 and 3 without any modification:
>>
>> $ python2 translate_demo2.py
>> Hello world = Hola Mundo
>> $ python3 translate_demo2.py
>> Hello world = Hola Mundo
>>
>> You should be able to just drop something like this right into your App
>> Engine code (plus the necessary stuff in app.yaml and requirements.txt).
>> App Engine comes with a default service account
>> <https://cloud.google.com/appengine/docs/standard/python/service-account>,
>> so you don't need to mess with all you did unless you need to (create a
>> separate service account and public/private key-pair) for other reasons. To
>> run this script *locally* (as I did above), you *do* need to do that
>> (create a service acct & keypair, download the JSON creden

Re: [google-appengine] Re: Where is the APIs & auth menu?

2021-07-26 Thread wesley chun
This thread isn't directly related to App Engine unless you're using Google
APIs from a GAE app, but if you find yourself needing to access the API
manager often, a shortcut link to go there directly is
console.developers.google.com ... once there, you'll get access to its 3
main pages:

   1. *Dashboard* -- your project's API usage, traffic, enabled APIs list
   2. *Library* -- where to search for and en-/disable APIs, and
   3. *Credentials* -- where you can create API keys, OAuth client IDs, or
   service acct credentials

--
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
<http://cyberwebconsulting.com/>
"Core Python" books : http://CorePython.com <http://corepython.com/>
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA6VXWHbGcrsL_%3DF-ixBOfPt-F4jFzcqEeqoH2m1YoOSpw%40mail.gmail.com.


[google-appengine] App Engine legacy bundled services private preview

2021-06-07 Thread wesley chun
To Java 8, Python 2, and Go 1.11 (or earlier) App Engine users:

In order to help with modernizing your apps to newer language releases, the
App Engine team is broadening the participation in our private preview of
the legacy bundled services. Previously, users have had to migrate from
bundled services like App Engine Datastore, Memcache, Task Queues, etc., to
their standalone, unbundled equivalent, i.e., Cloud Datastore, Cloud
Memorystore, Cloud Tasks, etc., before upgrading to the second generation
App Engine Java 11, Python 3, PHP 7, and Go 1.12 (and newer) runtimes.

Now by accessing these private preview features, you can do the vice versa:
upgrade to the modern language runtimes, then migrate to the new standalone
services on your own time. The legacy services we are making available are
meant to aid you as a migration tool. Be aware that new features and
product innovations will only take place in the newer standalone services,
so we do recommend upgrading when possible. Here is what's currently
available in the private preview (with more on the way soon):

Feature

Java 11

Python 3

Go 1.12+

Datastore
✔ ✔ ✔

Memcache
✔ ✔ ✔

Blobstore
✔
✔

Task Queues
✔
✔

URLfetch
✔ ✔ ✔

Mail
✔

Users
✔
✔

Images
✔


If you would like to register for the private preview, please fill out this
registration form
<https://docs.google.com/forms/d/e/1FAIpQLSd1hFLA2UFSYwIMxm9ZI3pwigORZBgjJRH0qrnhtE7nvhhRCQ/viewform>
. Registering will get you in the queue to access the private preview, its
documentation, and the announcements mailing list.
--
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA5b_ryFHPAvCTkSHy7BUaxRqe-RhN%2BvmB1RSX5SoJy-Gw%40mail.gmail.com.


Re: [google-appengine] Re: I can´t delete my Google Cloud account I used App Engine "for free"

2021-05-29 Thread wesley chun
Also for all future students who are finding this thread online, please try
to AVOID the Free Trial if you can. As a student, it's best if you work
with your professors and teachers to get completely free credits without
giving Google your credit card information. Send your educators to
cloud.google.com/edu and select "Faculty resources" where they can request
GCP ("teaching") credits as well as ("training") credits for Qwiklabs
codelab tutorials <http://google.qwiklabs.com> for students in their
courses. Students, you should never have to send an email message like this!

On Sat, May 29, 2021 at 3:15 PM 'babdelrahman' via Google App Engine <
google-appengine@googlegroups.com> wrote:

> Hello,
>
> I understand that you created a free trial account with GCP to do an
> assignment and that you can't delete the account.
>
> Kindly check document [1] on information about the GCP Free Tier.
>
> For the future, you can set budget alerts in order to not exceed a certain
> threshold [2].
>
> Since your only project is shut down, you will not be charged more.
>
> For information on how to delete your billing account, please check
> document [3].
>
> Can you elaborate more on the billing support that you are inquiring about?
>
>
> [1] https://cloud.google.com/free/docs/gcp-free-tier
> [2] https://cloud.google.com/billing/docs/how-to/budgets
> [3] https://cloud.google.com/billing/docs/how-to/manage-billing-account
> On Saturday, May 29, 2021 at 9:03:39 AM UTC-4 jdmval...@gmail.com wrote:
>
>> Hi everyone I create an account on Google Cloud because was an assignment
>> of my subject of Web Programming, so know that I send my homework, I can´t
>> delete the account
>> I´m on the free trial but I saw the charges in my credit card.
>> Tre project on App Engine I enabled and deleted with success I think, the
>> send an email
>> "our project supple-synapse-315102 has been shut down"
>> I can´t be able to have the support on Cloud Billing Support because I
>> need a project to request help
>> appears this  *To view this page, select a project.*
>>
>> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/6f0efd37-9749-4c67-92d4-f50e7e772169n%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/6f0efd37-9749-4c67-92d4-f50e7e772169n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA7B3jy3%3DWXQkpt3TZFx1maRq9J3WRzutC3ozhVyez%3DX8g%40mail.gmail.com.


Re: [google-appengine] Re: Where can your run "legacy" Google App Engine (Java) applications?

2021-05-12 Thread wesley chun
andard/long-term-support>,
>>> we've also got guides to help developers move off bundled services so
>>> they can upgrade to Java 11
>>> <https://cloud.google.com/appengine/docs/standard/java11/java-differences>.
>>> We're planning additional resources to help users upgrade their apps, so
>>> stay tuned for those. The first bunch for Python launched recently
>>> <https://twitter.com/wescpy/status/1378050414449319937?utm_source=twitter&utm_medium=unpaidsoc&utm_campaign=CDR_wes_aap-serverless_modernizegae_codelabsannounce_201031&utm_content=->,
>>> and we're planning equivalent resources for Java after all the Python ones
>>> are done.
>>>
>>> Cheers,
>>> --Wesley
>>>
>>> On Thu, Apr 29, 2021 at 3:21 PM 'cyberquarks' via Google App Engine <
>>> google-a...@googlegroups.com> wrote:
>>>
>>>> Hi, our app is built on Google App Engine (Java) version 1.9.40 where
>>>> all components are "integrated" into the runtime, the Datastore, the Task
>>>> Queue etc.
>>>>
>>>> On Friday, April 30, 2021 at 1:53:21 AM UTC+8 Elliott (Cloud Platform
>>>> Support) wrote:
>>>>
>>>>>
>>>>> Hello,
>>>>>
>>>>> I understand that you would like to run a legacy Java App Engine
>>>>> application on the infrastructure that exists currently in Google Cloud
>>>>> Platform without modifying the existing project.
>>>>>
>>>>> I was able to find a document
>>>>> <https://cloud.google.com/appengine/docs/standard/long-term-support>,
>>>>> which describes the legacy 8 version of Java still supported. What version
>>>>> of Java are you using? Are you using Google App Standard or Google App 
>>>>> Flex?
>>>>>
>>>>> I’m thinking that depending on your answer, you may choose to use
>>>>> Containers in Google Cloud Run <https://cloud.google.com/run> to
>>>>> create your environment but you indicated that you do not wish to modify
>>>>> your project.
>>>>>
>>>>> So to provide more options, I would ask you to give detail about your
>>>>> project.
>>>>>
>>>>>
>>>>>
>>>>> On Thursday, April 29, 2021 at 10:14:18 AM UTC-4
>>>>> qqua...@protonmail.com wrote:
>>>>>
>>>>>> Where can you run GAE application built with "integrated" Datastore?
>>>>>> Meaning, those application that were build prior to Google platform 
>>>>>> making
>>>>>> the Datastore a separate service from the "core" GAE service. That is
>>>>>> without modifying the project.
>>>>>>
>>>>>> Can the current Google App Engine run "legacy" applications?
>>>>>>
>>>>> --
>>>> 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-appengi...@googlegroups.com.
>>>> To view this discussion on the web visit
>>>> https://groups.google.com/d/msgid/google-appengine/eeeaee50-0677-4f9d-9b54-a3206409e6fcn%40googlegroups.com
>>>> <https://groups.google.com/d/msgid/google-appengine/eeeaee50-0677-4f9d-9b54-a3206409e6fcn%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>> .
>>>>
>>>
>>>
>>> --
>>> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
>>> "A computer never does what you want... only what you tell it."
>>> wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
>>> Architect & Engineer
>>> Developer Advocate at Google Cloud by day; at night...
>>> Python training & consulting : http://CyberwebConsulting.com
>>> "Core Python" books : http://CorePython.com
>>> Python blog: http://wescpy.blogspot.com
>>>
>> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/16bf9162-15e1-4231-87e6-4181b8ac244fn%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/16bf9162-15e1-4231-87e6-4181b8ac244fn%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA5yjmbyLjvF-BozG5taZo5ej7Rb23AkSgo%3DjKzT114GeQ%40mail.gmail.com.


Re: [google-appengine] Google Translate API & Permissions

2021-05-07 Thread wesley chun
in. I know that by fumbling around in the
> console I eventually ended up on a page where it wanted me to type an email
> address. And I eventually figured out that it wanted the email address of
> the service account. But for the life of me, I can't find that now.
>
> You need to write a how-to for giving an app engine app permission to
> access an API. Or if such a thing already exists, you need to elevate it to
> make it findable.
>
> -Joshua
>
> On Dec 4, 2020, at 2:17 PM, wesley chun  wrote:
>
> Thanks for your feedback Joshua. Can you take a screenshot of the Cloud
> Console where you think there should be a message or that is misleading,
> then go to the appropriate page in the documentation you think additional
> messaging would help, and click on the "Send feedback" button in the upper
> right corner of that page? The tool will also let you highlight where on
> the docs page your messaging should go. This will greatly help the team
> analyze your feedback and take appropriate action as necessary.
>
> Cheers,
> --Wesley
>
> On Fri, Nov 20, 2020 at 5:33 AM Joshua Smith 
> wrote:
>
>> That worked. Thank you so much.
>>
>> You guys need to work on your documentation. I never could have figured
>> that out myself. And the process of adding that role to the service account
>> was also weird. (The UX is asking for the email of a new user, when what I
>> need to add is a service account that isn’t a new user, and isn’t even
>> really an email.)
>>
>> -Joshua
>>
>> On Nov 19, 2020, at 2:19 PM, 'Amit Sinha' via Google App Engine <
>> google-appengine@googlegroups.com> wrote:
>>
>> *Hello Joshua, could you try to add the “Cloud Translation API User” role
>> in the service account from IAM? As of this [1] documentation, it includes
>> the permission that showing in the error.[1]
>> https://cloud.google.com/iam/docs/understanding-roles#cloud-translation-roles
>> <https://cloud.google.com/iam/docs/understanding-roles#cloud-translation-roles>*
>> On Monday, November 16, 2020 at 2:23:03 PM UTC-5 Joshua Smith wrote:
>>
>>> I don’t think Google could have come up with a more confusing and
>>> convoluted system for API permission management if they tried.
>>>
>>> So I’ve enabled the “cloud translation” API within my project.
>>>
>>> I have some Python (2.7, old school) code that goes:
>>>
>>> credentials =
>>> ServiceAccountCredentials.from_json_keyfile_name(CLIENT_SECRETS_FILE,
>>> scopes=['https://www.googleapis.com/auth/cloud-platform’])
>>> http_auth = credentials.authorize(Http())
>>> service = build("translation", "v3", http=http_auth)
>>> service.projects().translateText(parent=“projects/*my-project-id-here*",body={"contents":"bonjour",
>>> "targetLanguageCode":"en"}).execute()
>>>
>>> And I get:
>>>
>>> googleapiclient.errors.HttpError: >> https://translation.googleapis.com/v3/projects/*my-project-id-here*:translateText?alt=json
>>> returned "Cloud IAM permission 'cloudtranslate.generalModels.predict'
>>> denied.">
>>>
>>> So it seems like I need to check some box somewhere to make this work,
>>> but I can’t figure out where.
>>>
>>> The service account in the client secrets file is working fine when I
>>> use it to hit Google Analytics from the same app. And in fact, my code to
>>> access GA is almost identical except the scope and service call.
>>>
>>> Any ideas?
>>>
>>> -Joshua
>>>
>>>
>> --
>> 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 view this discussion on the web visit
>> https://groups.google.com/d/msgid/google-appengine/38511647-af55-4440-b8a9-47a2d26e1f42n%40googlegroups.com
>> <https://groups.google.com/d/msgid/google-appengine/38511647-af55-4440-b8a9-47a2d26e1f42n%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>>
>>
>> --
>> 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 view this discussion on the web visit

Re: [google-appengine] Re: Where can your run "legacy" Google App Engine (Java) applications?

2021-04-29 Thread wesley chun
At this time, you can run those applications with the "bundled services" on
our Java 8 App Engine runtime
<https://cloud.google.com/appengine/docs/standard/java>. That's the latest
version w/the bundled services available. The other one is Java 11 but
*without* bundled services
<https://cloud.google.com/appengine/docs/standard/java11>. Also see
the documentation
page highlighting the differences b/w both 1st and 2nd generation runtimes
<https://cloud.google.com/appengine/docs/standard/runtimes>.

While we're committed to supporting legacy runtimes
<https://cloud.google.com/appengine/docs/standard/long-term-support>, we've
also got guides to help developers move off bundled services so they can
upgrade to Java 11
<https://cloud.google.com/appengine/docs/standard/java11/java-differences>.
We're planning additional resources to help users upgrade their apps, so
stay tuned for those. The first bunch for Python launched recently
<https://twitter.com/wescpy/status/1378050414449319937?utm_source=twitter&utm_medium=unpaidsoc&utm_campaign=CDR_wes_aap-serverless_modernizegae_codelabsannounce_201031&utm_content=->,
and we're planning equivalent resources for Java after all the Python ones
are done.

Cheers,
--Wesley

On Thu, Apr 29, 2021 at 3:21 PM 'cyberquarks' via Google App Engine <
google-appengine@googlegroups.com> wrote:

> Hi, our app is built on Google App Engine (Java) version 1.9.40 where all
> components are "integrated" into the runtime, the Datastore, the Task Queue
> etc.
>
> On Friday, April 30, 2021 at 1:53:21 AM UTC+8 Elliott (Cloud Platform
> Support) wrote:
>
>>
>> Hello,
>>
>> I understand that you would like to run a legacy Java App Engine
>> application on the infrastructure that exists currently in Google Cloud
>> Platform without modifying the existing project.
>>
>> I was able to find a document
>> <https://cloud.google.com/appengine/docs/standard/long-term-support>,
>> which describes the legacy 8 version of Java still supported. What version
>> of Java are you using? Are you using Google App Standard or Google App Flex?
>>
>> I’m thinking that depending on your answer, you may choose to use
>> Containers in Google Cloud Run <https://cloud.google.com/run> to create
>> your environment but you indicated that you do not wish to modify your
>> project.
>>
>> So to provide more options, I would ask you to give detail about your
>> project.
>>
>>
>>
>> On Thursday, April 29, 2021 at 10:14:18 AM UTC-4 qqua...@protonmail.com
>> wrote:
>>
>>> Where can you run GAE application built with "integrated" Datastore?
>>> Meaning, those application that were build prior to Google platform making
>>> the Datastore a separate service from the "core" GAE service. That is
>>> without modifying the project.
>>>
>>> Can the current Google App Engine run "legacy" applications?
>>>
>> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/eeeaee50-0677-4f9d-9b54-a3206409e6fcn%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/eeeaee50-0677-4f9d-9b54-a3206409e6fcn%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA4-%3DTvzcK%2BDVfnX5cWhTzKnsEEhxb58CHVtnA5vPL11Hw%40mail.gmail.com.


Re: [google-appengine] Re: GAE Microservices

2021-04-27 Thread wesley chun
Hi Mukesh, in addition to my colleague Andrew's recommendations, I'll add
the following:

   1. You inquired about microservices. We have a Python 2 *App Engine
   microservices architecture*
   
<https://cloud.google.com/appengine/docs/standard/python/microservices-on-app-engine>
document
   that should be interesting to you.
   2. You could probably replicate a similar architecture on Python 3,
   however Python 3 on App Engine slightly different (no bundled services) so
   we didn't publish a similar page for 3.x. Another reason is that such an
   architecture on Python 3 may be better suited for its sister product, Google
   *Cloud Functions*
   <https://cloud.google.com/functions/docs/concepts/python-runtime>. What
   you call "modules" can be implemented as individual functions.
   3. If you're going to store data in Firebase, you might as well use
*Firebase
   Auth <https://firebase.google.com/docs/auth>* to authenticate your
   users. Learn about that and other auth options on App Engine from this
   page
   
<https://cloud.google.com/appengine/docs/standard/python3/authenticating-users>
   in the docs. (It's very likely the same technique can be used w/Cloud
   Functions as well).
   4. Heads-up there's a "new" product that combines the Firebase RTDB
   <http://firebase.google.com/products/realtime-database> + Google
   Cloud's NoSQL Cloud Datastore <http://cloud.google.com/datastore>
called *Cloud
   Firestore* <http://cloud.google.com/firestore> that launched in 2017
   <https://firebase.googleblog.com/2017/10/introducing-cloud-firestore.html>
   as the next-gen successor to both. If you're considering one of them,
   here's the page in the docs helping you decide b/w Firebase & Firestore
   <https://firebase.google.com/docs/database/rtdb-vs-firestore>.

Good luck and let us know how it goes!
--Wesley

On Sun, Apr 25, 2021 at 6:09 AM mukesh raj dass 
wrote:

> Hi
>
> Appreciate the feedback.
>
> I am using Standard environment in Python 3.7.  I need to create a URL for
> services that can only be access from inside the application after login
> authentication.  The
> services will be modules that will available.  It cannot be accessed from
> outside the application.  Do i restrict access via app.yaml only to allow
> access from within the application into a module which will be a "service"
> .  How best to do it ?
>
> Mukesh Raj
>
>
> On Friday, 23 April 2021 at 18:24:40 UTC+10 anco...@google.com wrote:
>
>> Which documentation are you following? Are you thinking of using GAE Flex
>> or GAE Standard?
>>
>> I have added a couple of links that you might find interesting that
>> details how requests are routed in GAE. Please note, this is for Python but
>> the concept is the same for other languages.
>>
>>-
>>
>>How Requests are Routed
>>
>> <https://cloud.google.com/appengine/docs/standard/python3/how-requests-are-routed>
>>-
>>
>>Communicating Between Your Services
>>
>> <https://cloud.google.com/appengine/docs/standard/python3/communicating-between-services>
>>-
>>
>>Serverless network endpoint groups overview
>>
>> <https://cloud.google.com/load-balancing/docs/negs/serverless-neg-concepts>
>>
>>
>> On Monday, April 12, 2021 at 11:54:36 AM UTC+2 optimum...@gmail.com
>> wrote:
>>
>>> Hi
>>>
>>> I am trying to develop an GAE with multiple modules each having distinct
>>> codes talking to Firebase.  A client might need an app with only 2 modules
>>> and other might need 5 modules...i was hoping to load them as services or
>>> microservices...problem is how to connect them together ?
>>>
>>> It is like going to an accounting system and having a GL, Job Costing,
>>> Project costing as a separate module.  In the main entry point  (services:
>>> default) there will be a button to go to each services or modules  From
>>> what i understand in the documentation...each services (previously modules)
>>> cannot access to each of them unless via REST.
>>>
>>> Any bright ideas how to do it in GAE using Firebase ?
>>>
>>> Appreciate the input.
>>>
>> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/b7a45753-f14a-41ab-adb1-34f0daa4c12en%40googlegr

[google-appengine] More migration resources

2021-04-14 Thread wesley chun
Greetings long-time App Engine developers,

If you're running on Python 2, Java 6-8, Go 1.6-1.11, and PHP 5, we'd like
to encourage you to consider upgrading to Python 3, Java 11, Go 1.12+, and
PHP 7. The issue facing many of you is that moving to the next-gen App
Engine platform involves two significant changes, so we understand why
there has been some hesitancy:

   1. Upgrading to a newer language version
   2. Moving from bundled to unbundled/best-of-breed services

While Google can't help with the former, we *can* do something about the
latter. Last month, my colleague announced
<https://groups.google.com/g/google-appengine/c/6Ws9IXl_QmM/m/3ZvsIozbAAAJ> a
community-driven repo of migration samples
<https://github.com/GoogleCloudPlatform/appengine-python2-3-migration>. A
few weeks ago, I introduced a series of codelab tutorials
<https://twitter.com/wescpy/status/1378050414449319937?utm_source=twitter&utm_medium=unpaidsoc&utm_campaign=CDR_wes_aap-serverless_modernizegae_codelabsannounce_201031&utm_content=->
to give users hands-on experience migrating unbundled services, starting
with Python as those developers have even greater challenges due to Python
3 not being backwards-compatible to Python 2. There is also content for
those interested in containerizing their App Engine apps (for Cloud Run).

These are just a few steps we're taking to help existing users modernize
their apps. Stay tuned for additional resources coming soon from the App
Engine team.

Best regards,
--Wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA50wfHow%3D6ZuD-yC2v4z7t_ydFnQDknppN04N6SumEtKA%40mail.gmail.com.


Re: [google-appengine] Re: Need Assistance to select product

2021-03-29 Thread wesley chun
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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/dd0e0d39-8159-47d5-8810-afbcf2b8f8ffn%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/dd0e0d39-8159-47d5-8810-afbcf2b8f8ffn%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA7KoMoSFnGmcoYQp_5R3a-R-jHW5WU9hmXOLXmb6XJB3g%40mail.gmail.com.


Re: [google-appengine] Google Translate API & Permissions

2020-12-04 Thread wesley chun
Thanks for your feedback Joshua. Can you take a screenshot of the Cloud
Console where you think there should be a message or that is misleading,
then go to the appropriate page in the documentation you think additional
messaging would help, and click on the "Send feedback" button in the upper
right corner of that page? The tool will also let you highlight where on
the docs page your messaging should go. This will greatly help the team
analyze your feedback and take appropriate action as necessary.

Cheers,
--Wesley

On Fri, Nov 20, 2020 at 5:33 AM Joshua Smith 
wrote:

> That worked. Thank you so much.
>
> You guys need to work on your documentation. I never could have figured
> that out myself. And the process of adding that role to the service account
> was also weird. (The UX is asking for the email of a new user, when what I
> need to add is a service account that isn’t a new user, and isn’t even
> really an email.)
>
> -Joshua
>
> On Nov 19, 2020, at 2:19 PM, 'Amit Sinha' via Google App Engine <
> google-appengine@googlegroups.com> wrote:
>
> *Hello Joshua, could you try to add the “Cloud Translation API User” role
> in the service account from IAM? As of this [1] documentation, it includes
> the permission that showing in the error.[1]
> https://cloud.google.com/iam/docs/understanding-roles#cloud-translation-roles
> <https://cloud.google.com/iam/docs/understanding-roles#cloud-translation-roles>*
> On Monday, November 16, 2020 at 2:23:03 PM UTC-5 Joshua Smith wrote:
>
>> I don’t think Google could have come up with a more confusing and
>> convoluted system for API permission management if they tried.
>>
>> So I’ve enabled the “cloud translation” API within my project.
>>
>> I have some Python (2.7, old school) code that goes:
>>
>> credentials =
>> ServiceAccountCredentials.from_json_keyfile_name(CLIENT_SECRETS_FILE,
>> scopes=['https://www.googleapis.com/auth/cloud-platform’])
>> http_auth = credentials.authorize(Http())
>> service = build("translation", "v3", http=http_auth)
>> service.projects().translateText(parent=“projects/*my-project-id-here*",body={"contents":"bonjour",
>> "targetLanguageCode":"en"}).execute()
>>
>> And I get:
>>
>> googleapiclient.errors.HttpError: > https://translation.googleapis.com/v3/projects/*my-project-id-here*:translateText?alt=json
>> returned "Cloud IAM permission 'cloudtranslate.generalModels.predict'
>> denied.">
>>
>> So it seems like I need to check some box somewhere to make this work,
>> but I can’t figure out where.
>>
>> The service account in the client secrets file is working fine when I use
>> it to hit Google Analytics from the same app. And in fact, my code to
>> access GA is almost identical except the scope and service call.
>>
>> Any ideas?
>>
>> -Joshua
>>
>>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/38511647-af55-4440-b8a9-47a2d26e1f42n%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/38511647-af55-4440-b8a9-47a2d26e1f42n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>
>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/96693B33-8943-4948-8444-7F9ABAAAB70D%40gmail.com
> <https://groups.google.com/d/msgid/google-appengine/96693B33-8943-4948-8444-7F9ABAAAB70D%40gmail.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA6qha4NWpPqtRQvSt3v86vPwJQ02j%3D_UtFT8w5m6KnHGQ%40mail.gmail.com.


Re: [google-appengine] Re: CloudTasks Queue (HTTP Tasks) break when disabling AppEngine

2020-12-03 Thread wesley chun
Thanks for the feedback... I see you're referring to the NOTE sidebar here
,
correct? Is your request to have a similar note placed on the Cloud Console
page to disable their App Engine apps
 warning users it will
also disable their Task Queues, regardless of where the task handlers are
(GAE or not)?

If so, go to that page in the docs, in the upper right corner, click the
"Send Feedback" button and use the tool to submit a screenshot of that NOTE
and let us know this warning should also appear on that Cloud Console page.
This will give weight to any bug filed (when customers experience issues
like this).

I think the reason you have to have an *enabled* App Engine "app" (in the
console even if you don't actually have any code running on App Engine) is
that Cloud Tasks originated from App Engine, and they haven't fully
migrated it away from GAE yet.

Thanks,
--Wesley

On Mon, Nov 30, 2020 at 2:04 PM Micah Thomas  wrote:

> Wesley,
>
> Our application uses HTTP handlers that are running in kubernetes on the
> same project, we don't use any appengine targets.
> The issue is that even w/o any handlers running in appengine, if I disable
> the appengine project, cloud tasks stop working.
>
> I now see that the official docs page has a note: The appengine project
> must stay enabled for queues to function.
> It would be better for user experience if this info is shown when you go
> to disable the appengine project so that a user is not surprised when the
> queues stop working.
>
> On Monday, November 30, 2020 at 2:38:33 PM UTC-7 Wesley C (Google) wrote:
>
>> There are 2 different types of (push) tasks that Cloud Tasks can handle,
>> and it depends on *where* the tasks are handled. These are called
>> "targets," and you can have App Engine targets, meaning the tasks run on
>> and are handled by App Engine, or generic HTTP targets, meaning the tasks
>> are hosted and are handled elsewhere, say a VM, Cloud Functions, etc. You
>> can read more about both types in this official docs page
>> .
>>
>> Focusing more specifically on your question, if your target tasks are
>> hosted on App Engine, then you project/app should *not* be disabled, but if
>> it is a standard HTTP target, you don't need an App Engine app for *that*
>> case. Hope this helps!
>>
>> On Sat, Nov 21, 2020 at 12:32 PM Micah Thomas 
>> wrote:
>>
>>> Thanks for pointing that out.
>>>
>>> I didn't get that impression from anywhere else, and it was confusing
>>> that cloud tasks have it's own page in google cloud if it depends on
>>> appengine.
>>> Anyway, I'll probably look into another system, and just keep the
>>> appengine app running till I migrate our queues over to something else.
>>>
>>> On Friday, November 20, 2020 at 7:24:52 AM UTC-7 jstsetinin wrote:
>>>

 Hello,

 Thak you for your question.

 According to our documentation "You must have an enabled App Engine
 application in your project to run your queue." [1]
 It is not possible to make it work without Appengine.

 [1] https://cloud.google.com/tasks/docs/quickstart-appengine
 On Friday, 20 November 2020 at 01:43:25 UTC+1 micaht...@gmail.com
 wrote:

> Hello,
>
> I am having trouble with Cloud Tasks (HTTP Request Tasks) breaking
> when I disable my app-engine application. For the time being I've
> re-enabled the app-engine application to get the cloud tasks queue to keep
> working. I thought Cloud Tasks was a separate project, and does not depend
> on appengine.
>
> Not sure who I should be talking to, if this is not the right
> group/place.
>


-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA7qzx0LjismcEm%3DWxHaz_yF4TkMyH7DY9WUzVUo0RQ8iQ%40mail.gmail.com.


Re: [google-appengine] Re: CloudTasks Queue (HTTP Tasks) break when disabling AppEngine

2020-11-30 Thread wesley chun
There are 2 different types of (push) tasks that Cloud Tasks can handle,
and it depends on *where* the tasks are handled. These are called
"targets," and you can have App Engine targets, meaning the tasks run on
and are handled by App Engine, or generic HTTP targets, meaning the tasks
are hosted and are handled elsewhere, say a VM, Cloud Functions, etc. You
can read more about both types in this official docs page
<https://cloud.google.com/tasks/docs/dual-overview>.

Focusing more specifically on your question, if your target tasks are
hosted on App Engine, then you project/app should *not* be disabled, but if
it is a standard HTTP target, you don't need an App Engine app for *that*
case. Hope this helps!

On Sat, Nov 21, 2020 at 12:32 PM Micah Thomas 
wrote:

> Thanks for pointing that out.
>
> I didn't get that impression from anywhere else, and it was confusing that
> cloud tasks have it's own page in google cloud if it depends on appengine.
> Anyway, I'll probably look into another system, and just keep the
> appengine app running till I migrate our queues over to something else.
>
> On Friday, November 20, 2020 at 7:24:52 AM UTC-7 jstsetinin wrote:
>
>>
>> Hello,
>>
>> Thak you for your question.
>>
>> According to our documentation "You must have an enabled App Engine
>> application in your project to run your queue." [1]
>> It is not possible to make it work without Appengine.
>>
>> [1] https://cloud.google.com/tasks/docs/quickstart-appengine
>> On Friday, 20 November 2020 at 01:43:25 UTC+1 micaht...@gmail.com wrote:
>>
>>> Hello,
>>>
>>> I am having trouble with Cloud Tasks (HTTP Request Tasks) breaking when
>>> I disable my app-engine application. For the time being I've re-enabled the
>>> app-engine application to get the cloud tasks queue to keep working. I
>>> thought Cloud Tasks was a separate project, and does not depend on
>>> appengine.
>>>
>>> Not sure who I should be talking to, if this is not the right
>>> group/place.
>>>
>> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/f09a677a-7f5e-424f-bcfb-5ddd5b7ead78n%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/f09a677a-7f5e-424f-bcfb-5ddd5b7ead78n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA4C3yYTfqVBYHdk0hKz80yenAnAQXTeWoaxvCY-jf%3Ddrw%40mail.gmail.com.


Re: [google-appengine] Re: Python App

2020-11-30 Thread wesley chun
Unfortunately the code you have is a Python command-line script, meaning
you can't use Google Cloud serverless platforms (App Engine, Cloud
Functions, Cloud Run) unless you either add API endpoints and data
serialization, or turn it into a full web app.

Based on what you have right now, you can try to run it elsewhere: 1) in
Cloud Shell, 2) on a Compute Engine VM (most users get an f1-micro free
each month), 3) Kubernetes Engine (more complex, but you seem have a
`google.yml` file for it), or 4) on your own computer.

On Sun, Nov 29, 2020 at 11:52 AM Zain Basit  wrote:

> https://github.com/zainbasit/GoogleCloudPlatform this is the app I want
> to deploy and execute, cloud functions didn't work.
>
> On Monday, November 30, 2020 at 12:28:24 AM UTC+5 yananc wrote:
>
>> *Hello, If you would like to know general information on how to deploy
>> and run Python apps on App Engine, please refer to the Quickstart for
>> Python 3 in App Engine Standard
>> <https://cloud.google.com/appengine/docs/standard/python3/quickstart> and
>> Quickstart for Python in App Engine Flexible
>> <https://cloud.google.com/appengine/docs/flexible/python/quickstart> for
>> detailed steps and sample Hello World apps for demonstration. If you have
>> any specific questions or issues regarding the matter, please kindly
>> elaborate so it would be much easier to get them answered.*
>>
>> On Sunday, November 29, 2020 at 9:58:09 AM UTC-5 zainb...@gmail.com
>> wrote:
>>
>>> Want to execute and run python app
>>
>> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/294a84ea-b75f-43d4-a9bf-be5304612fd8n%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/294a84ea-b75f-43d4-a9bf-be5304612fd8n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA4CekH20nAPegM1V6vvemAYBW29p-kXQXKpoVdND%2BAsKg%40mail.gmail.com.


Re: [google-appengine] Re: import 2nd library

2020-11-11 Thread wesley chun
That's quite odd John. Can you temporarily rename your main.py and deploy
this code as main.py and run it?

from flask import Flask
from google import cloud

app = Flask(__name__)

@app.route('/')
def hello_world():
return 'Hello, World!'

Pls reply with what shows up in your App Engine dashboard
<https://console.cloud.google.com/appengine> down in the "Application
Errors" section.
Also paste relevant lines from your app.yaml (or the whole thing).

Thanks,
--Wesley

On Wed, Nov 11, 2020 at 12:17 PM John Iacovacci 
wrote:

> I've isolated the problem down to my app engine python code not allowing
> me to import more than one module. Even a simple hello world app will only
> allow me to implement one import. Every time I add a module to any of my
> program I get errors.
>
> On Wed, Nov 11, 2020 at 2:58 PM 'Elliott (Cloud Platform Support)' via
> Google App Engine  wrote:
>
>> Hello,
>>
>> To isolate the problem, does this code run locally on your machine?
>>
>> On Wednesday, November 11, 2020 at 12:18:48 PM UTC-5 john.ia...@gmail.com
>> wrote:
>>
>>> I'm trying to import the datastore module(or anytime I try to import a
>>> second module for that matter) in my app engine standard code.
>>>
>>> I've virtually tried every combination and I'm getting either
>>>
>>> Error: Server ErrorThe server encountered an error and could not
>>> complete your request.
>>>
>>> Please try again in 30 seconds.
>>>
>>>
>>> or 502 Gateway ngix errors.
>>>
>>>
>>> Any thoughts?
>>>
>>>
>>> Thanks
>>>
>>>
>>> John Iacovacci
>>>
>>> main.py
>>> from flask import Flask, request, render_template
>>>
>>> # START Translate requirements
>>> from google.cloud import translate_v2 as translate
>>> translate_client = translate.Client()
>>>
>>> import datastore
>>> # END Translate requirements
>>>
>>>
>>> app = Flask(__name__)   # Flask is the web framework we're using
>>>
>>>
>>> @app.route('/', methods=['POST','GET']) # This defines when the 
>>> function below will be called
>>> def translate():
>>> if request.method == 'POST':
>>>
>>> # This code will run if a POST is received
>>>
>>> data = request.form.to_dict(flat=True)  # Reads the body of the 
>>> post request and assigns it to the "data" variable
>>>
>>> result = translate_client.translate(data['inputText'], 
>>> target_language=data["toLang"]) # Sends data to the translate API
>>>
>>> return 
>>> render_template('index.html',translatedText=result['translatedText'])# 
>>> Renders the page with the response
>>>
>>> else:
>>>
>>> # This code will run if a GET is received
>>> return render_template('index.html')
>>>
>>>
>>> # Don't worry about this part
>>> if __name__ == '__main__':
>>> app.run(host='127.0.0.1', port=8080, debug=True)
>>>
>> --
>> 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 view this discussion on the web visit
>> https://groups.google.com/d/msgid/google-appengine/02857814-1a89-4d13-b0cb-eaa593e2dba9n%40googlegroups.com
>> <https://groups.google.com/d/msgid/google-appengine/02857814-1a89-4d13-b0cb-eaa593e2dba9n%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/CADTT8SQZP_svALjuaUY_SFf%2Bdim%2BV_uGZHHPmruXFGqbvZyMvA%40mail.gmail.com
> <https://groups.google.com/d/msgid/google-appengine/CADTT8SQZP_svALjuaUY_SFf%2Bdim%2BV_uGZHHPmruXFGqbvZyMvA%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA50EiJne-8syMHXbHyuYT30Kk4NkesDcb9vwRr0avSF6g%40mail.gmail.com.


Re: [google-appengine] Google App Engine code not updated after deployment

2020-10-28 Thread wesley chun
Go to your app's Services page
<https://console.cloud.google.com/appengine/services>. You should then see
what's up-and-running. For each live version, if you go to the Diagnose
column and click on the Tools pulldown, select "Source" to see the files so
you can see the code that's running under specific versions and confirm
what's running (and what's not).

On Wed, Oct 28, 2020 at 1:10 AM Tuan Nguyen  wrote:

> Hi,
> So I have a GAE app. However when I update the application multiple times
> a day, sometimes the website is reverted back to the previous version, or
> just does not contain the latest code.
> Just wondering how to fix this behaviour. I have deleted all unused
> versions, but seems like the code is not at the latest when I do a
> deployment.
>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/95f60db1-c6f4-4c9d-ab9a-16da049d3c5dn%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/95f60db1-c6f4-4c9d-ab9a-16da049d3c5dn%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA4MfOBi1akKE9q%2B2F_qqDAyPNBbdJNgaU1ztOX94t1d6w%40mail.gmail.com.


Re: [google-appengine] Can we create a billing account without turning on the free $300/90 days credit?

2020-09-17 Thread wesley chun
Also, track this SO question <http://stackoverflow.com/questions/63915713>
as some Googlers are active on it. And if you feel compelled to contact
Cloud billing/support folks sooner than later, here are some links:

   - https://console.cloud.google.com/support/chat
   - https://cloud.google.com/support/billing


On Wed, Sep 16, 2020 at 7:35 AM 'David (Cloud Platform Support)' via Google
App Engine  wrote:

> As per the free trial documentation
> <https://cloud.google.com/free/docs/gcp-free-tier>, the free trial will
> start automatically when you set up your billing account so you must be
> prepared to use your free trial when doing this.
> On Tuesday, September 15, 2020 at 7:21:59 PM UTC-4 NP wrote:
>
>> >>>> then create a billing account there
>> <https://console.cloud.google.com/billing/create> and see if you can do
>> so w/o activting the Free Trial <<<
>>
>> Right now, it looks to me like it will activate it. I don't want to
>> complete the step in case it does activate the free trial (since there's no
>> way to turn it off). Is there any way to confirm if it will or will not
>> activate the free trial?
>>
>>
>> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/7dd76c05-b8e7-4ee3-845e-337e6ba45cbdn%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/7dd76c05-b8e7-4ee3-845e-337e6ba45cbdn%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA4VVMO0gNUx1kNFEZa1MaphMYZKPFRSBrNjKqsm%3DyxTiQ%40mail.gmail.com.


Re: [google-appengine] Re: Not able to run dev_appserver with Python 3 only environment

2020-09-17 Thread wesley chun
am just
>> trying to play around with the sample app from the documentation), I get:
>>
>> dev_appserver.py app.yaml
>> ERROR: (dev_appserver) python2: command not found
>>
>> I installed google-cloud-sdk using brew with: brew cask install
>> google-cloud-sdk.
>>
>> As of now, my only requirement for my app is GAE and datastore and I am
>> hoping to be able to use the datastore emulator with the above.
>>
>> Ritesh
>>
>
-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA6V40dOWEfWSDfqh7vbbzpM%3Dpx9jZKg8QUMLqusdYA7fQ%40mail.gmail.com.


Re: [google-appengine] Can we create a billing account without turning on the free $300/90 days credit?

2020-09-14 Thread wesley chun
Hello. You're correct that appcfg.py
<https://cloud.google.com/appengine/docs/standard/python/tools/appcfg-arguments>
is going away
<https://cloud.google.com/appengine/docs/standard/java/tools/migrating-from-appcfg-to-gcloud>.
Try going to the cloud console <https://console.cloud.google.com>, select
your App Engine project from the top, then create a billing account there
<https://console.cloud.google.com/billing/create> and see if you can do so
w/o activting the Free Trial (which I agree with you on -- no one should
activate it until they have enough regular use to take advantage of it,
esp. since it expires in 3 mos). Once you've created a billing account
using a credit card, you s/b able to use gcloud deploy successfully to
deploy.

Can you also privately send me some terminal screenshots of gcloud deploy
asking for a billing account, and if a new one is created, it automatically
activates the Cloud Console?

Thank you,
--Wesley

On Mon, Sep 14, 2020 at 11:36 AM NP  wrote:

> Hello,
>
> GAE no longer allows deployment to production using app cfg. They insist
> you must use "gcloud deploy".
>
> However, when you try to use "gcloud deploy", it insists you must enable a
> billing account and enabling this automatically turns on the 'free' $300
> credit which expires in 90 days or so.
>
>
> Given that I'm still in early stages of development (only deploying to
> production to make sure everything works), I do not wish to waste the 90
> days/free $300 credit.
>
> So my questions are
>
> 1) Is it possible to create a new billing account without turning on the
> free $300/90 days credit?
>
> 2) Is there still a way to use appcfg.py to deploy your app (which means I
> don't need the answer to question 1)?
>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/30bfd66c-6281-40ca-bfc0-6fb206c86c30o%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/30bfd66c-6281-40ca-bfc0-6fb206c86c30o%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA5-6%2By-URLrTAsbo4qdyCZoAY_0%2BZVGWyjPEmKnEH%3DP1Q%40mail.gmail.com.


Re: [google-appengine] Re: Obtaining refresh_token through offline_access scope to be used with IAP

2020-09-02 Thread wesley chun
That's great to hear José. I'm a bit new to using JWT tokens myself (having
only used OAuth2 access & refresh tokens) when talking to Google APIs. One
big advantage to JWT tokens is that you save API calls to both exchange a
JWT for an access token as well as your case of needing to send a refresh
token to get a new/valid access token. Cheers!

On Wed, Sep 2, 2020 at 1:04 AM 'José Cantera' via Google App Engine <
google-appengine@googlegroups.com> wrote:

> Yes, Wesley is right, in the end a refresh_token is not that necessary in
> this case, it suffices with self-signing a new JWT token with the exp
> timestamp updated,
>
> thanks!
>
> On Wed, Sep 2, 2020 at 3:26 AM wesley chun  wrote:
>
>> Hi, I may not be correct in my understanding but believe that refresh
>> tokens are only used in cases where you're using OAuth2 access tokens for
>> authorization. Since you're using a self-signed JWT instead of an access
>> token
>> <https://developers.google.com/identity/protocols/oauth2/service-account#jwt-auth>,
>> I don't think the useful reference that David linked to applies in your
>> case (and BTW, this is independent of whether you're using IAP or not).
>>
>> Since you're signing the JWT token, can't you simply resign it with an
>> updated timestamp in your JWT payload (as shown a bit further down on the
>> page I just linked to above)? (I believe that'll have the same effect of
>> using a refresh token to get an updated access token.)
>>
>> On Tue, Sep 1, 2020 at 2:00 PM 'David (Cloud Platform Support)' via
>> Google App Engine  wrote:
>>
>>> This documentation
>>> <https://developers.google.com/identity/protocols/oauth2/web-server#offline>
>>> about refreshing an access token (offline access) using Google's
>>> authorization server could be helpful.
>>>
>>> On Monday, August 31, 2020 at 8:26:25 AM UTC-4 jose.c...@iota.org wrote:
>>>
>>>> I am using IAP to protect a Web API Application. I have enabled a
>>>> service account to get access to the APIs through an id_token. I am able to
>>>> obtain an id_token (JWT) by signing a JWT (using the keys of my service
>>>> account) with the following assertions
>>>> {
>>>>  "iss": "xx.iam.gserviceaccount.com",
>>>>  "sub": "xx.iam.gserviceaccount.com",
>>>>  "aud": "https://oauth2.googleapis.com/token";,
>>>>  "target_audience": "my_application_client_id",
>>>>  "iat": 1598702078,
>>>>  "exp": 1598705593
>>>>  }
>>>>
>>>> and then Posting to the token service as follows
>>>> curl --location --request POST 'https://oauth2.googleapis.com/token' \
>>>> --header 'Content-Type: application/x-www-form-urlencoded' \
>>>>  --data-urlencode 'assertion=’
>>>>  --data-urlencode
>>>> 'grant_type=urn:ietf:params:oauth:grant-type:jwt-bearer' \
>>>> --data-urlencode 'scope=openid’
>>>>
>>>> Now I would like to also obtain a refresh_token and has been
>>>> impossible. I have tried with *scope=openid offline_access* but no
>>>> luck. Is *offline_access* implemented in the Google Auth Server? Any
>>>> other mechanism to obtain a refresh_token?
>>>>
>>>> Thank you very much
>>>>
>>>> *IOTA Foundation*
>>>> c/o Nextland
>>>> Strassburgerstraße 55
>>>> 10405 Berlin, Germany
>>>>
>>>> Board of Directors: Dominik Schiener, David Sønstebø, Serguei Popov,
>>>> Navin Ramachandran
>>>> ID/Foundation No.: 3416/1234/2 (Foundation Register of Berlin)
>>>>
>>> --
>>> 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 view this discussion on the web visit
>>> https://groups.google.com/d/msgid/google-appengine/9687fedb-925a-42ef-9c26-439febdf168fn%40googlegroups.com
>>> <https://groups.google.com/d/msgid/google-appengine/9687fedb-925a-42ef-9c26-439febdf168fn%40googlegroups.com?utm_medium=email&utm_source=footer>
>>> .
>>>
>>
>>
>> --
>> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
>> "A compute

Re: [google-appengine] Re: Obtaining refresh_token through offline_access scope to be used with IAP

2020-09-01 Thread wesley chun
Hi, I may not be correct in my understanding but believe that refresh
tokens are only used in cases where you're using OAuth2 access tokens for
authorization. Since you're using a self-signed JWT instead of an access
token
<https://developers.google.com/identity/protocols/oauth2/service-account#jwt-auth>,
I don't think the useful reference that David linked to applies in your
case (and BTW, this is independent of whether you're using IAP or not).

Since you're signing the JWT token, can't you simply resign it with an
updated timestamp in your JWT payload (as shown a bit further down on the
page I just linked to above)? (I believe that'll have the same effect of
using a refresh token to get an updated access token.)

On Tue, Sep 1, 2020 at 2:00 PM 'David (Cloud Platform Support)' via Google
App Engine  wrote:

> This documentation
> <https://developers.google.com/identity/protocols/oauth2/web-server#offline>
> about refreshing an access token (offline access) using Google's
> authorization server could be helpful.
>
> On Monday, August 31, 2020 at 8:26:25 AM UTC-4 jose.c...@iota.org wrote:
>
>> I am using IAP to protect a Web API Application. I have enabled a service
>> account to get access to the APIs through an id_token. I am able to obtain
>> an id_token (JWT) by signing a JWT (using the keys of my service account)
>> with the following assertions
>> {
>>  "iss": "xx.iam.gserviceaccount.com",
>>  "sub": "xx.iam.gserviceaccount.com",
>>  "aud": "https://oauth2.googleapis.com/token";,
>>  "target_audience": "my_application_client_id",
>>  "iat": 1598702078,
>>  "exp": 1598705593
>>  }
>>
>> and then Posting to the token service as follows
>> curl --location --request POST 'https://oauth2.googleapis.com/token' \
>> --header 'Content-Type: application/x-www-form-urlencoded' \
>>  --data-urlencode 'assertion=’
>>  --data-urlencode
>> 'grant_type=urn:ietf:params:oauth:grant-type:jwt-bearer' \
>> --data-urlencode 'scope=openid’
>>
>> Now I would like to also obtain a refresh_token and has been impossible.
>> I have tried with *scope=openid offline_access* but no luck. Is
>> *offline_access* implemented in the Google Auth Server? Any other
>> mechanism to obtain a refresh_token?
>>
>> Thank you very much
>>
>> *IOTA Foundation*
>> c/o Nextland
>> Strassburgerstraße 55
>> 10405 Berlin, Germany
>>
>> Board of Directors: Dominik Schiener, David Sønstebø, Serguei Popov,
>> Navin Ramachandran
>> ID/Foundation No.: 3416/1234/2 (Foundation Register of Berlin)
>>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/google-appengine/9687fedb-925a-42ef-9c26-439febdf168fn%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/9687fedb-925a-42ef-9c26-439febdf168fn%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA7w%3DYu9dOZ7ChhgE8Bf9Bb%2BjFxoMTsMbuTuHZ7dURqDrw%40mail.gmail.com.


Re: [google-appengine] "Google Cloud API" was not in in "Adding credentials to the project".

2020-08-22 Thread wesley chun
This is the Google App Engine mailing list. To use the PaaS system, you
only need to create a project (which you have already done) then go to
console.cloud.google.com/appengine to create your App Engine app. There's
no need to create credentials or use a "Google Cloud API" unless you know
you need to do so. I suggest installing the Google Cloud SDK (
cloud.google.com/sdk) which provides tools to simplify creating & deploying
your app. To learn more about App Engine, please see
cloud.google.com/appengine for its documentation. If you have any specific
questions, feel free to ask here but paste any specific commands or
screenshots showing where you may have an issue.

Good luck!
--Wesley

On Sat, Aug 22, 2020 at 11:53 AM I snb  wrote:

> In the console of Google cloud platform, I created project name -> Google
> cloud API -> Credentials. However, "Google Cloud API" was not an option in
> "Adding credentials to the project".


- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA5MBEnHCUaq_BodApwc%2BewaJRwduMUtaXLtGGMtZ%3Dg02A%40mail.gmail.com.


Re: [google-appengine] Receiving data from Google Cloud

2020-08-17 Thread wesley chun
GCF on GCP auto-scales (as does GAE & GCR). Each instance only supports one
request at a time. Additional instances will be spun up to support other
concurrent requests. If your function (or app or container) "goes viral,"
GCP automatically handles the traffic for you. However, not everyone has
unlimited budget, so there's a way you can control the max # of instances
spun-up. To learn more about concurrent requests, check out this page in
our documentation: https://cloud.google.com/functions/docs/concepts/exec

On Sun, Aug 16, 2020 at 12:57 AM Vishnu U  wrote:

> Thanks a lot. Now I got an idea on how to proceed. Also please explain to
> me in case there are multiple requests how GCP will handle them - is there
> any load balancer? This is because the project is time-critical.
>
> On Sunday, August 16, 2020 at 1:56:44 AM UTC+5:30, Wesley C (Google) wrote:
>>
>> Ah, great. That was good to know, and yes, you can do it the easiest with
>> Cloud Functions... since you're only serving a model, you don't need an
>> entire app (App Engine). I've not done it myself, but start with this
>> post
>> <https://blog.tensorflow.org/2018/08/training-and-serving-ml-models-with-tf-keras.html>
>> on how to serve models w/tf.keras. Then follow-up with this post
>> <https://cloud.google.com/blog/products/ai-machine-learning/how-to-serve-deep-learning-models-using-tensorflow-2-0-with-cloud-functions>
>> about a year later on how it can be done with Cloud Functions.
>>
>> To quickly learn Cloud Functions, I'll refer to the advice I gave in my
>> 1st response: "You can get started immediately by going to the Cloud
>> console's Cloud Functions dashboard
>> <https://console.cloud.google.com/functions> where you can create, code,
>> deploy, and test your function, all from your browser. The Quickstart
>> sample <https://cloud.google.com/functions/docs/quickstart-python> code
>> is already dropped into the editor and ready for you to modify."
>>
>> Good luck!
>> --Wesley
>>
>>
>> On Fri, Aug 14, 2020 at 11:37 PM Vishnu U  wrote:
>>
>>> My aim is like i want to perform prediction using a Keras saved model.
>>> So I receive two sensor inputs from raspberry pi to Google Cloud and
>>> perform the prediction on the cloud and return that result back to
>>> raspberry pi to make necessary changes. Will cloud functions be suitable
>>> for this?
>>>
>>> On Saturday, August 15, 2020 at 11:59:13 AM UTC+5:30, Wesley C (Google)
>>> wrote:
>>>>
>>>> It's best if you describe your entire architecture then, because I was
>>>> only going on what you stated in your OP... you "have to send data from
>>>> Raspberry Pi to Google Cloud, process it, and receive the result back to
>>>> the same Raspberry Pi." I answered that your use case looks like it fits
>>>> Cloud Functions better than either App Engine or Cloud Run. There was no
>>>> mention of GCS (Cloud Storage) nor Cloud Datastore. As mentioned, you *can*
>>>> use App Engine to get the RaspPI data, process it, and return it, but it
>>>> seems like it would be easier to use Cloud Functions instead to do the same
>>>> thing.
>>>>
>>>> Cloud Functions can take the data, do some processing and return it,
>>>> just like App Engine, but easier. However, if the code that processes this
>>>> data is more complex and is an entire *app* where you have many components
>>>> or need to persist, provide a web UI, etc., then yes, App Engine would then
>>>> be better. Cloud Functions is for serverless unction-hosting in the cloud,
>>>> App Engine is for serverless app-hosting in the cloud, and Cloud Run is for
>>>> serverless container-hosting in the cloud.
>>>>
>>>>
>>>> On Fri, Aug 14, 2020 at 6:22 PM Vishnu U  wrote:
>>>>
>>>>>
>>>>> But my source of data is not any cloud storage or cloud data store.
>>>>> Suppose I received data on app engine from raspberry pi and I perform some
>>>>> calculation and want to return that data. Is this possible?
>>>>> On Sat, 15 Aug 2020 at 6:45 AM, wesley chun  wrote:
>>>>>
>>>>>> While App Engine will serve your needs, based on what you asked,
>>>>>> perhaps Google Cloud Functions <http://cloud.google.com/functions>
>>>>>> would be a simpler solution. You can get started immediately by going to
>>>>>> the Cloud console's Cloud F

Re: [google-appengine] Receiving data from Google Cloud

2020-08-15 Thread wesley chun
Ah, great. That was good to know, and yes, you can do it the easiest with
Cloud Functions... since you're only serving a model, you don't need an
entire app (App Engine). I've not done it myself, but start with this post
<https://blog.tensorflow.org/2018/08/training-and-serving-ml-models-with-tf-keras.html>
on how to serve models w/tf.keras. Then follow-up with this post
<https://cloud.google.com/blog/products/ai-machine-learning/how-to-serve-deep-learning-models-using-tensorflow-2-0-with-cloud-functions>
about a year later on how it can be done with Cloud Functions.

To quickly learn Cloud Functions, I'll refer to the advice I gave in my 1st
response: "You can get started immediately by going to the Cloud console's
Cloud Functions dashboard <https://console.cloud.google.com/functions> where
you can create, code, deploy, and test your function, all from your
browser. The Quickstart sample
<https://cloud.google.com/functions/docs/quickstart-python> code is already
dropped into the editor and ready for you to modify."

Good luck!
--Wesley


On Fri, Aug 14, 2020 at 11:37 PM Vishnu U  wrote:

> My aim is like i want to perform prediction using a Keras saved model. So
> I receive two sensor inputs from raspberry pi to Google Cloud and perform
> the prediction on the cloud and return that result back to raspberry pi to
> make necessary changes. Will cloud functions be suitable for this?
>
> On Saturday, August 15, 2020 at 11:59:13 AM UTC+5:30, Wesley C (Google)
> wrote:
>>
>> It's best if you describe your entire architecture then, because I was
>> only going on what you stated in your OP... you "have to send data from
>> Raspberry Pi to Google Cloud, process it, and receive the result back to
>> the same Raspberry Pi." I answered that your use case looks like it fits
>> Cloud Functions better than either App Engine or Cloud Run. There was no
>> mention of GCS (Cloud Storage) nor Cloud Datastore. As mentioned, you *can*
>> use App Engine to get the RaspPI data, process it, and return it, but it
>> seems like it would be easier to use Cloud Functions instead to do the same
>> thing.
>>
>> Cloud Functions can take the data, do some processing and return it, just
>> like App Engine, but easier. However, if the code that processes this data
>> is more complex and is an entire *app* where you have many components or
>> need to persist, provide a web UI, etc., then yes, App Engine would then be
>> better. Cloud Functions is for serverless unction-hosting in the cloud, App
>> Engine is for serverless app-hosting in the cloud, and Cloud Run is for
>> serverless container-hosting in the cloud.
>>
>>
>> On Fri, Aug 14, 2020 at 6:22 PM Vishnu U  wrote:
>>
>>>
>>> But my source of data is not any cloud storage or cloud data store.
>>> Suppose I received data on app engine from raspberry pi and I perform some
>>> calculation and want to return that data. Is this possible?
>>> On Sat, 15 Aug 2020 at 6:45 AM, wesley chun  wrote:
>>>
>>>> While App Engine will serve your needs, based on what you asked,
>>>> perhaps Google Cloud Functions <http://cloud.google.com/functions>
>>>> would be a simpler solution. You can get started immediately by going to
>>>> the Cloud console's Cloud Functions dashboard
>>>> <https://console.cloud.google.com/functions> where you can create,
>>>> code, deploy, and test your function, all from your browser. The Quickstart
>>>> sample <https://cloud.google.com/functions/docs/quickstart-python>
>>>> code is already dropped into the editor and ready for you to modify.
>>>> Alternatively, if you already have that app you want to call in a Docker
>>>> container, then you should use Google Cloud Run
>>>> <http://cloud.google.com/run> instead. App Engine is best suited for
>>>> normal web apps like Flask or Django.
>>>>
>>>> Hope this helps!
>>>> --Wesley
>>>>
>>>> On Fri, Aug 14, 2020 at 7:28 AM Vishnu U  wrote:
>>>>
>>>>> I am working on a project where I have to send data from Raspberry Pi
>>>>> to Google Cloud, process it, and receive the result back to the same
>>>>> Raspberry Pi. Is this possible using Google App Engine?. If not is there
>>>>> any other service in GCP that can do this functionality?
>>>>>
>>>> --
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <htt

Re: [google-appengine] Receiving data from Google Cloud

2020-08-14 Thread wesley chun
It's best if you describe your entire architecture then, because I was only
going on what you stated in your OP... you "have to send data from
Raspberry Pi to Google Cloud, process it, and receive the result back to
the same Raspberry Pi." I answered that your use case looks like it fits
Cloud Functions better than either App Engine or Cloud Run. There was no
mention of GCS (Cloud Storage) nor Cloud Datastore. As mentioned, you *can*
use App Engine to get the RaspPI data, process it, and return it, but it
seems like it would be easier to use Cloud Functions instead to do the same
thing.

Cloud Functions can take the data, do some processing and return it, just
like App Engine, but easier. However, if the code that processes this data
is more complex and is an entire *app* where you have many components or
need to persist, provide a web UI, etc., then yes, App Engine would then be
better. Cloud Functions is for serverless unction-hosting in the cloud, App
Engine is for serverless app-hosting in the cloud, and Cloud Run is for
serverless container-hosting in the cloud.


On Fri, Aug 14, 2020 at 6:22 PM Vishnu U  wrote:

>
> But my source of data is not any cloud storage or cloud data store.
> Suppose I received data on app engine from raspberry pi and I perform some
> calculation and want to return that data. Is this possible?
> On Sat, 15 Aug 2020 at 6:45 AM, wesley chun  wrote:
>
>> While App Engine will serve your needs, based on what you asked, perhaps 
>> Google
>> Cloud Functions <http://cloud.google.com/functions> would be a simpler
>> solution. You can get started immediately by going to the Cloud
>> console's Cloud Functions dashboard
>> <https://console.cloud.google.com/functions> where you can create, code,
>> deploy, and test your function, all from your browser. The Quickstart
>> sample <https://cloud.google.com/functions/docs/quickstart-python> code
>> is already dropped into the editor and ready for you to modify.
>> Alternatively, if you already have that app you want to call in a Docker
>> container, then you should use Google Cloud Run
>> <http://cloud.google.com/run> instead. App Engine is best suited for
>> normal web apps like Flask or Django.
>>
>> Hope this helps!
>> --Wesley
>>
>> On Fri, Aug 14, 2020 at 7:28 AM Vishnu U  wrote:
>>
>>> I am working on a project where I have to send data from Raspberry Pi to
>>> Google Cloud, process it, and receive the result back to the same Raspberry
>>> Pi. Is this possible using Google App Engine?. If not is there any other
>>> service in GCP that can do this functionality?
>>>
>>
>>>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA4aDtU_Za1ZHkwO_tHnEUzDbKbKnp0ZUcxeOnvsG697NQ%40mail.gmail.com.


Re: [google-appengine] Receiving data from Google Cloud

2020-08-14 Thread wesley chun
While App Engine will serve your needs, based on what you asked, perhaps Google
Cloud Functions <http://cloud.google.com/functions> would be a simpler
solution. You can get started immediately by going to the Cloud console's
Cloud Functions dashboard <https://console.cloud.google.com/functions>
where you can create, code, deploy, and test your function, all from your
browser. The Quickstart sample
<https://cloud.google.com/functions/docs/quickstart-python> code is already
dropped into the editor and ready for you to modify. Alternatively, if you
already have that app you want to call in a Docker container, then you
should use Google Cloud Run <http://cloud.google.com/run> instead. App
Engine is best suited for normal web apps like Flask or Django.

Hope this helps!
--Wesley

On Fri, Aug 14, 2020 at 7:28 AM Vishnu U  wrote:

> I am working on a project where I have to send data from Raspberry Pi to
> Google Cloud, process it, and receive the result back to the same Raspberry
> Pi. Is this possible using Google App Engine?. If not is there any other
> service in GCP that can do this functionality?
>

-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA7sxv%3DgjxHXYPU3W3CcEKyorsF6X7SjMA6ny1aS3nwvog%40mail.gmail.com.


Re: [google-appengine] Re: GCP Access

2020-07-22 Thread wesley chun
Agreed. Never (ever) share login/password information. We are well beyond
those days now with role-based authentication
<https://en.wikipedia.org/wiki/Role-based_access_control> and OAuth2
<https://en.wikipedia.org/wiki/OAuth>.

Furthermore, be aware we have multiple compute options available from GCP
in addition to App Engine. If you're considering what's right for you,
check out this informative animation <https://lnkd.in/gkeT3AW>. I recommend
serverless for cost+convenience, containers for flexibility, and Cloud Run
for both!

Cheers,
 --Wesley


On Wed, Jul 22, 2020 at 12:00 PM 'Charlie Engelke' via Google App Engine <
google-appengine@googlegroups.com> wrote:

> Don't share login information. There's no need. You can create a project,
> then add the developer as a user, or owner, of that project in addition to
> you.
>
> On Wednesday, July 22, 2020 at 1:00:44 AM UTC-7 ki...@douglassoftware.com
> wrote:
>
>> I am a non technical founder, what information do i need to give my
>> developer to be able to upload the code to GCP ? Do I need to just hand
>> over my login info to the developer to be able to upload or is there a way
>> of giving the developer access to the account that I have created ?
>
>
-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA6czrCQw30S6q12N4NO6zWPt4CGDR_9Pc%3DE%3DG7sPaSAuQ%40mail.gmail.com.


Re: [google-appengine] Re: App Engine doesn't downscale when CPU utilisation is below target_utilization

2020-07-20 Thread wesley chun
This question only applies to Flex users
<https://groups.google.com/forum/#!topic/google-appengine/IWNzceG4FxY>.
According to the documentation
<https://cloud.google.com/appengine/docs/flexible/python/reference/app-yaml#updated_health_checks>,
health check HTTP requests are *not* sent to the container, meaning that it
doesn't affect the autoscaling (up or down) to your app like "real" traffic
to your app. The exception is if you "extended" your health checks to your
app by providing a path to the endpoint you wish to be hit when a health
check is performed. I'm sure you also know that Flex requires *at least* 1
instance being up, so it'll never downscale to zero (see this page
<https://cloud.google.com/appengine/docs/flexible/python/flexible-for-standard-users#scaling_characteristics>
regarding scaling, health checks, and other differences b/w standard &
flexible environments.

Hope this helps!
--Wesley

On Sun, Jul 19, 2020 at 4:26 PM tz martin  wrote:

> Does anyone know if potential health check settings (liveness_check or
> readiness_check) are as requests that would prevent downscaling instances?
> Wondering if health check "bursts" would keep one or all instances alive.
>
> On Tuesday, September 3, 2019 at 2:52:21 PM UTC diogoa...@google.com
> wrote:
>
>> You can use the App Engine custom runtime
>> <https://cloud.google.com/appengine/docs/flexible/custom-runtimes/> to
>> deploy an application in any language.
>>
>> I did not find any documents about Angular 8, but as a starting point you
>> could take a look at this tutorial for deploying Angular 6
>> <https://medium.com/@asanoop24/deploying-angular-6-app-on-google-app-engine-b6259d4c16c2>
>> .
>>
>> As not all use cases can be covered in the App Engine documents I
>> recommend you take request development assistance on Stack Overflow
>> <https://stackoverflow.com/questions/39782506/deploying-basic-angular-2-app-to-google-app-engine/50494337#50494337>,
>> where the community of developers will be able to help you with your
>> Angular coding.
>>
>> On Tuesday, September 3, 2019 at 8:54:41 AM UTC-4, chuda mani wrote:
>>>
>>> hi i need a suggestion , i have to deploy angular 8 application with
>>> apache server in gcp app engine..is it possible?..if so please  forward any
>>> reference documents..thank you
>>>
>>
-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA7%3Doqv4FY%2Bb4bvSuoKresHvX%2BJiVS_pnPnXDxUcKLoENw%40mail.gmail.com.


Re: [google-appengine] Re: I'm interested to know more about cloud storage free trail under$300

2020-07-20 Thread wesley chun
Hi Kumar, as a beginner to GCP, I generally recommend *against* using the
free trial when exploring the product group. (BTW, in English, there is a
difference between "trial" and "trail".) As Joseph mentioned, there is
an "Always
Free" tier <https://cloud.google.com/free/docs/gcp-free-tier#always-free>
(multiple
GCP products). This daily/monthly free quota for participating products (1
free VM, 5GB disk storage [US region], 2M Cloud Functions calls, etc.) is
always available to developers. As long as you stay under the quota, you
will never be charged for their use.

I recommend you do NOT use the $300USD Free Trial because of 2 main
reasons: 1) the trial lasts exactly 12 months from when you activate it
(the clock starts ticking immediately) and 2) it is a 1-time offer (can't
get it again). You only incur billing by exceeding the Always Free tier
quotas, meaning you don't "eat into" the $300 until that happens. Do your
due diligence, research which GCP tools to use, and *only activate the Free
Trial when your normal usage on GCP consistently exceeds the Always Free
tier*. Otherwise you're not taking full advantage of the offer.

Good luck!
--Wesley


On Mon, Jul 20, 2020 at 10:53 AM 'noverlyjoseph' via Google App Engine <
google-appengine@googlegroups.com> wrote:

> You will only be charged for what you go over the Free Tier depending on
> the services.
> For Cloud Storage for example, as long as you don't go over the Always
> Free limit in your usage, you will not be charged.
> Here's[1] the Always Free usage limits for Cloud Storage.
> For any other services you will find that information in the Pricing
> section of that Service.
>
>
> [1] https://cloud.google.com/storage/pricing#cloud-storage-always-free
>
>
> On Monday, July 20, 2020 at 8:15:10 AM UTC-4, kumar reddy wrote:
>>
>> I just want to know more about $300 free trail. I i get signed up for
>> $300 free trail, and add credit card details., will i be charged for any
>> charges after i consume the services under that package?. will i have a
>> stop point that allows me to stop using the paid services?
>>
>> My intention is to avoid any kind of charges, and continue with free
>> trail to experience the cloud storage.
>>
>> Thanks,
>> Kumar N.
>>
>
-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun :: @wescpy <http://twitter.com/wescpy> :: Software
Architect & Engineer
Developer Advocate at Google Cloud by day; at night...
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAB6eaA4E6hKUyUqeOgtCBGqOb%3DEwP0k5FubUQ9uP%3Dt1Tmu6_9Q%40mail.gmail.com.


Re: [Tutor] Dave Angel

2015-08-18 Thread wesley chun
I was posting more regularly to Tutor when Dave came around the first time
at the end of March 2009 (first thread here
<https://mail.python.org/pipermail/tutor/2009-March/068227.html> and last
thread from early May
<https://mail.python.org/pipermail/tutor/2015-May/105430.html>). For the 6+
years in between, he has helped many new to Python and new to programming
in general. We are thankful for his contributions and will miss his
presence. RIP Dave Angel.

Regards and respect,
--Wesley

On Tue, Aug 18, 2015 at 12:15 PM, Marc Tompkins 
wrote:

> Thank you very much - and thanks to Dave for his contributions over the
> years.
>
> On Tue, Aug 18, 2015 at 1:49 AM, Alan Gauld 
> wrote:
>
> > Many members of the list will remember Dave Angel as a regular and active
> > participant over many years. However, Dave has not been active on the
> list
> > for a little while.
> >
> > I regret to inform you that Dave passed away at the end of May.
> > There is an obituary here:
> >
> > http://www.monaghanfunerals.com/obits/obituary.php?id=552157
> >
> > I have left a message of condolence on behalf of the tutor list.
> >
> > Alan G.
> > List moderator.
>

-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail : @wescpy
<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] syntax error with raw input

2014-11-12 Thread wesley chun
Slightly hijacking this thread a bit, specifically Alan's reply, if anyone
is averse to installing multiple versions of Python on their computers, you
can always access a Python interpreter from a browser window.

Here are a collection I've put together. Most are Python 2, but the top
pair also support Python 3:

   - http://ideone.com (2.x & 3.x)
   - http://colabv6.dan.co.jp/lleval.html (2.x & 3.x)
   - http://doc.pyschools.com/console
   - http://repl.it/languages/Python
   - http://skulpt.org (pure JS implementation; allows turtle)
   - http://pythonwebconsole.thomnichols.org
   - http://shell.appspot.com (Google App Engine + libraries)
   - http://codepad.org
   - http://lotrepls.appspot.com
   - http://datamech.com/devan/trypython/trypython.py

Cheers,
--Wesley

On Wed, Nov 12, 2014 at 9:11 AM, Alan Gauld 
wrote:

> On 12/11/14 11:08, Vaibhav Banait wrote:
>
>> Hi
>> I am new to python. I learnt (!) using  raw_input a day back. Attempt to
>> use has resulted in error. I am not able to spot a problem in syntax. I
>> am using python 3.4.2. Kindly help
>>
>
> Looks like you are reading a v2 book/tutorial but using v3.
>
> In v3 several key changes were made to Python including the renaming of
> raw_input() to input().
>
> The other big change was making print a function so you now *must* put
> parentheses around anything you want to print.
>
> ie
>
> print 'hello'  # Python v2
>
> becomes
>
> print('hello')   # python v3
>
> There are numerous other small changes so it would be better for you to
> either find a v3 tutorial (you could try mine! :-) or install Python v2.7
> while you are learning.
>
>
> --
> Alan G
> Author of the Learn to Program web site
> http://www.alan-g.me.uk/
> http://www.flickr.com/photos/alangauldphotos
>
>
> ___
> Tutor maillist  -  Tutor@python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
>



-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail : @wescpy
<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] “has a value of True” versus “evaluates true” (was: don't understand iteration)

2014-11-10 Thread wesley chun
good catch, and definitely a distinction beginners should be more cognizant
of.

it's also good to recognize that a call to "bool(match)" would render that
statement correct, as the built-in/factory function will return what an
object evaluates to (True [re.match object] or/vs.False [None]).

On Mon, Nov 10, 2014 at 5:31 PM, Clayton Kirkwood 
wrote:

> I reported it. I feel all grown up now. Kind of like one of the
> boys(girls...)
>
> Clayton:<)
>
>
> >-Original Message-
> >From: Tutor [mailto:tutor-bounces+crk=godblessthe...@python.org] On
> >Behalf Of Ben Finney
> >Sent: Monday, November 10, 2014 3:24 PM
> >To: tutor@python.org
> >Subject: [Tutor] “has a value of True” versus “evaluates true” (was:
> >don't understand iteration)
> >
> >"Clayton Kirkwood"  writes:
> >
> >> Also of confusion, the library reference says:
> >>
> >> Match objects always have a boolean value of True. Since match() and
> >> search() return None when there is no match, you can test whether
> >> there was a match with a simple if statement:
> >>
> >> match = re.search(pattern, string)
> >> if match:
> >> process(match)
> >
> >The documentation is incorrect, as you point out: “have a boolean value
> >of True” implies that the value is identical to the built-in ‘True’
> >constant, which is never the case for these objects.
> >
> >Instead, the passage above should say “evaluates true in a boolean
> >context”.
> >
> >Would you be so kind as to report a bug to that effect
> >http://bugs.python.org/>?
> >
> >--
> > \   “The Vatican is not a state.… a state must have people. There |
> >  `\are no Vaticanians.… No-one gets born in the Vatican except by |
> >_o__)an unfortunate accident.” —Geoffrey Robertson, 2010-09-18 |
> >Ben Finney
> >
> >___
> >Tutor maillist  -  Tutor@python.org
> >To unsubscribe or change subscription options:
> >https://mail.python.org/mailman/listinfo/tutor
>
>
> ___
> Tutor maillist  -  Tutor@python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
>



-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail : @wescpy
<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] Python open source for beginners

2014-07-16 Thread wesley chun
> I am learning Python 3 for fun and as hobby.  I am experienced in C#,
> ASP.Net.  I want to gain more knowledge in Python.  Can somebody
> please suggest open source projects/sites?


Greetings Mitesh, and welcome to Python!

Others will have more advice to give on specific projects, but I would
initially suggest: 1) http://python.org which is the main website for the
open source language -- it has all the docs and a beginners' tutorial, 2)
http://ironpython.net which is the website for IronPython, the open source
version of Python implemented for .NET, an area that you're familiar with,
and where you may feel more comfortable joining the Python world. Finally,
3) http://sf.net/projects/pywin32 -- this is the Python Extensions for
Windows library which allows you to create apps using the MFC library,
including COM clients.

As you start coding and running into issues/problems, feel free to drop by
and ask your questions here along with a description of what you tried,
what didn't work, and what was the output and/or stack trace that you got.

Best of luck!
--Wesley

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail : @wescpy
<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] Python 2 Vs python 3

2014-07-15 Thread wesley chun
*> From:* idiallo.s...@gmail.com
*> Sent:* Sunday, July 13, 2014 9:16 AM
*> To:* Python Tutor Mailing List
*> Subject:* [Tutor] Python 2 Vs python 3

>
> I am in the process to dive into python and start learning it. But most
books
> advice to install python 2 instead of ‎python 3. Any advice from the ones
with
> the experiences and what is the main difference?



Everyone's given good reasons for each version and where to start. This, as
you can imagine, is also an FAQ which is asked several times a year, so it
may also be worthwhile to search the archives to see what has been said in
the past.

I also answered this question on Quora
<http://www.quora.com/Python-programming-language-1/As-someone-interested-in-learning-Python-should-I-start-with-2-x-or-go-straight-to-3-x/answer/Wesley-Chun>and
provided several references as well as a few talks I've given in the past
on the subject.

Cheers,
-- Wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail : @wescpy
<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] how do I set variables in Python 3.4

2014-07-14 Thread wesley chun
Greetings Danielle,

Welcome to programming! Thanks for the additional clarification as to what
your project is. Starting from scratch isn't easy, but with a little bit of
guidance, you'll soon be able to "drive on your own!"

In the course you're taking, can you share a bit about what resources your
instructor has provided you? Is there a book or an online website that
you're using? From looking at the code you've created, it seems that you're
trying to just take the requirements and hoping that it matches with the
languages syntax. Because it does *not*, the Python interpreter cannot
figure out what you're trying to do.

The solution is to learn the language that the Python interpreter is
"speaking," and converse in that language to help you meet your goal. For
example, the book or website that you're using should be indicating that
when the requirement is: "Set operand1 = 2 and operand2 = 7," this does not
mean that 'set "(operand1 = 2 and operand2 = 7)"' is what you would do in
Python.

The reading should have told you that "set" is not a keyword in Python.
Instead, you would think, "I need to set these variables... how do I do
that?" In your study guide, you would then find something like: "In order
to assign a value to a variable in Python, for example, to assign the
integer 10 to the variable 'x', the correct syntax is: x = 10". You then
bring that back to your example and do something similar: "operand1 = 2".

In fact, all of us here on the mailing list would go a step further and ask
you to experiment, like set the variable and then display it, and to
cut-n-paste the output here so we can confirm you know how to do it, and
that it works:

>>> operand1 = 2
>>> print(operand1)
2
>>> print(1 + operand1)
3

Once you've gained some confidence, you can then do the same for operand2,
and after this, go back to your learning resource and learn how to add,
subtract, etc. The best part is that you only have to learn these steps
once. The rules don't change for this aspect of programming in Python, and
you can then go ahead and complete your assignment. The most important
thing is to reference your learning resource and not to guess based on the
requirements in the assignment. Check out all the examples and model your
solution after them.

Best of luck!
--Wesley


On Mon, Jul 14, 2014 at 10:51 PM, Danielle Salaz 
wrote:

> This is the assignment:
>
> Write a Python script as follows:
>
>
>
> Use 3 variables named:
>
>operand1
>
>operand2
>
>result
>
> Set operand1 = 2 and operand2 = 7.
>
>
>
> Evaluate the following expressions and produce the output as shown:
>
>result = operand1 + operand2
>
>result = operand2 – operand1
>
>result = operand2 * operand1
>
>result = operand2 / operand1
>
>result = operand2 % operand1
>
>
>
> Your output should look like:
>
>
>
>operand1 = 2
>
>operand2 = 7
>
>2 + 7 = 9
>
>7 – 2 = 5
>
>7 * 2 = 14
>
> etc.
>
>
> I am using Python 3.4 and my OS is Windows 7 Ultimate.
> Thank you everyone for all of your help
>
>
> On Sun, Jul 13, 2014 at 10:41 AM, Danny Yoo 
> wrote:
>
>> On Sun, Jul 13, 2014 at 12:25 AM, Danielle Salaz 
>> wrote:
>> > This is what I've been doing, also I'm using version 3.4
>> >
>> > set "(operand1 = 2 and operand2 = 7)
>> > print (operand1 = 2)
>> > print (operand2 = 7)
>> > print (result=operand1 + operand2)
>> > print (result=operand2 - operand1)
>> > print (result=operand2 * operand1)
>> > print (result=operand2 / operand1)
>> > print (result=operand2 % operand1)
>>
>>
>> Beyond what Alan has said, also please also also say what you expected
>> to happen if the program were to run without error.
>>
>> I mentioned this earlier in a prior reply in this thread, and I still
>> stick by the recommendation.  We want to help troubleshoot any
>> misconceptions as early as possible, and knowing intent is helpful.
>>
>> Since you are a beginner, try to explain each line and the overall
>> program goal if possible.  It will help us understand what programming
>> model you've got in your head.  For example, can you explain what the
>> first three lines of your program are intended to do?
>>
>
>
>
> --
> Thank you,
> Danielle Salaz
> Signature Financial Services, Inc.
> 21 W. Laurel Dr. #47, Salinas, Ca. 93906
> (831) 754-0600
>
> Your perception has everything to do with your progression!!

Fwd: ANN: Intro+Intermediate Python, San Francisco, Jul 30-31, Aug 1

2014-06-11 Thread wesley chun
Greetings!

I'll be offering another hardcore Python course this summer near the
San Francisco airport. If you're somewhat new to or have some Python
experience under your belt already but want to fill-in the holes,
this course is for you. Why take a real course when you can learn
Python online or by reading books?

Well, my goal isn't to teach Python syntax, which you can from any
teacher, live or online, or from giant books. My job is to create
great Python developers and removing the roadblocks that impede
your path to getting there. This intensive course is based on my
 "Core Python" (http://corepython.com) books and is made up of 3
full days complete with lectures and several hands-on coding labs
per day. t's also a great excuse to coming to beautiful Northern
California for a summer vacation!

Groups and development teams are welcome as well as individuals. I do
more private gigs and fewer of these public courses lately, so please
come join if you can... my next public intro/intermediate course may
not be for awhile, so I'm hoping to meet some of you this time around!

Sign up soon... there's a special earlybird rate for the rest of this
month before going up to the regular rate after that. More details and
registration at http://cyberwebconsulting.com as well as in the ad:
http://goo.gl/pyJseQ

I'm no fan of spam, so I'll only send out one last reminder as the
date gets closer... say around the end of June.

Cheers,
-- Wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail :
@wescpy<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
-- 
https://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


Re: [Tutor] I am having difficulty grasping 'generators'

2014-05-28 Thread wesley chun
I'm not going to add too much more to all the replies here already, but one
of my students did record a quick <6-minute video in one of my courses
where i explained generators. hopefully you find it useful!

It's about halfway down the page at http://cyberwebconsulting.com. (Also
for those learning Python and in the San Francisco area, I'm offering
another intensive 3-day course mid-summer -- more info on the same page.
Ping me privately for more details or if you have questions!)

Cheers,
--Wesley


On Tue, May 27, 2014 at 12:27 PM, Degreat Yartey
wrote:

> I am studying python on my own (i.e. i am between the beginner and
> intermediate level) and i haven't met any difficulty until i reached the
> topic 'Generators and Iterators'.
> I need an explanation so simple as using the expression 'print ()', in
> this case 'yield'.
> Python 2.6 here!
> Thank you.
>
> ___
> Tutor maillist  -  Tutor@python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
>
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail :
@wescpy<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor


[portland] Fwd: ANN: Intro+Intermediate Python, San Francisco, Jul 30-31, Aug 1

2014-05-13 Thread wesley chun
Greetings!

I'll be offering another hardcore Python course this summer near the
San Francisco airport. If you're somewhat new to or have some Python
experience under your belt already but want to fill-in the holes,
this course is for you. Why take a real course when you can learn
Python online or by reading books?

Well, my goal isn't to teach Python syntax, which you can from any
teacher, live or online, or from giant books. My job is to create
great Python developers and removing the roadblocks that impede
your path to getting there. This intensive course is based on my
 "Core Python" (http://corepython.com) books and is made up of 3
full days complete with lectures and several hands-on coding labs
per day. t's also a great excuse to coming to beautiful Northern
California for a summer vacation and just a 1-hour flight from PDX!

Groups and development teams are welcome as well as individuals. I do
more private gigs and fewer of these public courses lately, so please
 come join if you can... my next public intro/intermediate course may
not be for awhile, so I'm hoping to meet some of you this time around!

Sign up soon... there's a special earlybird rate for the rest of this
month before going up to the regular rate after that. More details and
registration at http://cyberwebconsulting.com as well as in the ad:
http://goo.gl/pyJseQ

I'm no fan of spam, so I'll only send out one last reminder as the
date gets closer... say around the end of June.

Cheers,
-- Wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail :
@wescpy<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
-- next part --
An HTML attachment was scrubbed...
URL: 
<http://mail.python.org/pipermail/portland/attachments/20140513/5bbf984c/attachment.html>
___
Portland mailing list
Portland@python.org
https://mail.python.org/mailman/listinfo/portland


ANN: Intro+Intermediate Python, San Francisco, Jul 30-31, Aug 1

2014-05-13 Thread wesley chun
Greetings!

I'll be offering another hardcore Python course this summer near the
San Francisco airport. If you're somewhat new to or have some Python
experience under your belt already but want to fill-in the holes,
this course is for you. Why take a real course when you can learn
Python online or by reading books?

Well, my goal isn't to teach Python syntax, which you can from any
teacher, live or online, or from giant books. My job is to create
great Python developers and removing the roadblocks that impede
your path to getting there. This intensive course is based on my
"Core Python" (http://corepython.com) books and is made up of 3
full days complete with lectures and several hands-on coding labs
per day. t's also a great excuse to coming to beautiful Northern
California for a summer vacation!

Groups and development teams are welcome as well as individuals. I do
more private gigs and fewer of these public courses lately, so please
come join if you can... my next public intro/intermediate course may
not be for awhile, so I'm hoping to meet some of you this time around!

Sign up soon... there's a special earlybird rate for the rest of this
month before going up to the regular rate after that. More details and
registration at http://cyberwebconsulting.com as well as in the ad:
http://goo.gl/pyJseQ

I'm no fan of spam, so I'll only send out one last reminder as the
date gets closer... say around the end of June.

Cheers,
-- Wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail :
@wescpy<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
-- 
https://mail.python.org/mailman/listinfo/python-list


[Tutor] OT: supporting Python & the PSF with a half/quarter-page ad?

2014-02-26 Thread wesley chun
Hey everyone,

This is somewhat off-topic for this list, but if you've gotten a lot out of
Python and want to contribute, the Python Software Foundation is advocating
for the language by creating and distributing a
brochure<http://brochure.getpython.info/>that talks all about the
goodness of Python. For the first run, they're
making "10,000 copies which the PSF will then distribute to user groups,
Python conferences and educational institutions on request and free of
charge."

If your company is interested in supporting the project and want to
advertise in it but find the half-page ad cost prohibitive at EURO 2650
(~$3636) or the 3-line reference ad listing at EURO 500 (~$686) too small, let
me know. I'm willing to split the cost of the ad (creating 2 quarter-page
ads).. the PSF organizer of the brochure suggested this as an alternative,
so now I want to see if any of you or your companies want to participate.
The full details can be found here<http://brochure.getpython.info/sponsorship>
.

The deadline is this Fri, Feb 28, so please get back to me by tomorrow
privately... thanks!
-- Wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail :
@wescpy<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor


Re: [Python-authors] Python 101 - the book

2014-02-22 Thread wesley chun
i did one years ago:

   - EuroPython 2011 talk description +
video<https://ep2013.europython.eu/conference/talks/writing-books-using-python-open-source-software>
   - OSCON 2009 slide
deck<http://cdn.oreillystatic.com/en/assets/1/event/27/Writing%20Books%20using%20Open%20Source%20Software%20Presentation.pdf>

cheers, and good luck!
--wesley


On Sat, Feb 22, 2014 at 9:10 AM, Mike Driscoll wrote:

> Hi Doug,
>
> I'm not only going to blog about the progress, but also about the process
> itself. There isn't enough information out there about how to write books
> using Python tools.
>
> - Mike
>
>
> On Sat, Feb 22, 2014 at 9:55 AM, Doug Hellmann wrote:
>
>> What a great idea! I hope you'll blog about your progress.
>>
>>  Doug
>>
>> On Feb 19, 2014, at 10:56 AM, Mike Driscoll 
>> wrote:
>>
>> Hi,
>>
>> I've mentioned I'm working on a book on this list a few times. Well I've
>> gotten over a dozen chapters written and I've started a Kickstarter for the
>> project that I thought I'd share:
>>
>> http://kck.st/1kX98BB
>>
>> Authoring a book is a lot of fun and a lot of work. Thanks for all the
>> help you all have given me!
>>
>>  Mike
>>
>> P.S. I may ask more questions later!
>> ___
>> Python-authors mailing list
>> Python-authors@python.org
>> https://mail.python.org/mailman/listinfo/python-authors
>>
>>
>>
>> ___
>> Python-authors mailing list
>> Python-authors@python.org
>> https://mail.python.org/mailman/listinfo/python-authors
>>
>>
>
>
> --
> -
> Mike Driscoll
>
> Blog:   http://blog.pythonlibrary.org
>
> ___
> Python-authors mailing list
> Python-authors@python.org
> https://mail.python.org/mailman/listinfo/python-authors
>
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail :
@wescpy<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Python-authors mailing list
Python-authors@python.org
https://mail.python.org/mailman/listinfo/python-authors


Re: [Tutor] Regarding Exceptions

2014-02-21 Thread wesley chun
On Mon, Feb 17, 2014 at 3:29 AM, Khalid Al-Ghamdi 
wrote:
Hi, in the following snippet, why is it I don't need to create an Exception
object and I can use the class directly in raise my custom exception?

here's a new one... i'm going to try to answer this question without
working code since everyone has pointed out it won't compile. the OP is
simply asking why Exception didn't need to be defined before using, as with
all Python variables... IOW, why doesn't it give a NameError exception here?

the reason is because Exception is a built-in, meaning that it's C code
that's been made available for you before your Python code executes. look:

>>> Exception


in reality, built-ins are part of a magical module called __builtins__
that's "automagically" imported for you so that you never have to do it
yourself. check this out:

>>> __builtins__.Exception


you can also find out what all the other built-ins are using dir():
>>> dir(__builtins__)
['ArithmeticError', 'AssertionError', 'AttributeError',...]

hope this helps!
--wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun : wescpy at gmail : @wescpy
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] How to correct decimal addition.

2014-01-24 Thread wesley chun
hi leon,

you made a good start and ran into something that i know doesn't seem right
to you. however, before we attack the issue, there are some basic problems
with the code you need to correct first. below are a few explanations and
perhaps workarounds:

   1. you're passing in price *and* asking the user for it... pick one, not
   both
   2. i'll assume you did *not* mean to pass it in for the rest of this
   response
   3. the == should be a single = otherwise you should get a NameErrorexception
   4. the return price + .09 should be indented on the next line
   5. the operation price + .09 should fail with a TypeError exception
   6. the value .09 is incorrect for the solution you're describing...
   choose another
   7. assuming you fix all of the problems above and run it, you'll still
   get the output you stated
   8. however, if you print the value, it'll show correctly
   9. if you use Python 2.7.x+ or 3.1.x+, it'll show correctly
   10. reference link 1 to review:
   http://docs.python.org/tutorial/floatingpoint
   11. reference link 2 to review: http://bugs.python.org/issue1580

hope this helps!
--wesley


On Fri, Jan 24, 2014 at 9:57 AM, Leon S  wrote:

> Here is what I'm trying to do, accept a price of gas, but I want to add
> the .009 to the price, so that people do not have to type the full amount.
>  Example, 3.49 /gallon would return 3.499 /gallon.
>
> This is what I have tried and the results of it.
>
> def gas_price(price):
>price == raw_input("What is the price of gas?")  return price + .09   
> 3.49=> 3.4898
>
>
> It reduces the number and then adds many decimal points after.
>
>
> Thanks for any help, I am sure this is an easy one for someone.
>
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail :
@wescpy<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] List Python Question..Please help

2013-09-27 Thread wesley chun
hello,

well, i have to say that you've at least made a good start at a solution.
right now you're thinking about it very much like a human. try to put
yourself into the shoes of a computer: how can we solve this task for just
ONE name?

once you have that solution, then you can apply the same solution for all
names by looping over or iterating through them. in your solution, you
tried to do everything at once using brute force.

i recommend you take the lessons learned you borrow some of that code and
solve it for a single name. for example, take a look at this pseudocode:

name = 'Guido'
if name first letter == name last letter: # turn this into real Python
using what you have
print 'match'
else:
print 'not a match'

then add the collection and a loop, and you'll be at your solution!

best of luck!
--wesley


On Fri, Sep 27, 2013 at 10:04 AM, Jacqueline Canales  wrote:

> composers = ['Antheil', 'Saint-Saens', 'Beethoven', 'Easdale', 'Nielsen']
> x = 'Antheil'
> s = 'Saint-Saens'
> h = 'Beethoven'
> y = 'Easdale'
> k = 'Nielsen'
>
> if s[0] == 'S' or s[0] == 's' == s[-1] == 'S' or s[-1] == 's':
> if y[0] == 'E' or y[0] == 'e' == y[-1] == 'E' or y[-1] == 'e':
> if k[0] == 'N' or k[0] == 'n' == k[-1] == 'N' or k[-1] == 'n':
> print(s,k,y)
> else:
> print(" ")
>
> Answer i Got Below
> >>>
> Saint-Saens Nielsen Easdale
> >>>
>
> Is this what i was going for in the direction i was a bit confused if we
> were suppose create loops or if statements that are verified in the actual
> composers list. I don't know i feel as if i know what i need to do i just
> cant put it together.
>
>
> On Fri, Sep 27, 2013 at 3:14 AM, 罗彭  wrote:
>
>> Maybe the length of each name matters, too. You should consider whether
>> to skip null('') and single-character('a').
>>
>>
>> On Fri, Sep 27, 2013 at 3:57 PM, Dharmit Shah wrote:
>>
>>> Also, comparison is case sensitive. Meaning, 'A' and 'a' are not the
>>> same.
>>>
>>> Hope that helps. :)
>>>
>>> On Fri, Sep 27, 2013 at 1:14 PM, Amit Saha 
>>> wrote:
>>> > On Fri, Sep 27, 2013 at 3:48 PM, Jacqueline Canales
>>> >  wrote:
>>> >> So I have been trying to do this program using ifs and or loops.
>>> >> I am having a hard time solving this question, If you could please
>>> assist me
>>> >> in the right direction.
>>> >>
>>> >> Write a program that lists all the composers on the list ['Antheil',
>>> >> 'Saint-Saens', 'Beethoven', 'Easdale', 'Nielsen'] whose name starts
>>> and ends
>>> >> with the same letter (so Nielsen gets lsited, but Antheil doesn't).
>>> >>
>>> >> I know below it prints the entire list of composers but i dont know
>>>  how to
>>> >> do the program above. I think I am thinking to much into but ive
>>> looked at
>>> >> all my notes and online resources and having a hard time coming up
>>> with
>>> >> anything.
>>> >> Please help!
>>> >>
>>> >> composers = ['Antheil', 'Saint-Saens', 'Beethoven', 'Easdale',
>>> 'Nielsen']
>>> >> for person in composers:
>>> >> print(person)
>>> >
>>> > So, here you are printing every compose as you rightly state above.
>>> > What you now need to do is:
>>> >
>>> > For each of the composers (`person'), you need to check if the first
>>> > letter and the last letter are the same. Here;s a hint:
>>> >
>>> >>>> s='abba'
>>> >
>>> > The first letter:
>>> >
>>> >>>> s[0]
>>> > 'a'
>>> >
>>> > The last letter:
>>> >
>>> >>>> s[-1]
>>> > 'a'
>>> >
>>> >
>>> > If you now compare these, you will know if they are the same and hence
>>> > you print him/her.
>>> >
>>> > Hope that helps.
>>> > -Amit
>>>
>>
-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail :
@wescpy<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor


Re: [SEAPY] Python Web app

2013-05-10 Thread wesley chun
There is no Drive API for getting your code into Google Project Hosting as
the authorization schemes are different. Drive uses OAuth2 while Project
Hosting uses passwords.

As mentioned before, you have access to multiple source control systems. If
you still wish to do it via command-line, the team has provided a Python
script that uploads files for you:
https://code.google.com/p/support/wiki/ScriptedUploads

Cheers,
--Wesley



On Fri, May 10, 2013 at 7:20 PM, Christopher Barker wrote:

> I haven't seen an API for Google Code, but not sure you need one -- it
> already supports Subversion <http://subversion.apache.org/>,  
> Mercurial<http://www.selenic.com/mercurial/>
>  and Git <http://git-scm.com/>.
>
> What else would you want to do?
>
> -Chris
>
>
> On Fri, May 10, 2013 at 6:36 PM, David Goldsmith 
> wrote:
>
>> I just asked on stackoverflow about Google App Engine Python support for
>> interacting with Google Code Project Hosting:
>>
>> http://stackoverflow.com/q/16492873/2371879
>>
>> Please answer there if you know about this.  Thanks!
>>
>> OlyDLG
>>
>
>
>
> --
> Christopher Barker, PhD
>
> Python Language Consulting
>   - Teaching
>   - Scientific Software Development
>   - Desktop GUI and Web Development
>   - wxPython, numpy, scipy, Cython
>



-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun <http://google.com/+WesleyChun> : wescpy at gmail :
@wescpy<http://twitter.com/wescpy>
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com


Re: [Tutor] Why do sets use 6 times as much memory as lists?

2013-05-07 Thread wesley chun
Following Oscar's comment, It's also O(n) vs. O(1) tradeoff.

--wesley


On Tue, May 7, 2013 at 12:09 PM, Oscar Benjamin
wrote:

> On 7 May 2013 19:09, Bjorn Madsen  wrote:
> > Hi, Thanks for the quick response.
> >
> > "Being curious" I actually expected something like this:
> >>>> L={x:None for x in range(1)}
> >>>> sys.getsizeof(L)
> > 196660
> >>>>
> >
> > That is why I wondered why 6 times is a lot given that a dict can do the
> > same at 3/4 of the mem-footprint.
> > Just got surprised about the overhead as "sets" some are more lightweight
> > than dictionaries.
>
> I think that the 3/4 is pretty much random. sets and dicts resize
> peroidically depending on how they are used.
>
> > additional overhead must have something to do with set-specific
> operations,
> > I imagine such as:
> > set1 - set2
> > set | set2
> > set1 & set2
> > set1 <= set2
> > 
>
> I don't think so. Here's the results on a 64-bit Linux machine (Python
> 2.7):
> >>> import sys
> >>> sys.getsizeof([x for x in range(1)])
> 87632
> >>> sys.getsizeof({x for x in range(1)})
> 524520
> >>> sys.getsizeof({x: None for x in range(1)})
> 786712
>
> So in this case the set ends up being 2/3 the size of the dict. As I
> said before these results will not be consistent from one computer to
> another.
>
>
> Oscar
> _______
> Tutor maillist  -  Tutor@python.org
> To unsubscribe or change subscription options:
> http://mail.python.org/mailman/listinfo/tutor
>



-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun : wescpy at gmail : @wescpy
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] if/else option for making a choice

2013-02-18 Thread wesley chun
> in your situation, i think it would be more "Pythonic" to maintain the

> > extras as a vector of options and prices. you then loop through those,
> > prompting the user to enter Yes or No, and add either the cost or zero,
> > respectively. that will help keep your code less complex as well. you
> > would
> > just be maintaining a running total until the user is done with all their
> > selections.
> >
> > good luck!
> > -- wesley
>
> I'd be interested in knowing exactly what you mean by the term "vector" in
> the above discussion.  When I saw the problem I thought dict would serve
> as in
>
> options = { "leather" : 1600, "alloy_wheels" : 1200,
> # and so on
> }



perfectly fine if order doesn't matter. if it does, then a tuple will serve
a similar purposes however, it's easy to move back-n-forth between either
via dict(), dict.items(), iter/zip(), etc.

cheers,
-- wesley

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun : wescpy at gmail : @wescpy
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] if/else option for making a choice

2013-02-18 Thread wesley chun
On Mon, Feb 18, 2013 at 10:22 AM, Niclas Rautenhaus wrote:

> Hello folks,
>
> ** **
>
> I would be very pleased if someone is able to help me.
>
> I wrote a small programm, to calculate the grand total for a car.
>
> A basic price can be entered. Given that basic price, a tax peercentage is
> calculated and added tot he grand total.
>
>
> But unfortunately I am stuck with giving the user the choice to select an
> additional option!
> The extra items have got set values, but at the moment they all get
> summarized, but i want to choose.
>
> **
>


greetings Niclas, and welcome to Python! while i'll let the others comment
on your code specifically, i can give some overall suggestions/guidance.

you're trying to create an overall price calculator correct? while it's
straightforward providing a base price, the complexity in your app (and
real life) is the set of options that customers can choose from.

in your situation, i think it would be more "Pythonic" to maintain the
extras as a vector of options and prices. you then loop through those,
prompting the user to enter Yes or No, and add either the cost or zero,
respectively. that will help keep your code less complex as well. you would
just be maintaining a running total until the user is done with all their
selections.

good luck!
-- wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun : wescpy at gmail : @wescpy
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] If a method has no return type?

2013-02-06 Thread wesley chun
On Thu, Feb 7, 2013 at 12:09 AM, Sunil Tech  wrote:

> If a method has no return type?
> what will it return?
>

note the original question is partially invalid... Python functions and
methods aren't typed. however, i imagine the OP really meant *return value*
instead, so the answer is really the following:
functions *and* methods with no explicit return *value* return None... this
happens when you either have no return statement or just return by itself
with no object given.

one exception is __init__()... you're never supposed to return anything
from it... ever. i can't think of any others... can you?

best regards,
-- wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun : wescpy at gmail : @wescpy
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] Python books

2012-11-09 Thread wesley chun
there is no one single book that has all you're seeking, however you can
probably find one or two that may suit your fancy in these Python reading
lists that i made earlier this year: http://goo.gl/i4u0R

note that the 3rd set of books are some of the references that you're
seeking.

best of luck!
--wesley


On Fri, Nov 9, 2012 at 5:18 PM, Ed Owens  wrote:

> I've been trying to learn Python, writing a Blackjack program. Seems
> that's a common problem for learning.  I'm not in a class or school, just
> working on my own.  I've been working in Python 2.7, and considering moving
> up to 3.x.  My programming background is ancient, having done most of my
> programming in FORTRAN. I have been using free internet resources to learn,
> mostly Google searches on syntax, and their free courses.
>
> I have the basic game done: dealing from a shoe of multiple decks, splits,
> betting, etc.  and started to work on the harder parts such as graphics of
> the table with cards, managing record keeping, and so on.  There seem to be
> a plethora of packages and options, many of them outside of the "standard"
> Python installation.  Plus, I'm still discovering how to do things with the
> standard library.  I need more structure and organization!
>
> I have one book, "Python Programming for the Absolute Beginner" by Dawson,
> which is too plodding. Can you experts recommend a Python library?  I would
> like to have:
>
> A command reference for the basic library.
> A comprehensive "How to" course for the basic library.
> Graphics in Python
> Data Management in Python
> Using the internet with Python
> (maybe Real Time(ish) Python)
> A comprehensive "Learn Python" course that puts all this together
>
> I realize that this is outside of the "help with this code" request, but I
> would value your advice.
>
> Ed O
>
>
> __**_
> Tutor maillist  -  Tutor@python.org
> To unsubscribe or change subscription options:
> http://mail.python.org/**mailman/listinfo/tutor<http://mail.python.org/mailman/listinfo/tutor>
>



-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun : wescpy at gmail : @wescpy
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


[Edu-sig] Computer Science Education Week (2012 Dec 9-13)

2012-10-18 Thread wesley chun
folks who are doing events/activities for CSEd week should post them up to
the main website (there's only 2 thus far). while i'm available to give a
session (talk or codelab) for any events close to where i'm based (silicon
valley), i don't have the bandwidth to organize an entire event.
anyway, the standard pitch is given below.

cheers,
--wesley


Computer Science Education Week  <http://www.csedweek.org/> (December 9-13,
2012)  is about celebrating and creating visibility for the importance of
K-12 computer science education.  Although the advocacy work is US-focused, the
celebration includes events and activities from all around the world.

Many teachers engage students in special CS-related activities during
CSEdWeek itself, but CS-related activities take place all year long, and
CSEdWeek strives to recognize and celebrate them all.  To do this, we
invite you to pledge
support<http://www.csedweek.org/forms/sign/pledge-step1> for
CSEdWeek and post CS-related K-12 activities on the CSEdWeek web site.

The more events we show, the better equipped we'll be to make the case that
CS education is vitally important and deserves local, national, and
international support!

Please note that contact information is input in Step 1 and in Step 2 you
will be invited to add your event or other outreach activity.
http://www.csedweek.org/forms/sign/pledge-step1

-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun : wescpy at gmail : @wescpy
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig


Re: [Tutor] combining c and python

2012-09-18 Thread wesley chun
another option that no one has mentioned yet is the use of 'ctypes'
with existing C libraries: http://docs.python.org/library/ctypes

cheers,
-- wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun : wescpy at gmail : @wescpy
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [portland] ANN: Intro+Intermediate Python, San Francisco, Aug 1-3

2012-07-12 Thread wesley chun
hello everyone, hope some of you enjoyed #EuroPython last week/end,
and perhaps i'll see some of you at OSCON next week!

as promised, here's the one and only FINAL REMINDER of the hardcore
intro+intermediate Python course i'm offering 2012 Aug 1-3 near the
San Francisco airport. reach out to me directly with any questions and
let other folks know who may be interested.

much appreciated!
--wesley


On Thu, May 10, 2012 at 11:16 AM, wesley chun  wrote:
> Greetings!
>
> I'll be doing a(nother) hardcore Python course this summer near the San
> Francisco airport. If you're somewhat new to Python or have tinkered but
> want to fill-in the holes, this course is for you. It's somewhat true
> you can learn Python online, watching videos, or reading books, but it
> still takes time and experience to master... I help accelerate this
> process. The course is based on my bestselling "Core Python" books and
> is made up of 3 full days complete with lectures and three hands-on
> coding labs per day.
>
> Please pass on this message to your colleagues who also need to learn
> Python. It's also a great excuse to coming to beautiful Northern
> California for a summer vacation! More details at http://goo.gl/uW4oF
> as well as the links in my .signature below.
>
> Since I hate spam, I'll only send out one more reminder as the date
> gets closer... probably around OSCON's timeframe.


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun : wescpy at gmail : @wescpy
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
___
Portland mailing list
Portland@python.org
http://mail.python.org/mailman/listinfo/portland


Re: [SEAPY] ANN: Intro+Intermediate Python, San Francisco, Aug 1-3

2012-07-12 Thread wesley chun
hello everyone, hope some of you enjoyed #EuroPython last week/end,
and perhaps i'll see some of you at OSCON next week down in PDX!

as promised, here's the one and only FINAL REMINDER of the hardcore
intro+intermediate Python course i'm offering 2012 Aug 1-3 near the
San Francisco airport. reach out to me directly with any questions and
let other folks know who may be interested.

much appreciated!
--wesley


On Thu, May 10, 2012 at 11:09 AM, wesley chun  wrote:
> Greetings!
>
> I'll be doing another hardcore Python course this summer in the San
> Francisco area. If you're somewhat new to Python or have tinkered but
> want to fill-in the holes, this course is for you. It's somewhat true
> you can learn Python online, watching videos, or reading books, but it
> still takes time and experience to master... I help accelerate this
> process. The course is based on my bestselling "Core Python" books and
> is made up of 3 full days complete with lectures and three hands-on
> coding labs per day.
>
> Please pass on this message to your colleagues who also need to learn
> Python. It's also a great excuse to coming to beautiful Northern
> California for a summer vacation! More details at http://goo.gl/uW4oF
> as well as the links in my .signature below.
>
> Since I hate spam, I'll only send out one more reminder as the date
> gets closer... probably around OSCON's timeframe.


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
+wesley chun : wescpy at gmail : @wescpy
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com


Re: ANN: Intro+Intermediate Python, San Francisco, Aug 1-3

2012-07-10 Thread wesley chun
hello everyone, hope some of you enjoyed #EuroPython this past
week/end, and perhaps i'll see some of you at OSCON next week!

as promised, here's the one and only FINAL REMINDER of the hardcore
intro+intermediate Python course i'm offering 2012 Aug 1-3 near the
San Francisco airport. reach out to me directly with any questions and
let other folks know who may be interested.

best regards,
--wesley


On Thu, May 10, 2012 at 2:07 PM, wesley chun  wrote:
> Greetings!
>
> I'll be doing another hardcore Python course this summer in the San
> Francisco area. If you're somewhat new to Python or have tinkered but
> want to fill-in the holes, this course is for you. It's somewhat true
> you can learn Python online, watching videos, or reading books, but it
> still takes time and experience to master... I help accelerate this
> process. The course is based on my bestselling "Core Python" books and
> is made up of 3 full days complete with lectures and three hands-on
> coding labs per day.
>
> Please pass on this message to your colleagues who also need to learn
> Python. It's also a great excuse to coming to beautiful Northern
> California for a summer vacation! More details at http://goo.gl/uW4oF
> as well as the links in my .signature below.


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
   +wesley chun : wescpy at gmail : @wescpy
Python training & consulting : http://CyberwebConsulting.com
"Core Python" books : http://CorePython.com
Python blog: http://wescpy.blogspot.com
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Python Web Development with Django by Wesley Chun

2012-05-24 Thread wesley chun
for those who aren't gainfully-employed, in emerging markets, or going
through hard times, it may seem quite expensive to purchase the book
at retail price ($49.99USD). below are some alternatives to obtaining
this one book at less than that:

1. Kindle electronic version from Amazon (at 65% off [$17.69]):
http://amzn.com/B004YWCKZS

2. used paperback from Amazon (as low as $15.65):
http://amazon.com/gp/offer-listing/0132356139?condition=used

3. more expensive but you get the book and the eBook (EPUB+PDF)
versions ($53.99):
http://informit.com/title/0132356139

best regards,
-- wesley

ps. please give credit where credit is due... i was the tertiary
author of this book.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : http://CyberwebConsulting.com
    "Core Python" books : http://CorePython.com
    Python blog: http://wescpy.blogspot.com

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



ANN: Intro+Intermediate Python, San Francisco, Aug 1-3

2012-05-11 Thread wesley chun
Greetings!

I'll be doing another hardcore Python course this summer in the San
Francisco area. If you're somewhat new to Python or have tinkered but
want to fill-in the holes, this course is for you. It's somewhat true
you can learn Python online, watching videos, or reading books, but it
still takes time and experience to master... I help accelerate this
process. The course is based on my bestselling "Core Python" books and
is made up of 3 full days complete with lectures and three hands-on
coding labs per day.

Please pass on this message to your colleagues who also need to learn
Python. It's also a great excuse to coming to beautiful Northern
California for a summer vacation! More details at http://goo.gl/uW4oF
as well as the links in my .signature below.

Since I hate spam, I'll only send out one more reminder as the date
gets closer... probably around OSCON's timeframe.

Hope to meet some of you soon!
--Wesley Chun
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : http://CyberwebConsulting.com
    "Core Python" books : http://CorePython.com
    Python blog: http://wescpy.blogspot.com
-- 
http://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


ANN: Intro+Intermediate Python, San Francisco, Aug 1-3

2012-05-10 Thread wesley chun
Greetings!

I'll be doing another hardcore Python course this summer in the San
Francisco area. If you're somewhat new to Python or have tinkered but
want to fill-in the holes, this course is for you. It's somewhat true
you can learn Python online, watching videos, or reading books, but it
still takes time and experience to master... I help accelerate this
process. The course is based on my bestselling "Core Python" books and
is made up of 3 full days complete with lectures and three hands-on
coding labs per day.

Please pass on this message to your colleagues who also need to learn
Python. It's also a great excuse to coming to beautiful Northern
California for a summer vacation! More details at http://goo.gl/uW4oF
as well as the links in my .signature below.

Since I hate spam, I'll only send out one more reminder as the date
gets closer... probably around OSCON's timeframe.

Hope to meet some of you soon!
--Wesley Chun
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : http://CyberwebConsulting.com
    "Core Python" books : http://CorePython.com
    Python blog: http://wescpy.blogspot.com
-- 
http://mail.python.org/mailman/listinfo/python-list


[portland] ANN: Intro+Intermediate Python, San Francisco, Aug 1-3

2012-05-10 Thread wesley chun
Greetings!

I'll be doing a(nother) hardcore Python course this summer near the San
Francisco airport. If you're somewhat new to Python or have tinkered but
want to fill-in the holes, this course is for you. It's somewhat true
you can learn Python online, watching videos, or reading books, but it
still takes time and experience to master... I help accelerate this
process. The course is based on my bestselling "Core Python" books and
is made up of 3 full days complete with lectures and three hands-on
coding labs per day.

Please pass on this message to your colleagues who also need to learn
Python. It's also a great excuse to coming to beautiful Northern
California for a summer vacation! More details at http://goo.gl/uW4oF
as well as the links in my .signature below.

Since I hate spam, I'll only send out one more reminder as the date
gets closer... probably around OSCON's timeframe.

Hope to meet some of you soon!
--Wesley Chun
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : http://CyberwebConsulting.com
    "Core Python" books : http://CorePython.com
    Python blog: http://wescpy.blogspot.com
___
Portland mailing list
Portland@python.org
http://mail.python.org/mailman/listinfo/portland


[SEAPY] ANN: Intro+Intermediate Python, San Francisco, Aug 1-3

2012-05-10 Thread wesley chun
Greetings!

I'll be doing another hardcore Python course this summer in the San
Francisco area. If you're somewhat new to Python or have tinkered but
want to fill-in the holes, this course is for you. It's somewhat true
you can learn Python online, watching videos, or reading books, but it
still takes time and experience to master... I help accelerate this
process. The course is based on my bestselling "Core Python" books and
is made up of 3 full days complete with lectures and three hands-on
coding labs per day.

Please pass on this message to your colleagues who also need to learn
Python. It's also a great excuse to coming to beautiful Northern
California for a summer vacation! More details at http://goo.gl/uW4oF
as well as the links in my .signature below.

Since I hate spam, I'll only send out one more reminder as the date
gets closer... probably around OSCON's timeframe.

Hope to meet some of you soon!
--Wesley Chun
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : http://CyberwebConsulting.com
    "Core Python" books : http://CorePython.com
    Python blog: http://wescpy.blogspot.com


Re: [Tutor] python installation problem

2012-05-03 Thread wesley chun
there are many pitfalls in installing Python on Macs. it definitely
isn't straightforward because usually the one you install will
conflict with the that Apple ships with Mac OS X. i would second the
recommendation to use MacPorts, homebrew, finkCmdr, or similar tools.

someone should do a fresh install, document the procedure, and make a
blogpost out of it! :-)

cheers,
--wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : http://CyberwebConsulting.com
    "Core Python" books : http://CorePython.com
    Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] Emailing code

2012-04-06 Thread wesley chun
On Fri, Apr 6, 2012 at 12:14 PM, myles broomes
 wrote:
> This question isnt so much related to a specific program, just something im
> curious about. What is the best way to email code? I find that when i copy
> and paste it into an email, the indentation and spacing gets all messed up.


as an alternative to emailing code, you can paste(bin) it online and
just send (or tweet or G+ or otherwise post) the URL... there are many
providers of this type of service out there:
http://www.similarsitesearch.com/alternatives-to/pastebin.com

cheers,
-- wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : http://CyberwebConsulting.com
    "Core Python" books : http://CorePython.com
    Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] generators

2012-04-03 Thread wesley chun
> On Tue, Apr 3, 2012 at 2:38 PM, mike jackson  wrote:
> I am trying understand python and have done fairly well, So for it has been 
> easy to learn and is concise.  However I seem to not quite understand the use 
> of a generator over a function(I am familiar with functions [other languages 
> and math]).  To me (excepting obvious syntax differences) a generator is a 
> function.  Why should I use a generator instead of a function or vice versa?  
> Is perhaps specfic uses it was created to handle?  A great web page with good 
> examples would be nice.  Of course if you can sum it up rather easy then by 
> all means go ahead.


dave beazley's lectures are *awesome*, and even more so if you can
attend them in-person. below are my comments on generators off the top
of my head:

1. syntactically, generators are merely functions with one or more
"yield" statements/expressions

2. users of generators will see them primarily as "advanced"
iterators, because they yield individual values until such an iterator
has been exhausted (StopIteration).

3. creators of generators will see them more like functions that you
can pause, "return" some intermediate value, then be resumable/resumed
later. the C language has the concept of a "static function" where
variables can maintain their values across function calls. while being
"nice," it's not nearly as powerful as being able to save the values
*and* the entire state of execution at the time the function is paused
then resume right where it left off later, hence the comparisons with
co-routines (which are even more independent threads of execution).

4. "generator expressions" are the lazy evaluation form of list
comprehensions, and better for memory because of that. they'll behave
just like generators but can be defined easily on a single line, just
like normal listcomps.

5. i made a quick 5-minute video introducing Python developers to
generators... it's a very ad hoc and informal session during one of my
Python courses that a student recorded. if interested in viewing it,
you can find it half-way down http://cyberwebconsulting.com

hope this helps!
-- wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : http://CyberwebConsulting.com
    "Core Python" books : http://CorePython.com
    Python blog: http://wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] Question about login=''.join(choice(lc) for j in range(llen))

2012-04-03 Thread wesley chun
On Tue, Apr 3, 2012 at 10:50 AM, Peter Otten <__pete...@web.de> wrote:
> Alan Gauld wrote:
>> On 03/04/12 15:54, Khalid Al-Ghamdi wrote:
>>
>>>      dom="".join(choice(lc) for j in range (dlen))
>>>
>>> how does the interpreter know what "j" is supposed to refer to when it
>>> was not mentioned prior?


+1 everyone else's replies so far. i'll add the following: you create
variables by assigning things to them. in this example, no prior code
used the variable 'x':

>>> x = 10
>>> print x
10

similarly, when used in a for-loop, it's like you had an "invisible"
assignment at the "top" of the loop. here's an example:

>>> for i in range(5):
...  print i
...
0
1
2
3
4
>>> print i
4

notice that the 'i' variable is still there even after the loop has
ended. it's as if you did the following:

>>> i = 0
>>> print i
0
>>> i = 1
:
>>> i = 4
>>> print i  # 1st time, part of the "loop"
4
>>> print i  # 2nd time, "outside" of the loop
4

hope this helps!
--wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : CyberwebConsulting.com
    "Core Python" books : CorePython.com
    Python blog: wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] New to Python programing

2012-04-03 Thread wesley chun
a couple of other sources of video learning (DISCLAIMER: the 1st is
from my employer, and the 2nd is from me -- the intention is to
provide alternatives not shameless self-promotion so please don't take
it that way!):

1. Google offers an internal Python training class to its employees.
it's a 2-day course designed to teach existing programmers how to code
in Python, covering syntax, data structures, etc. (it's not deep and
thorough like the course i teach publicly but it may be just what you
need.)

i volunteer to deliver it a couple of times a year. anyway, you can
get all the course contents, exercises, and a lively delivery by my
colleague Nick Parlante (recorded a few years ago) across 7 videos
which span both days here:
http://code.google.com/edu/languages/google-python-class

2. a few years ago, i was asked to do a video version of my public
course blended with material from the "Core Python Programming" book.
the primary target audience includes existing programmers who need to
learn Python (2.x & 3.x) quickly and comprehensively via video
lectures (as opposed to the "show-me-do" style of onscreen hacking --
which is *also* a viable way of learning but just not for everyone).

some people prefer the lecture-style, so if you do, then you may wish
to consider it. i made the mistake of not being more public about this
early on, hence some of the not-so-great Amazon reviews. :P anyway, if
you're interested, you can get a free video clip here:
http://www.informit.com/store/product.aspx?isbn=9780137143412. (the
editors left some of my bleeping bloopers in the DVD, so it may be
entertaining to you at my expense.) another free preview of my
teaching style (if you want to learn about Python Generators) can be
found at http://cyberwebconsulting.com

cheers,
-- wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : CyberwebConsulting.com
    "Core Python" books : CorePython.com
    Python blog: wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] New to Python programing

2012-04-02 Thread wesley chun
greetings walter, and welcome to the Python family!

it looks like you've got your machine all set up. hopefully installing
Python 3 wasn't too difficult -- users constantly have issues with
their own installs clash with the Python that's pre-installed by
Apple.

as far as learning Python for beginners goes, you have to decide what
version to learn -- since you have both Python 2 & 3 on your system,
you have a choice. if you have existing code that's written in Python
2.x, you should learn that first. if you have "no baggage," then
Python 3.x is the way to go as it is the future.

regardless of which you pick, you should realize: 1) once you learn
one, you will learn the other as there are only seemingly minor (but
backwards-incompatible differences), 2) most books and online
materials are still in Python 2 although more and more Python 3
materials are becoming available.

as far as books go, the best way to learn Python is by writing games.
this is an approach that works both with children as well as adults.
there are several excellent books that can help you with this regard:

- Hello World! Computer Programming for Kids and Other Beginners by
Warren Sande and Carter Sande, Manning,
- Invent your Own Computer Games with Python second edition by Al Sweigart
- How to Think Like a Computer Scientist by Allen B. Downey, Jeff
Elkner and Chris Meyers, Green Tea Press
- Python Programming for the Absolute Beginner by Michael Dawson,
Course Technology

i go into a bit more detail on these as well as the books shane
recommends in my "Python Reading List" article (which actually
describes 3 separate reading lists):
http://www.informit.com/articles/article.aspx?p=1849069

as far as online resources go, try these:

- How to Think Like a Computer Scientist (Downey, Elkner, Meyers)
http://www.openbookproject.net/thinkcs/
- Learning to Program (Gauld)
http://www.alan-g.me.uk/l2p
- LiveWires Python
http://www.livewires.org.uk/python/home
http://pythongames.weebly.com/livewires.html
- Snake Wrangling for Kids (Briggs)
http://www.briggs.net.nz/snake-wrangling-for-kids.html
http://code.google.com/p/swfk/
- Computer Programming is Fun! (Handy)
http://www.handysoftware.com/cpif/
- Karel the Robot clone: Guido van Robot
http://gvr.sf.net
http://en.wikipedia.org/wiki/Guido_van_Robot
- Karel the Robot clones: RUR-PLE
http://rur-ple.sf.net
http://en.wikipedia.org/wiki/RUR-PLE
- A Byte of Python (Swaroop)
http://www.swaroopch.com/notes/Python
- Instant Hacking: Learning to Program with Python (Hetland)
http://hetland.org/writing/instant-hacking.html

hope this all helps, and again, welcome to Python!!
--wesley


On Mon, Apr 2, 2012 at 5:03 PM, Walter Luna  wrote:
> Hi everybody, my name is Walter I am a new beginner with no programing 
> experience. I am using OSX Lion, and successfully installed Python version 3. 
> I am looking for a programing guide for  beginners with no programing 
> experience. Can you please suggest me a good one to use. Thank you.
>
> Walter


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : CyberwebConsulting.com
    "Core Python" books : CorePython.com
    Python blog: wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] 答复: Any book to study Python

2012-03-28 Thread wesley chun
> I'm reading your book and just typeing the TCP server and client example 
> scripts to my python and run it, but I did not get the expected results.
>
> For tstclnt.py(example 16.2,page 473 on the book),when I typed in vi and 
> execut it by python tstclnt.py, I get the error of 'No route to host'.
>
> Of course I modified the IP address to 192.168.1.11 which is on another linux 
> server in the script, I pinged the 192.168.1.11 and get successfully.(On 
> 192.168.1.11 I run the TCP server program, it is the one on the book)
>
> Please see the screen shot for detail.
>
> Can you give me some suggestion on this error?



hi xianming,

any of the tutors here can help you, not just me! :-)

instead of a screenshot (many people use only terminals to read
email), it's best to just cut-n-paste the code and error traceback
into your email. based on what you sent in, it would be worthwhile for
you to also post the server code and output as well.

note that a positive ping and the client speaking to an address are
somewhat but not entirely related. the reason is that different
network protocols are being used. ping uses ICMP --
http://en.wikipedia.org/wiki/Internet_Control_Message_Protocol --
while the code uses TCP --
http://en.wikipedia.org/wiki/Transmission_Control_Protocol -- instead.

once you provide the server code and output, people may be able to
help you better.

best regards,
-- wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
    wesley chun : wescpy at gmail : @wescpy/+wescpy
    Python training & consulting : CyberwebConsulting.com
    "Core Python" books : CorePython.com
    Python-flavored blog: wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] 答复: Any book to study Python

2012-03-19 Thread wesley chun
On Mon, Mar 19, 2012 at 6:36 PM, Yan, Xianming <
xianming@intercallapac.com> wrote:

>
> I've bought the book named Python 核 心 编 程 (第二版) on www.dangdang.com. I
> guess I can get the book today.
>
> To Wesley, I did not realize you are the author of Python 核 心 编 程 (第二版)
> until I read the book's note online carefully and found your name. It's
> very exciting! You know this is the first time in my life that the book's
> author e-mail me. After I get it I shall start to read in my weekend and if
> there is any questions I shall write e-mail to you. Thanks again!
>


hi xian-ming,

i'm replying here to address dave angel's comment to reply *after* the
email (this is called "bottom-posting" so that people here can see what
your issue and context are. many people normally "top-post" or reply at the
beginning, but it is not as easy to read this when communicating in a
technical forum like this. i can even remove the parts of your message
which i am not responding to (like i did above).

about Python 核 心 编 程 (第二版) and my participation, thanks to you and Leam for
your kind remarks, however i am a Python user just like everyone else
here... the only difference is that i started using Python in 1997 which
gives me more experience. :-) i'm also a crazy engineer that is also
interested in *documentation* -- i know, i'm losing my reputation as a
developer now. 8|

i hope that the criticisms of the translator can be minimized (just watch
out for the bad code indentation), and that they were able to interpret
what i really wanted to say, otherwise you may have to find the English
one. i try to use easy-to-understand English, so it should not be *too*
bad. anyway, if you have more questions, please cut-n-paste your code here
along with the output, and everyone can help you more effectively.

谢谢!
--  wesley - 陈仲才
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"A computer never does what you want... only what you tell it."
wesley chun : wescpy at gmail : @wescpy <http://twitter.com/wescpy>/
+wescpy <http://plus.ly/wescpy>
Python training & consulting : CyberwebConsulting.com
"Core Python" books : CorePython.com <http://corepython.com/>
Python-flavored blog: wescpy.blogspot.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] Any book to study Python

2012-03-19 Thread wesley chun
你好 Xianming,

I have a book --  *Python 核 心 编 程 (第二版)* -- that is for people who already
program but want to learn Python. It is available in China from at least 3
online stores:

http://www.china-pub.com/39969
http://www.amazon.cn/dp/bkbk835890
http://mall.sina.com.cn/product_1749023.htm

In the Amazon comments, it looks like there are critical replies about the
translator. Since I cannot read Chinese, I don't know about the book's
quality or translation accuracy because I write with American English, so
you should do some research to see if it is a good book. To compare, the
English one is at http://amzn.com/0132269937

Good luck!
--Wesley - 陈仲才 (陳仲才)


On Mon, Mar 19, 2012 at 12:38 AM, Yan, Xianming <
xianming@intercallapac.com> wrote:

> Hello all,
>
> I'm a new learning to python and does not know python anything at all.
>
> Anyone can recommend a book about python to read? I prefer a paper-based
> book, not online book.
>
> By the way, I'm from china, I hope the book is Chinese--:)--Reading in
> Chinese is quicker~:)
>
> Thanks
> Xianming
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy/+wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] question on self

2012-03-13 Thread wesley chun
i want to expand specifically on steve's response and note the big
distinction that needs to be made for everyone is that this is primary the
difference between calling a *function* and calling a *method* (which is a
function that belongs to/defined for a class).

with that instance (self), that method is considered "bound," and Python
automagically passes it in as the first argument to that method (self). if
you wish to call an *unbound* method, you need to pass an instance on your
own *and* reference it via its class, i.e., YourClass.TakeTurns(self) --
readability takes a blow there.

btw, if you want to make just a function call *and* that function doesn't
have much to do with the class, then just define it as a function. a
seldomly-used alternative is to make it a static method (using the
@staticmethod decorator) -- this lets you define a method within a class
but pretend it's like a function (where you don't need to use the instance
[self]).

cheers,
--wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python Programming", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy/+wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] specific recommendation for a Python book, to move from baby-level to intermediate-level

2012-02-15 Thread wesley chun
tooting my own horn, http://corepython.com gets good reviews too. however,
it does target existing programmers who want to learn Python as quickly and
as comprehensively as possible. it's not a good book if you're a beginner
to programming or are looking for a pure reference like PER or Nutshell.

if you really need a learning disc, a subset of my book and the slides i
use to teach with can be found in the Python Fundamentals DVD that i
authored as well, however it is *not* a "showmedo" video of Python hacking.
rather, it's a subset of my lectures that come from my Python courses.

i'm also book-agnostic but am concerned that readers get the right book for
their needs, so i would be glad to recommend other books outside of my own.

cheers,
--wesley



On Wed, Feb 15, 2012 at 1:28 AM, Alan Gauld wrote:

> On 15/02/12 02:16, Tamar Osher wrote:
>
>  I am hoping to find a professionally designed, serious, university level
>> book (with exercises, with a learning disc, and answers, and an
>> elaborately helpful website) that will carefully and surely guide me
>> through learning computer programming with Python version 3. I want to
>> be lifted up from a baby-level to an intermediate level.
>>
>
> I don;t know about a CD etc but its a good book:
>
> Programming in Python 3 by Summerfield.
>
> And as a general intermediate book I like
>
> Programming Python by Lutz (not in v3 yet but as an
> intermediate programmer that won't make any difference
> to you, your past worrying about that)
>
>
>  I don't want to spend a lot of time casually browsing through the
>> websites, trying out different things.
>>
>
> A pity, its the best way to learn.
>
>
> > I am in a rush to become a Python expert, I need a job!
>
> Go write lots of code.
>
>
>  I enjoy computer programming. Python is my only programming language.
>>
>
> To get and keep a job you will need more than one.
> As a minimum you will probably need SQL and nowadays
> at least some JavaScript will be useful. And an OS shell
> language would be useful too. As a minimum.
>
>
>  A note to Python Teachers:
>> I downloaded Python version 3.2.2 on my computer. Most Python books and
>> tutorials are several years old, for older, outdated versions.
>>
>
> Yes, because to produce them takes a lot of time. And most online
> tutorials are done by volunteers with another lifew - the one that earns
> them money. So they can't write tutorials as fast as the language evolves.
> Or they only have time to write a tutorial once, not to update it. The good
> news is that Python is fairly stable and most things still work even from
> version 1.
>
>
>  learning Python got off to a slow start: Initially, I had spent over a
>> week trying to figure out the (version 2) tutorial for "Hello, World!",
>> and the print/print() situation.
>>
>
> Really? If you had asked here. or even read the v3 documentation you would
> have had print()  explained in great detail.
>
>
>  Today, there is a huge and growing number of online Python tutorials and
>> websites. My request is that the list of recommended tutorials be
>> revised and updated. There is a sizable amount of learning and tutorial
>> info at Python.org that seems to be valuable historical information
>> rather than urgent-read-now-tutorials for new beginning programmers.
>>
>
> Remember that many - most? - professional Python programmers are still
> using Python v2 not v3. There are still some critical third party libraries
> to be ported to v3. It is getting better but we are not there yet. At the
> very least they are maintaining v2 code. I use both versions but only about
> 20-25% of my time is spent in v3. v2 is not only of "historical" interest,
> its what the majority of Python code is written in, even today.
>
>
>  instance, there are some very well written Python tutorials from years
>> 2009, 2007, and 2005. An idea: Delete all references to tutorials that
>> are not version 2 or 3.
>>
>
> v1 Python is possibly a valid point. But most v1 tutorials are still valid
> in v2, there was much less change from v1 to v2.
>
>
>  And clearly label all the well-written version 2 tutorials, as
>>
> > being outdated version 2.
>
> Who determines what is "well written"? And if a tutorial is based on v2.7
> is it really outdated?
>
>
>  For me, learning computer programming is easy, so far.
>>
>
> That's good, so you will have realized that the language, and especially
> the language version is largely irrelevant. What is important is structure,
> algorithm, data and I/O.
>
>  What is difficult is ...learning how to manage the
>>
>> difference between version 3.2.2 and older versions.
>>
>
> No, that's trivially easy. If you think that's difficult then you haven't
> begun to understand computer science. I strongly suggest you search for and
> read the classic paper by Fred Brooks called "No silver bullet"
> There he describes the "essential" problems at the heart of programming
> and why there are no easy answers. Languages included.
>
>
>  For

Re: [OT] Book authoring

2012-01-03 Thread wesley chun
fwiw, i've given a related talk a couple of times on this subject, the
most recent of which was at EuroPython this summer:
http://ep2011.europython.eu/conference/talks/writing-books-using-python-open-source-software

the content includes a couple of the tools mentioned in this thread as
well as some author case studies. slide deck's available there too.

cheers,
--wesley


On Dec 9 2011, 7:43 am, Nick Dokos  wrote:
> Grant Edwards  wrote:
> > On 2011-12-09, Miki Tebeka  wrote:
> > > Greetings,
>
> > > Any recommendations for abook authoringsystem that supports the following:
> > > 1. Code examples (with syntax highlighting and line numbers)
> > > 2. Output HTML, PDF, ePub ...
> > > 3. Automatic TOC and index
> > > 4. Search (in HTML) - this is a "nice to have"
>
> >http://en.wikipedia.org/wiki/Lightweight_markup_language
>
> > I've used asciidoc extensively and reStructuredText a little. Asciidoc
> > will produce all the formats you mentioned (though I've only refularly
> > used HTML and PDF). reStructuredText is what's used for Python docs
> > isn't it?
>
> > > Can I somehow use Sphinx?
>
> > Don't know what Sphinx is.
>
> I think Sphinx is used for the python docs: it sits atop rST and does
> all the transformations/processing to produce the desired output
> (http://sphinx.pocoo.org)
>
> > And there's always the old stand-by LaTeX, but it's a bit more
> > heavyweight with more of a learning curve.  OTOH, it does produce
> > text-book quality output.
>
> There is also orgmode, which has been used for a few books
> (http://orgmode.org). I know it does HTML and PDF (the latter through
> latex), but I'm not sure about ePub: ISTR somebody actually did ePub for
> his book but I don't remember details. The indexing is manual:
> add #+index: foo entries as required.  But in general, imo, automatic
> indexing for books sucks raw eggs (it works much better for highly
> regular source code like the python source base).
>
> Nick


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
    http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy/+wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: [Tutor] best book for OOP

2011-12-11 Thread wesley chun
what do you think you are missing? is there something in the book that
you don't/can't understand? those of us on the list may be able to
help you out... sometimes humans are better at explaining things than
just books. :-)

best regards,
--wesley



On Sun, Dec 11, 2011 at 6:49 AM, surya k  wrote:
>
> I'm reading "Core Python Programming" - Chun..
> Currently, I am studying OOP in it.. and I feel there is something I am 
> missing in that while studying. Actually I am from C.. so, no idea of OOP.
> Could you tell me the best, simple, easy to understand book!!


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Python Web Development with Django", Addison Wesley, (c) 2009
    http://withdjango.com

wesley.chun : wescpy-gmail.com : @wescpy/+wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


LinuxJournal Readers' Choice Awards 2011 Best {Programming, Scripting} Language

2011-12-04 Thread wesley chun
in recent news...

Python wins LinuxJournal's Readers' Choice Awards 2011 as Best
Programming Language:
http://www.linuxjournal.com/slideshow/readers-choice-2011?page=27

yee-haw!! it's even more amazing that Python has won this title 3
straight years. let's celebrate and get back to building great things.

wait, in other news...

Python wins LinuxJournal's Readers' Choice Awards 2011 as Best
Scripting Language:
http://www.linuxjournal.com/slideshow/readers-choice-2011?page=28

interestingly enough, this happened last year as well:
http://www.linuxjournal.com/content/readers-choice-awards-2010

in fact, Python has nearly won this one 6 straight years, from
2006-2011, except bash won in 2009. is it the same people who are
voting (practically) every year? :-)

cheers,
--wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
    http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: [Tutor] Python Saved the Day

2011-12-04 Thread wesley chun
Congrats! I love hearing stuff like this... keep them coming! I'm curious
as to how Python was able to help you get your job done this time (without
going into anything confidential naturally). What was it about the
language? Or was it specific Python modules/packages you used for the
analysis?

Does anyone else have similar stories? (I think I may be biased as I use
Python for everything, trouble or otherwise, so I can't tell the difference
anymore!)

cheers,
-wesley


On Sun, Dec 4, 2011 at 12:45 AM, Mark Lybrand  wrote:

> No question.   Last weekend I buckled down and learned as much Python as I
> could (just because I have had an interest to do so for a while).  When I
> got to work on Monday, there was a serious database issue that needed
> addressing.  As I was trying to assess the situation, I employed Python to
> help me do my data analysis.  I was able to sort through all the issues,
> develop a corrective action plan and verify its accuracy, all in Python.
> Plan was successfully implemented at 6PM today and all is well again. It
> was a good week.
>
> --
> Mark :)



-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [SEAPY] October Meeting, thank you

2011-10-19 Thread wesley chun
sure np... glad to be able to come up there to give this talk! also i forgot
to give jonathan the link for the training, and sadly, today is the 2nd day
of 3 already, but i'll be doing a more applications-focused class in
February. the link for all my courses is http://cyberwebconsulting.com

cheers,
-wesley


On Wed, Oct 19, 2011 at 12:04 PM, jentzen mooney wrote:

> Awesome bosum!!
> :)
> Thanks again.
>
> --
> *From:* Jonathan Mark 
>
> *To:* Seattle Python Interest Group 
> *Cc:* wesley chun ; jentzen mooney <
> jentzenski...@yahoo.com>
> *Sent:* Wednesday, October 19, 2011 12:01 PM
> *Subject:* Re: [SEAPY] October Meeting, thank you
>
> I found the slides.  Wesley sent them earlier but I misplaced them.
>
> Here is a link to the meeting summary (which has a link to the slides):
> http://seapig.org/October2011Notes
>
> Thanks again Wesley!!
>
> best,
>
> Jonathan
>



-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Python Web Development with Django", Addison Wesley, (c) 2009
http://withdjango.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com


Re: [SEAPY] October Meeting, thank you

2011-10-19 Thread wesley chun
sure, np. i enjoyed it. i've sent the slides to jonathan already so he'll
post them soon!

cheers,
-wesley


On Wed, Oct 19, 2011 at 7:47 AM, jentzen mooney wrote:

> I saw on the meeting notes page that Wesley Chun will be posting his slides
> from his talk soon.
> I just wanted to say Thank you to Wesley Chun, for speaking and sharing
> his slides.
> :)
> I hope it was a good meeting.
> -Jentzen
>
> --
> *From:* Casey Durfee 
> *To:* Seattle Python Interest Group 
> *Sent:* Monday, October 17, 2011 5:34 PM
> *Subject:* Re: [SEAPY] solr django and python recommendations
>
> I've done several big projects (tens of millions of documents) with Solr
> and Python.
>
> I think it's one of those things where if you're not familiar with Solr,
> you're better off doing things by hand first as a way to learn how it works.
>  And if you are doing something complex or know Solr really well, you might
> find a specific library more trouble than it's worth.
>
> The main issues I encounter with Solr are:
>
> 1. Designing a good Solr data model
> 2. Detecting changed records in the DB and updating Solr efficiently
> 3. Dealing with Solr's rules about stopwords, stemming, tokenizing, etc. of
> search terms and text and getting the right combo of them for the problem
> you're trying to solve
> 4. Getting relevancy ranking to be good (tuning the weighting between
> different query fields in Solr, and/or re-sorting results based on database
> attributes after you get an initial rough result set from Solr.)
> 5. Massaging funky or incomplete data you want to index, munging character
> sets, etc.
>
> A client library isn't really going to solve any of those for you, I don't
> think (except maybe #1 and #2, and probably not that well).  They might help
> you get to a working solution marginally faster, but at the cost of you
> having to go back and learn Solr anyway if you what it gives you
> automagically isn't good enough in any number of ways.
>
> Jython would probably only come into play in my book if you wanted to write
> a tokenizer/filter/query analyzer for Solr to use and needed to plug into
> someone else's Java code as a part of that.  Since you can pre-process the
> data before you send it to Solr, however, I've never had occasion to write a
> Solr plugin directly.  It makes more sense to me to have all of your
> indexing logic in one place -- meaning do as much massaging as possible
> before sending data to Solr, instead of half of your logic in shell scripts
> and half in server-side Solr plugins.
>
> Given how efficient Solr is at this point, and how much hassle it saves you
> overall, I don't see a big advantage in interfacing directly with
> (Py)Lucene.
>
>
> --Casey
>
> On Sat, Oct 15, 2011 at 10:53 AM, Christopher Bare <
> christopherb...@gmail.com> wrote:
>
> Hi Pythonistas,
>
> Does anyone have experience accessing a Solr search engine from
> Python? There are several bindings out there, so if anyone has a
> recommendation, I'd appreciate it.
>
> Our needs are probably on the lighter end of the spectrum: moderate
> traffic, tens of thousands building to hundreds of thousands of search
> terms over time. Infrequent updates, accesses are mostly read.
>
> I looked briefly at Haystack and wasn't too excited by it. Too much
> "automagic" stuff going on. Plus, I like the idea of defining my own
> Solr schema, rather than directly mapping Django models into Solr.
> Sunburt looks pretty good, at first glance.
>
> Any hints would be appreciated. Thanks!
>
> - Chris
>
>


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com


Re: [SEAPY] Call for October Python speaker (and location)

2011-10-04 Thread wesley chun
cool, be glad to! the talk abstract and my background would be
identical as what's on those events' sites, so feel free to "borrow"
as necessary for seapig.

cheers,
-wesley


On Tue, Oct 4, 2011 at 12:19 PM, Jonathan Mark  wrote:
> Hi,
>
> That's OK Oscar, looking forward to the Blender talk when it is rescheduled.
>
> Wesley, I think that sounds great and appreciate you stepping up.
> If you can talk for 60-90 minutes at the beginning, it will leave some time
> for discussion of random topics afterward.
> See you all Oct. 13 at 7:00!
>
> Thanks!
>
>        Jonathan
>
> On 10/3/2011 8:28 PM, wesley chun wrote:
>>
>> wow, sorry to hear that oscar!! i was originally going to do a quick
>> 30mins and let you have the rest of the time, but if i can extend it
>> as the original Python 3 talk is 60-90mins in length. i just gave this
>> talk last week and the week before as the opening keynote at
>> PythonBrasil
>> (http://www.pythonbrasil.org.br/2011/programacao/diaria/quinta-feira-29-09-2011)
>> as well as the closing English keynotes at PyCon Argentina
>> (http://ar.pycon.org/2011/activity/accepted#63), respectively.
>> whatever you guys want/need... just lemme know!


Re: [SEAPY] Call for October Python speaker (and location)

2011-10-03 Thread wesley chun
wow, sorry to hear that oscar!! i was originally going to do a quick
30mins and let you have the rest of the time, but if i can extend it
as the original Python 3 talk is 60-90mins in length. i just gave this
talk last week and the week before as the opening keynote at
PythonBrasil 
(http://www.pythonbrasil.org.br/2011/programacao/diaria/quinta-feira-29-09-2011)
as well as the closing English keynotes at PyCon Argentina
(http://ar.pycon.org/2011/activity/accepted#63), respectively.
whatever you guys want/need... just lemme know!

cheers,
-wesley


On Mon, Oct 3, 2011 at 11:46 PM, Oscar Baechler  wrote:
> My wife has informed me that we are leaving for a wedding in California on
> the 13th, not the 14th as I originally thought. Unfortunately I won't be
> able to talk about Blender like I hoped at the October meeting, so I am
> afraid I must punt to November :(
>
> My apologies, hope this is early enough notice for a new volunteer to step
> forward.
> Sorry guys, I totally suck!
> --Oscar
>
> On Wed, Sep 21, 2011 at 1:03 PM, wesley chun  wrote:
>>
>> great! how long is your talk Oscar? in jonathan's message, it said 7-9p at
>> the venue, but this month it seems like a 1-hour talk followed by a 1-hour
>> brewfest. i just need to know how many slides i would need for the talk so i
>> can customize it for you guys.
>> as far as the venue goes, it looks like Fremont is going to win... we're
>> right under/next to the Fremont St bridge, so you can probably bike there.
>> parking is weird though so just be aware of that as it's in a private
>> business complex. having it here would be easier for me too as i don't make
>> it to Kirkland as much, but i wouldn't be opposed to holding it there at
>> some point cuz i know peeps from that office.
>> 
>> i'm offering my twice yearly hardcore intro+intermediate Python 3-day
>> course down in San Francisco again next month, so if you want me to convert
>> your friends & co-workers to Python, here's your chance. :-) totally
>> convenient (& free) from the
>> airport: http://sfbay.craigslist.org/sfc/cls/2495963854.html
>> 
>>
>> cheers,
>> -wesley
>>
>> On Wed, Sep 21, 2011 at 5:39 PM, Oscar Baechler 
>> wrote:
>>>
>>> Also +1 Fremont :)
>>>
>>> Wesley's talk sounds great to me!
>>>
>>> On Wed, Sep 21, 2011 at 10:27 AM, Richard Fuhr 
>>> wrote:
>>>>
>>>> +1 Fremont
>>>>
>>>> On Wed, Sep 21, 2011 at 10:12 AM, Kevin LaTona 
>>>> wrote:
>>>>>
>>>>> +1 Fremont
>>>>>
>>>>> On Sep 21, 2011, at 10:06 AM, Matt S. wrote:
>>>>>
>>>>>> +1 Fremont
>>>>>>
>>>>>> On Wed, Sep 21, 2011 at 9:21 AM, Cris Ewing 
>>>>>> wrote:
>>>>>> +1 for Fremont
>>>>>>
>>>>>> c
>>>>>>
>>>>>> On Sep 20, 2011, at 10:43 PM, wesley chun wrote:
>>>>>>
>>>>>> > hi all,
>>>>>> >
>>>>>> > i lurk most of the time because i'm based out of silicon valley but
>>>>>> > visit SEA quite often to meet with my team up there. i'd like to
>>>>>> > come
>>>>>> > as a 1st-timer to the meeting if you'll have me, and perhaps before
>>>>>> > Oscar's interesting talk, i can give a quick recap/review of what's
>>>>>> > going with Python 3 anyway. i'm currently here in South America and
>>>>>> > will be giving a full keynote on this topic at both PyCon Argentina
>>>>>> > this weekend as well as PythonBrasil[7] next week.
>>>>>> >
>>>>>> > in the future, i should also be able to get Google to host some of
>>>>>> > the
>>>>>> > meetings. would y'all prefer to meet in Fremont or Kirkland? (i need
>>>>>> > to start thinking about it and reaching out to the correct peeps.)
>>>>>> >
>>>>>> > thanks,
>>>>>> > -wesley
>>>>>> >
>>>>>> >
>>>>>> > On Wed, Sep 21, 2011 at 12:17 AM, Nathaniel Guy
>>>>>> >  wrote:
>>>>>> >> I've already gotten us a room and I've been talking to Jon about
>>>>>> >> it, so no
>>>>>> >> worries. Jon, would you mind sending out the details?
>>>>>> >>
>>>>>> >> -Nat
>>>>>> >>
>>>>>> >> On Sep 20, 2011 5:04 PM, "Matt S."  wrote:
>>>>>> >>
>>>>>> >> I should be able to get a room at UW for the Oct. 13 meeting.




-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Python Web Development with Django", Addison Wesley, (c) 2009
    http://withdjango.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com


Fwd: ANN: Intro+Intermediate Python course, SF, Oct 18-20

2011-09-27 Thread wesley chun
** FINAL CALL **

http://sfbay.craigslist.org/sfc/cls/2495963854.html


-- Forwarded message --
From: wesley chun 
Date: Mon, Jul 25, 2011 at 12:32 PM
Subject: ANN: Intro+Intermediate Python course, SF, Oct 18-20

Need to get up-to-speed with Python as quickly and as in-depth as
possible? Already coding Python but still have areas of uncertainty
you need to fill? Then come join me, Wesley Chun, author of
Prentice-Hall's bestseller "Core Python" for a comprehensive
intro/intermediate course coming up this May in Northern California,
then enjoy a beautiful Fall weekend afterwards in San Francisco, the
beautiful city by the bay.

Please pass on this note to whomever you think may be interested. I
look forward to meeting you and your colleagues! Feel free to pass
around the PDF flyer linked down below. Write if you have questions.

Since I hate spam, I'll only send out one reminder as the date gets
closer.

(Comprehensive) Intro+Intermediate Python
Tue-Thu, 2011 Oct 18-20, 9am-5pm

Hope to meet you soon!
-Wesley

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(COMPREHENSIVE) INTRO+INTERMEDIATE PYTHON

Although this course may appear to those new to Python, it is also
perfect for those who have tinkered with it and want to "fill in the
gaps" and/or want to get more in-depth formal training.  It combines
the best of both an introduction to the language as well as a "Python
Internals" training course.

We will immerse you in the world of Python in only a few days, showing
you more than just its syntax (which you don't really need a book to
learn, right?). Knowing more about how Python works under the covers,
including the relationship between data objects and memory management,
will make you a much more effective Python programmer coming out of
the gate. 3 hands-on labs each day will help hammer the concepts home.

Come find out why Google, Yahoo!, Disney, ILM/LucasFilm, VMware,
NASA, Ubuntu, YouTube, and Red Hat all use Python. Users supporting or
jumping to Plone, Zope, TurboGears, Pylons, Django, Google App Engine,
Jython, IronPython, and Mailman will also benefit!

PREVIEW 1: you will find (and can download) a video clip of a
class session recorded live to get an idea of my lecture style and
the interactive classroom environment (as well as sign-up) at:

http://cyberwebconsulting.com

PREVIEW 2: Partnering with O'Reilly and Pearson, Safari Books
Online has asked me to deliver a 1-hour webcast a couple of years ago
called "What is Python?". This was an online seminar based on a
session that I've delivered at numerous conferences in the past. It
will give you an idea of lecture style as well as an overview of the
material
covered in the course.

info:http://www.safaribooksonline.com/events/WhatIsPython.html
download (reg req'd):
http://www.safaribooksonline.com/Corporate/DownloadAndResources/webcastInfo.php?page=WhatIsPython
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

WHERE: near the San Francisco Airport (SFO/San Bruno), CA, USA

WEB:   http://cyberwebconsulting.com

FLYER: http://cyberwebconsulting.com/flyerPP1.pdf

LOCALS: easy freeway (101/280/380) with lots of parking plus public
transit (BART and CalTrain) access via the San Bruno stations, easily
accessible from all parts of the Bay Area

VISITORS: free shuttle to/from the airport, free high-speed internet,
free breakfast and regular evening receptions; fully-equipped suites

See website for costs, venue info, and registration. There is a
significant discounts available for full-time students, secondary
teachers, and others.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python Programming", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
-- 
http://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


Re: [portland] ANN: Intro+Intermediate Python course, SF, Oct 18-20

2011-09-27 Thread wesley chun
** FINAL CALL **

http://sfbay.craigslist.org/sfc/cls/2495963854.html

-- Forwarded message --
From: wesley chun 
Date: Mon, Jul 25, 2011 at 12:32 PM
Subject: ANN: Intro+Intermediate Python course, SF, Oct 18-20

Need to get up-to-speed with Python as quickly and as in-depth as
possible? Already coding Python but still have areas of uncertainty
you need to fill? Then come join me, Wesley Chun, author of
Prentice-Hall's bestseller "Core Python" for a comprehensive
intro/intermediate course coming up this May in Northern California,
then enjoy a beautiful Fall weekend afterwards in San Francisco, the
beautiful city by the bay.

Please pass on this note to whomever you think may be interested. I
look forward to meeting you and your colleagues! Feel free to pass
around the PDF flyer linked down below. Write if you have questions.

Since I hate spam, I'll only send out one reminder as the date gets
closer.

(Comprehensive) Intro+Intermediate Python
Tue-Thu, 2011 Oct 18-20, 9am-5pm

Hope to meet you soon!
-Wesley

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(COMPREHENSIVE) INTRO+INTERMEDIATE PYTHON

Although this course may appear to those new to Python, it is also
perfect for those who have tinkered with it and want to "fill in the
gaps" and/or want to get more in-depth formal training.  It combines
the best of both an introduction to the language as well as a "Python
Internals" training course.

We will immerse you in the world of Python in only a few days, showing
you more than just its syntax (which you don't really need a book to
learn, right?). Knowing more about how Python works under the covers,
including the relationship between data objects and memory management,
will make you a much more effective Python programmer coming out of
the gate. 3 hands-on labs each day will help hammer the concepts home.

Come find out why Google, Yahoo!, Disney, ILM/LucasFilm, VMware,
NASA, Ubuntu, YouTube, and Red Hat all use Python. Users supporting or
jumping to Plone, Zope, TurboGears, Pylons, Django, Google App Engine,
Jython, IronPython, and Mailman will also benefit!

PREVIEW 1: you will find (and can download) a video clip of a
class session recorded live to get an idea of my lecture style and
the interactive classroom environment (as well as sign-up) at:

http://cyberwebconsulting.com

PREVIEW 2: Partnering with O'Reilly and Pearson, Safari Books
Online has asked me to deliver a 1-hour webcast a couple of years ago
called "What is Python?". This was an online seminar based on a
session that I've delivered at numerous conferences in the past. It
will give you an idea of lecture style as well as an overview of the
material
covered in the course.

info:http://www.safaribooksonline.com/events/WhatIsPython.html
download (reg req'd):
http://www.safaribooksonline.com/Corporate/DownloadAndResources/webcastInfo.php?page=WhatIsPython
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

WHERE: near the San Francisco Airport (SFO/San Bruno), CA, USA

WEB:   http://cyberwebconsulting.com

FLYER: http://cyberwebconsulting.com/flyerPP1.pdf

LOCALS: easy freeway (101/280/380) with lots of parking plus public
transit (BART and CalTrain) access via the San Bruno stations, easily
accessible from all parts of the Bay Area

VISITORS: free shuttle to/from the airport, free high-speed internet,
free breakfast and regular evening receptions; fully-equipped suites

See website for costs, venue info, and registration. There is a
significant discounts available for full-time students, secondary
teachers, and others.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python Programming", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
    http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
___
Portland mailing list
Portland@python.org
http://mail.python.org/mailman/listinfo/portland


Re: ANN: Intro+Intermediate Python course, SF, Oct 18-20

2011-09-27 Thread wesley chun
** FINAL CALL **

http://sfbay.craigslist.org/sfc/cls/2495963854.html


-- Forwarded message --
From: wesley chun 
Date: Mon, Jul 25, 2011 at 12:32 PM
Subject: ANN: Intro+Intermediate Python course, SF, Oct 18-20

Need to get up-to-speed with Python as quickly and as in-depth as
possible? Already coding Python but still have areas of uncertainty
you need to fill? Then come join me, Wesley Chun, author of
Prentice-Hall's bestseller "Core Python" for a comprehensive
intro/intermediate course coming up this May in Northern California,
then enjoy a beautiful Fall weekend afterwards in San Francisco, the
beautiful city by the bay.

Please pass on this note to whomever you think may be interested. I
look forward to meeting you and your colleagues! Feel free to pass
around the PDF flyer linked down below. Write if you have questions.

Since I hate spam, I'll only send out one reminder as the date gets
closer.

(Comprehensive) Intro+Intermediate Python
Tue-Thu, 2011 Oct 18-20, 9am-5pm

Hope to meet you soon!
-Wesley

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(COMPREHENSIVE) INTRO+INTERMEDIATE PYTHON

Although this course may appear to those new to Python, it is also
perfect for those who have tinkered with it and want to "fill in the
gaps" and/or want to get more in-depth formal training.  It combines
the best of both an introduction to the language as well as a "Python
Internals" training course.

We will immerse you in the world of Python in only a few days, showing
you more than just its syntax (which you don't really need a book to
learn, right?). Knowing more about how Python works under the covers,
including the relationship between data objects and memory management,
will make you a much more effective Python programmer coming out of
the gate. 3 hands-on labs each day will help hammer the concepts home.

Come find out why Google, Yahoo!, Disney, ILM/LucasFilm, VMware,
NASA, Ubuntu, YouTube, and Red Hat all use Python. Users supporting or
jumping to Plone, Zope, TurboGears, Pylons, Django, Google App Engine,
Jython, IronPython, and Mailman will also benefit!

PREVIEW 1: you will find (and can download) a video clip of a
class session recorded live to get an idea of my lecture style and
the interactive classroom environment (as well as sign-up) at:

http://cyberwebconsulting.com

PREVIEW 2: Partnering with O'Reilly and Pearson, Safari Books
Online has asked me to deliver a 1-hour webcast a couple of years ago
called "What is Python?". This was an online seminar based on a
session that I've delivered at numerous conferences in the past. It
will give you an idea of lecture style as well as an overview of the
material
covered in the course.

info:http://www.safaribooksonline.com/events/WhatIsPython.html
download (reg req'd):
http://www.safaribooksonline.com/Corporate/DownloadAndResources/webcastInfo.php?page=WhatIsPython
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

WHERE: near the San Francisco Airport (SFO/San Bruno), CA, USA

WEB:   http://cyberwebconsulting.com

FLYER: http://cyberwebconsulting.com/flyerPP1.pdf

LOCALS: easy freeway (101/280/380) with lots of parking plus public
transit (BART and CalTrain) access via the San Bruno stations, easily
accessible from all parts of the Bay Area

VISITORS: free shuttle to/from the airport, free high-speed internet,
free breakfast and regular evening receptions; fully-equipped suites

See website for costs, venue info, and registration. There is a
significant discounts available for full-time students, secondary
teachers, and others.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python Programming", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: [Edu-sig] ANN: Intro+Intermediate Python course, SF, Oct 18-20

2011-09-27 Thread wesley chun
** FINAL CALL **

http://sfbay.craigslist.org/sfc/cls/2495963854.html

significant discount for primary/secondary teachers.


-- Forwarded message --
From: wesley chun 
Date: Mon, Jul 25, 2011 at 12:32 PM
Subject: ANN: Intro+Intermediate Python course, SF, Oct 18-20

Need to get up-to-speed with Python as quickly and as in-depth as
possible? Already coding Python but still have areas of uncertainty
you need to fill? Then come join me, Wesley Chun, author of
Prentice-Hall's bestseller "Core Python" for a comprehensive
intro/intermediate course coming up this May in Northern California,
then enjoy a beautiful Fall weekend afterwards in San Francisco, the
beautiful city by the bay.

Please pass on this note to whomever you think may be interested. I
look forward to meeting you and your colleagues! Feel free to pass
around the PDF flyer linked down below. Write if you have questions.

Since I hate spam, I'll only send out one reminder as the date gets
closer.

(Comprehensive) Intro+Intermediate Python
Tue-Thu, 2011 Oct 18-20, 9am-5pm

Hope to meet you soon!
-Wesley

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(COMPREHENSIVE) INTRO+INTERMEDIATE PYTHON

Although this course may appear to those new to Python, it is also
perfect for those who have tinkered with it and want to "fill in the
gaps" and/or want to get more in-depth formal training.  It combines
the best of both an introduction to the language as well as a "Python
Internals" training course.

We will immerse you in the world of Python in only a few days, showing
you more than just its syntax (which you don't really need a book to
learn, right?). Knowing more about how Python works under the covers,
including the relationship between data objects and memory management,
will make you a much more effective Python programmer coming out of
the gate. 3 hands-on labs each day will help hammer the concepts home.

Come find out why Google, Yahoo!, Disney, ILM/LucasFilm, VMware,
NASA, Ubuntu, YouTube, and Red Hat all use Python. Users supporting or
jumping to Plone, Zope, TurboGears, Pylons, Django, Google App Engine,
Jython, IronPython, and Mailman will also benefit!

PREVIEW 1: you will find (and can download) a video clip of a
class session recorded live to get an idea of my lecture style and
the interactive classroom environment (as well as sign-up) at:

http://cyberwebconsulting.com

PREVIEW 2: Partnering with O'Reilly and Pearson, Safari Books
Online has asked me to deliver a 1-hour webcast a couple of years ago
called "What is Python?". This was an online seminar based on a
session that I've delivered at numerous conferences in the past. It
will give you an idea of lecture style as well as an overview of the
material
covered in the course.

info:http://www.safaribooksonline.com/events/WhatIsPython.html
download (reg req'd):
http://www.safaribooksonline.com/Corporate/DownloadAndResources/webcastInfo.php?page=WhatIsPython
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

WHERE: near the San Francisco Airport (SFO/San Bruno), CA, USA

WEB:   http://cyberwebconsulting.com

FLYER: http://cyberwebconsulting.com/flyerPP1.pdf

LOCALS: easy freeway (101/280/380) with lots of parking plus public
transit (BART and CalTrain) access via the San Bruno stations, easily
accessible from all parts of the Bay Area

VISITORS: free shuttle to/from the airport, free high-speed internet,
free breakfast and regular evening receptions; fully-equipped suites

See website for costs, venue info, and registration. There is a
significant discounts available for full-time students, secondary
teachers, and others.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python Programming", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
    http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig


Re: [SEAPY] ANN: Intro+Intermediate Python course, SF, Oct 18-20

2011-09-27 Thread wesley chun
** FINAL CALL **

http://sfbay.craigslist.org/sfc/cls/2495963854.html

-- Forwarded message --
From: wesley chun 
Date: Mon, Jul 25, 2011 at 12:32 PM
Subject: ANN: Intro+Intermediate Python course, SF, Oct 18-20

Need to get up-to-speed with Python as quickly and as in-depth as
possible? Already coding Python but still have areas of uncertainty
you need to fill? Then come join me, Wesley Chun, author of
Prentice-Hall's bestseller "Core Python" for a comprehensive
intro/intermediate course coming up this May in Northern California,
then enjoy a beautiful Fall weekend afterwards in San Francisco, the
beautiful city by the bay.

Please pass on this note to whomever you think may be interested. I
look forward to meeting you and your colleagues! Feel free to pass
around the PDF flyer linked down below. Write if you have questions.

Since I hate spam, I'll only send out one reminder as the date gets
closer.

(Comprehensive) Intro+Intermediate Python
Tue-Thu, 2011 Oct 18-20, 9am-5pm

Hope to meet you soon!
-Wesley

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(COMPREHENSIVE) INTRO+INTERMEDIATE PYTHON

Although this course may appear to those new to Python, it is also
perfect for those who have tinkered with it and want to "fill in the
gaps" and/or want to get more in-depth formal training.  It combines
the best of both an introduction to the language as well as a "Python
Internals" training course.

We will immerse you in the world of Python in only a few days, showing
you more than just its syntax (which you don't really need a book to
learn, right?). Knowing more about how Python works under the covers,
including the relationship between data objects and memory management,
will make you a much more effective Python programmer coming out of
the gate. 3 hands-on labs each day will help hammer the concepts home.

Come find out why Google, Yahoo!, Disney, ILM/LucasFilm, VMware,
NASA, Ubuntu, YouTube, and Red Hat all use Python. Users supporting or
jumping to Plone, Zope, TurboGears, Pylons, Django, Google App Engine,
Jython, IronPython, and Mailman will also benefit!

PREVIEW 1: you will find (and can download) a video clip of a
class session recorded live to get an idea of my lecture style and
the interactive classroom environment (as well as sign-up) at:

http://cyberwebconsulting.com

PREVIEW 2: Partnering with O'Reilly and Pearson, Safari Books
Online has asked me to deliver a 1-hour webcast a couple of years ago
called "What is Python?". This was an online seminar based on a
session that I've delivered at numerous conferences in the past. It
will give you an idea of lecture style as well as an overview of the
material
covered in the course.

info:http://www.safaribooksonline.com/events/WhatIsPython.html
download (reg req'd):
http://www.safaribooksonline.com/Corporate/DownloadAndResources/webcastInfo.php?page=WhatIsPython
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

WHERE: near the San Francisco Airport (SFO/San Bruno), CA, USA

WEB:   http://cyberwebconsulting.com

FLYER: http://cyberwebconsulting.com/flyerPP1.pdf

LOCALS: easy freeway (101/280/380) with lots of parking plus public
transit (BART and CalTrain) access via the San Bruno stations, easily
accessible from all parts of the Bay Area

VISITORS: free shuttle to/from the airport, free high-speed internet,
free breakfast and regular evening receptions; fully-equipped suites

See website for costs, venue info, and registration. There is a
significant discounts available for full-time students, secondary
teachers, and others.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python Programming", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
    http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com


Re: [SEAPY] Call for October Python speaker (and location)

2011-09-21 Thread wesley chun
great! how long is your talk Oscar? in jonathan's message, it said 7-9p at
the venue, but this month it seems like a 1-hour talk followed by a 1-hour
brewfest. i just need to know how many slides i would need for the talk so i
can customize it for you guys.

as far as the venue goes, it looks like Fremont is going to win... we're
right under/next to the Fremont St bridge, so you can probably bike there.
parking is weird though so just be aware of that as it's in a private
business complex. having it here would be easier for me too as i don't make
it to Kirkland as much, but i wouldn't be opposed to holding it there at
some point cuz i know peeps from that office.


i'm offering my twice yearly hardcore intro+intermediate Python 3-day course
down in San Francisco again next month, so if you want me to convert your
friends & co-workers to Python, here's your chance. :-) totally convenient
(& free) from the airport:
http://sfbay.craigslist.org/sfc/cls/2495963854.html


cheers,
-wesley


On Wed, Sep 21, 2011 at 5:39 PM, Oscar Baechler wrote:

> Also +1 Fremont :)
>
> Wesley's talk sounds great to me!
>
>
> On Wed, Sep 21, 2011 at 10:27 AM, Richard Fuhr wrote:
>
>> +1 Fremont
>>
>>
>> On Wed, Sep 21, 2011 at 10:12 AM, Kevin LaTona wrote:
>>
>>> +1 Fremont
>>>
>>>
>>> On Sep 21, 2011, at 10:06 AM, Matt S. wrote:
>>>
>>>  +1 Fremont
>>>>
>>>> On Wed, Sep 21, 2011 at 9:21 AM, Cris Ewing  wrote:
>>>> +1 for Fremont
>>>>
>>>> c
>>>>
>>>> On Sep 20, 2011, at 10:43 PM, wesley chun wrote:
>>>>
>>>> > hi all,
>>>> >
>>>> > i lurk most of the time because i'm based out of silicon valley but
>>>> > visit SEA quite often to meet with my team up there. i'd like to come
>>>> > as a 1st-timer to the meeting if you'll have me, and perhaps before
>>>> > Oscar's interesting talk, i can give a quick recap/review of what's
>>>> > going with Python 3 anyway. i'm currently here in South America and
>>>> > will be giving a full keynote on this topic at both PyCon Argentina
>>>> > this weekend as well as PythonBrasil[7] next week.
>>>> >
>>>> > in the future, i should also be able to get Google to host some of the
>>>> > meetings. would y'all prefer to meet in Fremont or Kirkland? (i need
>>>> > to start thinking about it and reaching out to the correct peeps.)
>>>> >
>>>> > thanks,
>>>> > -wesley
>>>> >
>>>> >
>>>> > On Wed, Sep 21, 2011 at 12:17 AM, Nathaniel Guy <
>>>> nattybum...@gmail.com> wrote:
>>>> >> I've already gotten us a room and I've been talking to Jon about it,
>>>> so no
>>>> >> worries. Jon, would you mind sending out the details?
>>>> >>
>>>> >> -Nat
>>>> >>
>>>> >> On Sep 20, 2011 5:04 PM, "Matt S."  wrote:
>>>> >>
>>>> >> I should be able to get a room at UW for the Oct. 13 meeting.
>>>> >>
>>>> >> On Wed, Sep 7, 2011 at 3:52 PM, Jonathan Mark 
>>>> wrote:
>>>> >>>
>>>> >>> Hi all... I am arrang...
>>>>
>>>

-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Python Web Development with Django", Addison Wesley, (c) 2009
http://withdjango.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com


Re: [SEAPY] Call for October Python speaker (and location)

2011-09-20 Thread wesley chun
hi all,

i lurk most of the time because i'm based out of silicon valley but
visit SEA quite often to meet with my team up there. i'd like to come
as a 1st-timer to the meeting if you'll have me, and perhaps before
Oscar's interesting talk, i can give a quick recap/review of what's
going with Python 3 anyway. i'm currently here in South America and
will be giving a full keynote on this topic at both PyCon Argentina
this weekend as well as PythonBrasil[7] next week.

in the future, i should also be able to get Google to host some of the
meetings. would y'all prefer to meet in Fremont or Kirkland? (i need
to start thinking about it and reaching out to the correct peeps.)

thanks,
-wesley


On Wed, Sep 21, 2011 at 12:17 AM, Nathaniel Guy  wrote:
> I've already gotten us a room and I've been talking to Jon about it, so no
> worries. Jon, would you mind sending out the details?
>
> -Nat
>
> On Sep 20, 2011 5:04 PM, "Matt S."  wrote:
>
> I should be able to get a room at UW for the Oct. 13 meeting.
>
> On Wed, Sep 7, 2011 at 3:52 PM, Jonathan Mark  wrote:
>>
>> Hi all... I am arrang...



-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
    http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com


ANN: Intro+Intermediate Python course, SF, Oct 18-20

2011-07-25 Thread wesley chun
Need to get up-to-speed with Python as quickly and as in-depth as
possible? Already coding Python but still have areas of uncertainty
you need to fill? Then come join me, Wesley Chun, author of
Prentice-Hall's bestseller "Core Python" for a comprehensive
intro/intermediate course coming up this May in Northern California,
then enjoy a beautiful Fall weekend afterwards in San Francisco, the
beautiful city by the bay.

Please pass on this note to whomever you think may be interested. I
look forward to meeting you and your colleagues! Feel free to pass
around the PDF flyer linked down below. Write if you have questions.

Since I hate spam, I'll only send out one reminder as the date gets
closer.

(Comprehensive) Intro+Intermediate Python
Tue-Thu, 2011 Oct 18-20, 9am-5pm

Hope to meet you soon!
-Wesley

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(COMPREHENSIVE) INTRO+INTERMEDIATE PYTHON

Although this course may appear to those new to Python, it is also
perfect for those who have tinkered with it and want to "fill in the
gaps" and/or want to get more in-depth formal training.  It combines
the best of both an introduction to the language as well as a "Python
Internals" training course.

We will immerse you in the world of Python in only a few days, showing
you more than just its syntax (which you don't really need a book to
learn, right?). Knowing more about how Python works under the covers,
including the relationship between data objects and memory management,
will make you a much more effective Python programmer coming out of
the gate. 3 hands-on labs each day will help hammer the concepts home.

Come find out why Google, Yahoo!, Disney, ILM/LucasFilm, VMware,
NASA, Ubuntu, YouTube, and Red Hat all use Python. Users supporting or
jumping to Plone, Zope, TurboGears, Pylons, Django, Google App Engine,
Jython, IronPython, and Mailman will also benefit!

PREVIEW 1: you will find (and can download) a video clip of a
class session recorded live to get an idea of my lecture style and
the interactive classroom environment (as well as sign-up) at:

http://cyberwebconsulting.com

PREVIEW 2: Partnering with O'Reilly and Pearson, Safari Books
Online has asked me to deliver a 1-hour webcast a couple of years ago
called "What is Python?". This was an online seminar based on a
session that I've delivered at numerous conferences in the past. It
will give you an idea of lecture style as well as an overview of the
material
covered in the course.

info:http://www.safaribooksonline.com/events/WhatIsPython.html
download (reg req'd):
http://www.safaribooksonline.com/Corporate/DownloadAndResources/webcastInfo.php?page=WhatIsPython
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

WHERE: near the San Francisco Airport (SFO/San Bruno), CA, USA

WEB:   http://cyberwebconsulting.com

FLYER: http://cyberwebconsulting.com/flyerPP1.pdf

LOCALS: easy freeway (101/280/380) with lots of parking plus public
transit (BART and CalTrain) access via the San Bruno stations, easily
accessible from all parts of the Bay Area

VISITORS: free shuttle to/from the airport, free high-speed internet,
free breakfast and regular evening receptions; fully-equipped suites

See website for costs, venue info, and registration. There is a
significant discounts available for full-time students, secondary
teachers, and others.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python Programming", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
    http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
-- 
http://mail.python.org/mailman/listinfo/python-announce-list

Support the Python Software Foundation:
http://www.python.org/psf/donations/


ANN: Intro+Intermediate Python course, SF, Oct 18-20

2011-07-25 Thread wesley chun
Need to get up-to-speed with Python as quickly and as in-depth as
possible? Already coding Python but still have areas of uncertainty
you need to fill? Then come join me, Wesley Chun, author of
Prentice-Hall's bestseller "Core Python" for a comprehensive
intro/intermediate course coming up this May in Northern California,
then enjoy a beautiful Fall weekend afterwards in San Francisco, the
beautiful city by the bay.

Please pass on this note to whomever you think may be interested. I
look forward to meeting you and your colleagues! Feel free to pass
around the PDF flyer linked down below. Write if you have questions.

Since I hate spam, I'll only send out one reminder as the date gets
closer.

(Comprehensive) Intro+Intermediate Python
Tue-Thu, 2011 Oct 18-20, 9am-5pm

Hope to meet you soon!
-Wesley

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(COMPREHENSIVE) INTRO+INTERMEDIATE PYTHON

Although this course may appear to those new to Python, it is also
perfect for those who have tinkered with it and want to "fill in the
gaps" and/or want to get more in-depth formal training.  It combines
the best of both an introduction to the language as well as a "Python
Internals" training course.

We will immerse you in the world of Python in only a few days, showing
you more than just its syntax (which you don't really need a book to
learn, right?). Knowing more about how Python works under the covers,
including the relationship between data objects and memory management,
will make you a much more effective Python programmer coming out of
the gate. 3 hands-on labs each day will help hammer the concepts home.

Come find out why Google, Yahoo!, Disney, ILM/LucasFilm, VMware,
NASA, Ubuntu, YouTube, and Red Hat all use Python. Users supporting or
jumping to Plone, Zope, TurboGears, Pylons, Django, Google App Engine,
Jython, IronPython, and Mailman will also benefit!

PREVIEW 1: you will find (and can download) a video clip of a
class session recorded live to get an idea of my lecture style and
the interactive classroom environment (as well as sign-up) at:

http://cyberwebconsulting.com

PREVIEW 2: Partnering with O'Reilly and Pearson, Safari Books
Online has asked me to deliver a 1-hour webcast a couple of years ago
called "What is Python?". This was an online seminar based on a
session that I've delivered at numerous conferences in the past. It
will give you an idea of lecture style as well as an overview of the
material
covered in the course.

info:http://www.safaribooksonline.com/events/WhatIsPython.html
download (reg req'd):
http://www.safaribooksonline.com/Corporate/DownloadAndResources/webcastInfo.php?page=WhatIsPython
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

WHERE: near the San Francisco Airport (SFO/San Bruno), CA, USA

WEB:   http://cyberwebconsulting.com

FLYER: http://cyberwebconsulting.com/flyerPP1.pdf

LOCALS: easy freeway (101/280/380) with lots of parking plus public
transit (BART and CalTrain) access via the San Bruno stations, easily
accessible from all parts of the Bay Area

VISITORS: free shuttle to/from the airport, free high-speed internet,
free breakfast and regular evening receptions; fully-equipped suites

See website for costs, venue info, and registration. There is a
significant discounts available for full-time students, secondary
teachers, and others.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python Programming", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
    http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: [Tutor] What's the difference between %s and %r?

2011-07-23 Thread wesley chun
i forgot to define these:

str() - printable/human-readable string representation of an object
repr() - evaluatable string representation of an object (can "eval()"
it, meaning it is a string representation that evaluates to a Python
object)

in other words:

>>>> x = 'foo'
>>>> str(x)
> 'foo'
>>>> repr(x)
> "'foo'"

eval(str(x)) is not a valid Python object (you'll get a NameError)
while eval(repr(x)) *is* a valid Python object (you'll get a string
'foo'):

>>> eval('foo')
Traceback (most recent call last):
  File "", line 1, in 
  File "", line 1, in 
NameError: name 'foo' is not defined
>>> eval("'foo'")
'foo'

-wesley


On Sat, Jul 23, 2011 at 12:06 PM, wesley chun  wrote:
> %s = send object to str() first then drop it into the string
> %r = send object to repr() first then drop it into the string
> pretty straightforward:
>>>> x = 'foo'
>>>> str(x)
> 'foo'
>>>> repr(x)
> "'foo'"
> why do people do %r at all? to get the quotes for free: :-)
>>>> x = 'Python'
>>>> print "What is this '%s' language?" % x
> What is this 'Python' language?
>>>> print "What is this %r language?" % x
> What is this 'Python' language?


-- 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Python Web Development with Django", Addison Wesley, (c) 2009
    http://withdjango.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] What's the difference between %s and %r?

2011-07-23 Thread wesley chun
%s = send object to str() first then drop it into the string
%r = send object to repr() first then drop it into the string

pretty straightforward:

>>> x = 'foo'
>>> str(x)
'foo'
>>> repr(x)
"'foo'"

why do people do %r at all? to get the quotes for free: :-)

>>> x = 'Python'
>>> print "What is this '%s' language?" % x
What is this 'Python' language?
>>> print "What is this %r language?" % x
What is this 'Python' language?

cheers,
-- wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python", Prentice Hall, (c)2007,2001
"Python Fundamentals", Prentice Hall, (c)2009
http://corepython.com

wesley.chun : wescpy-gmail.com : @wescpy
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


  1   2   3   4   5   6   >