Author Topic: Locus Actions - Google Drive?  (Read 2252 times)

Offline Bob Denny

  • More than Newbie
  • *
  • Posts: 80
    • View Profile
Locus Actions - Google Drive?
« on: March 25, 2014, 04:49:52 »
Maybe this is a wish list. Locus Actions will save my soul. I have 15 tablets to set up with maps, points, and settings. Now I realize I can set things up so the newbie users can do this with Locus Actions, fantastic!

I have the files (some over a gigabyte) to download on Google Drive. However, it appears that a Google Drive URL won't work?If the link is of the form locus-actions://https/drive.google.com/file/d/0B5ykixwFeOisY1RhZnpvV0czTUk/edit?usp=sharing it seems that Locus says "problem with file xxxxxx". If I move everything over to DropBox it is OK (both the locus-actions://.../xxx.xml link and the <source> link in the XML itself both DropBox.

I can move things to DropBox, but it is 12 Gb (lots of map tile sqlite DB files). Am I making a mistake with Google Drive or are the URLs that they use not working with Locus Actions?
 

Offline Menion

  • Locus team
  • Professor of Locus
  • *****
  • Posts: 12602
  • Thanked: 835 times
    • View Profile
    • http://www.asamm.com
  • Device: Pixel 5, A12
Re: Locus Actions - Google Drive?
« Reply #1 on: March 25, 2014, 10:52:25 »
As I see, your URL isn't visible for public as it have to be to make it work.

https://drive.google.com/file/d/0B5ykixwFeOisY1RhZnpvV0czTUk/edit?usp=sharing
- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 final download
 

Offline Bob Denny

  • More than Newbie
  • *
  • Posts: 80
    • View Profile
Re: Locus Actions - Google Drive?
« Reply #2 on: March 25, 2014, 13:10:44 »
My mistake, I guess I pasted the wrong link into my message here, was trying to point to a file in the GDrive Public folder. Let me research this and set up a test for you... I had moved things to DropBox Public where it works OK. I am on the iPad now, will be in my office in a couple of hours...
 

Offline Menion

  • Locus team
  • Professor of Locus
  • *****
  • Posts: 12602
  • Thanked: 835 times
    • View Profile
    • http://www.asamm.com
  • Device: Pixel 5, A12
Re: Locus Actions - Google Drive?
« Reply #3 on: March 25, 2014, 14:11:01 »
No problem

Also please consider placing basic ideas, questions etc. on Help Desk - http://help.locusmap.eu/

- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 final download
 

Offline Bob Denny

  • More than Newbie
  • *
  • Posts: 80
    • View Profile
Re: Locus Actions - Google Drive?
« Reply #4 on: March 25, 2014, 15:56:58 »
Again I am sorry for not using helpdesk... but this is not "basic" I think:

(1) You must convert your "sharing URL" from GDrive into a "direct download" URL. This is typical Google, they go 90% and then stop leaving some key bit of info for the user to "discover". So for example (the link to the XML file):

https://drive.google.com/file/d/0B5ykixwFeOisZFhaaXh2QzhfWXc/edit?usp=sharing

must be changed to

https://docs.google.com/uc?export=download&id=0B5ykixwFeOisZFhaaXh2QzhfWXc

I tested both "download" links in a browser and they work. The files are in my Public folder on GDrive.

(2) Now I made up this HTML which you can find at http://solo.dc3.com/locustest.html
Code: [Select]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Test of Locus Actions</title>
</head>
<body>
<p>Hello test!</p>
<p><a href="locus-actions://https/dl.dropboxusercontent.com/u/8209159/test.xml">Download Locus Settings (Dropbox)</a></p>
<p><a href="locus-actions://https/docs.google.com/uc?export=download&id=0B5ykixwFeOisZFhaaXh2QzhfWXc">Download Locus Settings (GDrive)</a></p>
</body>
</html>

(3) And here is the XML file for the final part
Code: [Select]
<?xml version="1.0" encoding="utf-8"?>
<locusActions>
  <download>
    <source size="11749">
      <![CDATA[https://docs.google.com/uc?export=download&id=0B5ykixwFeOisalpwZGtVODNwWWs]]>
    </source>
    <dest><![CDATA[/backup/ActionsTest.zip]]></dest>
  </download>
</locusActions>

Now clicking on the Download Locus Settings (GDrive) (<= this might work right here!) does trigger the intent and start LocusPro, however, immediately is shows an error with the XML file (more below this image):

  <-click

Note that the URL in the error message is all lower case! Perhaps that is just the error message display, but if the URL is truly being converted to lower case before using it, then that would cause a problem because the GDrive ID is case-sensitive. This is just a guess... but I cannot get to the XML file (the URL in the error message is for the XML file not the final file to download to Locus).

I hope I have given you enough info this time, and again I am sorry for the stupid post before.
« Last Edit: March 25, 2014, 18:59:50 by gynta »
 

Offline Menion

  • Locus team
  • Professor of Locus
  • *****
  • Posts: 12602
  • Thanked: 835 times
    • View Profile
    • http://www.asamm.com
  • Device: Pixel 5, A12
Re: Locus Actions - Google Drive?
« Reply #5 on: March 25, 2014, 20:50:23 »
ah sorry, problem is really in case sensitivity. I change it during one test and till now, no one had such problem. After fix it works correctly.

Probably in friday will be version with a lot more fixes, so this one will work also.
- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 final download
 

Offline Bob Denny

  • More than Newbie
  • *
  • Posts: 80
    • View Profile
Re: Locus Actions - Google Drive?
« Reply #6 on: March 25, 2014, 21:58:13 »
Excellent, can't ask for better response and support!

« Last Edit: March 26, 2014, 06:24:41 by Bob Denny »