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 628473
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T19:38:27+00:00 2026-05-13T19:38:27+00:00

I have two separate python scripts. One is for getting user location information (which

  • 0

I have two separate python scripts. One is for getting user location
information (which I get from web based geofeed provider.User Gsm is registerd
with that services).Another is for retrieving lastfm user track history.I have already
able to get user location data and user music track information.

Goal is to map those two script in such a way that I could be
able to make relation from those information” Users in certain location are listening certain music in certain time”.

Can anybody have nice idea to get this out?Thanks in advance!

  • 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-13T19:38:27+00:00Added an answer on May 13, 2026 at 7:38 pm

    Write a third script that import both of the other as modules, and make sure each module’s functionality is embodied in a function (as is Python’s best practice), not just “floating” as module-level code — a module’s top-level statements should usually be limited to import, from, def, class, and simple assignments of names to constants (possibly initial values for global variables), with all actual logic within functions and classes.

    So in your third script, after importing the other two as modules, you have a main function that calls the operating functions of the others to get location and track info, calls a function from standard module datetime (e.g. datetime.datetime.now()) — or possibly time — to get the current time, and finally formats all this information in the way you desire and writes it somewhere (where and how do you want to “publish” this info?).

    At the end of the script you do

    if __name__ == '__main__':
        main()
    

    which is the usual Python idiom to ensure the module’s main function executes when the file’s being used as the main script rather than just being imported from elsewhere.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 460k
  • Answers 460k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer You could do this with a RequestBuilder -- just request… May 15, 2026 at 11:53 pm
  • Editorial Team
    Editorial Team added an answer There are there solutions here: AJAX: Like Marc explained. An… May 15, 2026 at 11:53 pm
  • Editorial Team
    Editorial Team added an answer If you don't need to invent the wheel: http://jqueryui.com/demos/sortable May 15, 2026 at 11:53 pm

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.