Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 788019
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T21:17:44+00:00 2026-05-14T21:17:44+00:00

I am having trouble upgrading my session token in google app engine if my

  • 0

I am having trouble upgrading my session token in google app engine if my user is not logged into my application using the google accounts user api. If the user is currently logged in then it functions perfectly.

If not then i am getting this error:

Traceback (most recent call last):
  File "/base/python_runtime/python_lib/versions/1/google/appengine/ext/webapp/__init__.py", line 511, in __call__
    handler.get(*groups)
  File "/base/data/home/apps/5th-anniversary/1.341853888797531127/main.py", line 78, in get
    u.upgradeToken(self)
  File "/base/data/home/apps/5th-anniversary/1.341853888797531127/upload.py", line 47, in upgradeToken
    client.UpgradeToSessionToken()
  File "/base/data/home/apps/5th-anniversary/1.341853888797531127/gdata/service.py", line 903, in UpgradeToSessionToken
    raise NonAuthSubToken
NonAuthSubToken 

What are my best options here? I do not want the user to have to log into the google accounts api and then the youtube site to upload a video.

here is my method for updating the token:

def upgradeToken(data,self):
    get = self.request.GET
    authsub_token = get['token']

    gdata.alt.appengine.run_on_appengine(client)

    client.SetAuthSubToken(authsub_token)
    client.UpgradeToSessionToken()

client is simply client = gdata.youtube.service.YouTubeService()

pretty sure i’m missing something on the authentication side but i can’t seem to see what, thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T21:17:45+00:00Added an answer on May 14, 2026 at 9:17 pm

    I solved this by using:

    client.UpgradeToSessionToken(gdata.auth.extract_auth_sub_token_from_url(self.request.url))
    

    but this raised another issue when building the upload form with

    GetFormUploadToken
    

    i receive:

    Traceback (most recent call last):
      File "/base/python_runtime/python_lib/versions/1/google/appengine/ext/webapp/__init__.py", line 513, in __call__
        handler.post(*groups)
      File "/base/data/home/apps/5th-anniversary/1.341859541699944556/upload.py", line 106, in post
        form = u.getUploadForm(self,title,description,keywords)
      File "/base/data/home/apps/5th-anniversary/1.341859541699944556/upload.py", line 65, in getUploadForm
        response = client.GetFormUploadToken(video_entry,'http://gdata.youtube.com/action/GetUploadToken')
      File "/base/data/home/apps/5th-anniversary/1.341859541699944556/gdata/youtube/service.py", line 716, in GetFormUploadToken
        raise YouTubeError(e.args[0])
    YouTubeError: {'status': 401L, 'body': '<HTML>\n<HEAD>\n<TITLE>User authentication required.</TITLE>\n</HEAD>\n<BODY BGCOLOR="#FFFFFF" TEXT="#000000">\n<H1>User authentication required.</H1>\n<H2>Error 401</H2>\n</BODY>\n</HTML>\n', 'reason': ''}
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I´m having trouble in creating a file and export to .yaml. I´m using Google
Having trouble with the binary_search function listed at the top. not sure where to
I have an application that was working fine with ror 2.3.x. I am having
Having trouble getting my form to UPDATE records in my database even after searching
Having trouble finding a solution for my situation here. Sorry if this has been
Still having trouble can you please help? This needs to be written in Visual
Im having trouble with json in mako. I do this: ${ to_json( dict( a
Im having trouble identifying my databases as correct and valid version of my model.
Im having trouble getting my head around the concept of the factory design pattern.
I'm uploading a rails site to bluehost, a site that works on my local

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.