New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add automatic update support #2531

Closed
arantius opened this Issue Jul 25, 2017 · 15 comments

Comments

Projects
None yet
5 participants
@arantius
Collaborator

arantius commented Jul 25, 2017

n.b.

@arantius arantius added this to the 4.0 milestone Jul 25, 2017

@arantius arantius modified the milestones: 4.0, 4.x Aug 21, 2017

@arantius arantius removed this from the 4.x milestone Jan 19, 2018

@arantius arantius added this to the Features milestone Feb 22, 2018

@i-cant-git

This comment has been minimized.

Show comment
Hide comment
@i-cant-git

i-cant-git May 22, 2018

"Manual update check" link in browser action menu:

check

i-cant-git commented May 22, 2018

"Manual update check" link in browser action menu:

check

@Nothing4You

This comment has been minimized.

Show comment
Hide comment
@Nothing4You

Nothing4You May 22, 2018

@i-cant-git that doesn't automatically get triggered, only when you click it.

Nothing4You commented May 22, 2018

@i-cant-git that doesn't automatically get triggered, only when you click it.

@arantius

This comment has been minimized.

Show comment
Hide comment
@arantius

arantius May 22, 2018

Collaborator

Yes any implementation for this would have scheduled and manually triggered updates as an option. The point is the ability to download, check whether it's newer, then install if so.

Collaborator

arantius commented May 22, 2018

Yes any implementation for this would have scheduled and manually triggered updates as an option. The point is the ability to download, check whether it's newer, then install if so.

@i-cant-git

This comment has been minimized.

Show comment
Hide comment
@i-cant-git

i-cant-git May 25, 2018

I shared here because #1743 is closed.

i-cant-git commented May 25, 2018

I shared here because #1743 is closed.

@jlpetz

This comment has been minimized.

Show comment
Hide comment
@jlpetz

jlpetz Jun 27, 2018

Any updates on when this could potentially be top of the issues list(milestone/time-frame)?

While GM4 is good, this is a major drawback for me in it's usability. Revisions to scripts occur quite frequently in my environment and without auto-updating(like we had in GM v3) it's tedious and can often lead to breakages. ie. When a website updates it's structure/content and the GM does not update in sync to handle the changes in the website(because you need to manually re-install it).

jlpetz commented Jun 27, 2018

Any updates on when this could potentially be top of the issues list(milestone/time-frame)?

While GM4 is good, this is a major drawback for me in it's usability. Revisions to scripts occur quite frequently in my environment and without auto-updating(like we had in GM v3) it's tedious and can often lead to breakages. ie. When a website updates it's structure/content and the GM does not update in sync to handle the changes in the website(because you need to manually re-install it).

@arantius arantius modified the milestones: Features, 4.7 Jun 29, 2018

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 20, 2018

@arantius

This comment has been minimized.

Show comment
Hide comment
@arantius

arantius Jul 20, 2018

Collaborator

I'm actively working on this; see b0b93bc .

Remaining (at least):

  • A UI control to manually check for updates, now.
  • A UI control to opt out of (default on) update checks, per script.
  • Skipping automatic checks, when the script has been edited since install time.
Collaborator

arantius commented Jul 20, 2018

I'm actively working on this; see b0b93bc .

Remaining (at least):

  • A UI control to manually check for updates, now.
  • A UI control to opt out of (default on) update checks, per script.
  • Skipping automatic checks, when the script has been edited since install time.

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 20, 2018

Track install and edit time.
Don't (auto) update a script that's been edited since install time.

Refs #2531

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 20, 2018

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 20, 2018

@arantius

This comment has been minimized.

Show comment
Hide comment
@arantius

arantius Jul 25, 2018

Collaborator

There should be a (more?) progress indicator for updates. Including: the script's data should update in-place, if you click "update now" and there is indeed an update available.

Collaborator

arantius commented Jul 25, 2018

There should be a (more?) progress indicator for updates. Including: the script's data should update in-place, if you click "update now" and there is indeed an update available.

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 27, 2018

Update message documentation.
Describe `UserScriptUpdateNow`, and update it to make the caller more aware of the result.

Refs #2531

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 27, 2018

Add example script servers.
Including one to help in testing script (auto) updating.

Refs #2531

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 27, 2018

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 27, 2018

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 27, 2018

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 27, 2018

@arantius

This comment has been minimized.

Show comment
Hide comment
@arantius

arantius Jul 27, 2018

Collaborator

The vast majority of this is in the current (2018.07.25) nightly ( https://arantius.com/misc/gm-nightly/ ), the rest will be in today's. I'd appreciate any and all testing.

Collaborator

arantius commented Jul 27, 2018

The vast majority of this is in the current (2018.07.25) nightly ( https://arantius.com/misc/gm-nightly/ ), the rest will be in today's. I'd appreciate any and all testing.

@jlpetz

This comment has been minimized.

Show comment
Hide comment
@jlpetz

jlpetz Jul 28, 2018

I was going to ask if you wanted a tester. I’ll see if I can get the nightly release installed and get back to you Monday. Thanks.

jlpetz commented Jul 28, 2018

I was going to ask if you wanted a tester. I’ll see if I can get the nightly release installed and get back to you Monday. Thanks.

@Eselce

This comment has been minimized.

Show comment
Hide comment
@Eselce

Eselce Jul 28, 2018

Contributor

Just some unfiltered impressions (tried to immitate a dummy user):

  • What about displaying the source file name (full path) in the install window?
  • Update now didn't work without @updateURL (no reaction)
  • Added @updateURL => Seemed to have worked... (tbc)
  • As I edited the script: Got a dialog as expected
  • Problem: Pressing OK didn't seem to overwrite the script
  • Therefore, the next time, the dialog was displayed again (File not changed? Flag still set?)
  • I'd prefer to have Edit menu item back on the top, maybe second position; especially far away from Uninstall, and with update stuff more to the bottom
  • ...
Contributor

Eselce commented Jul 28, 2018

Just some unfiltered impressions (tried to immitate a dummy user):

  • What about displaying the source file name (full path) in the install window?
  • Update now didn't work without @updateURL (no reaction)
  • Added @updateURL => Seemed to have worked... (tbc)
  • As I edited the script: Got a dialog as expected
  • Problem: Pressing OK didn't seem to overwrite the script
  • Therefore, the next time, the dialog was displayed again (File not changed? Flag still set?)
  • I'd prefer to have Edit menu item back on the top, maybe second position; especially far away from Uninstall, and with update stuff more to the bottom
  • ...
@arantius

This comment has been minimized.

Show comment
Hide comment
@arantius

arantius Jul 29, 2018

Collaborator

What about displaying the source file name (full path) in the install window?

This change has nothing to do with the install window.

Update now didn't work without @updateURL (no reaction)
Added @updateURL => Seemed to have worked... (tbc)

You're confused. GM 4 doesn't do anything with that value. (It's still in the parser, but nothing else uses it in any way.)

As I edited the script: Got a dialog as expected
Problem: Pressing OK didn't seem to overwrite the script
Therefore, the next time, the dialog was displayed again (File not changed? Flag still set?)

Among all the rest of your comments this sounds legitimate (but it was hard to read as three seemingly-independent bullet points -- they only make sense as one unit).

I'd prefer to have Edit menu item back on the top, maybe second position; especially far away from Uninstall, and with update stuff more to the bottom

Take a look at the latest nightly including work for #2728 .

Collaborator

arantius commented Jul 29, 2018

What about displaying the source file name (full path) in the install window?

This change has nothing to do with the install window.

Update now didn't work without @updateURL (no reaction)
Added @updateURL => Seemed to have worked... (tbc)

You're confused. GM 4 doesn't do anything with that value. (It's still in the parser, but nothing else uses it in any way.)

As I edited the script: Got a dialog as expected
Problem: Pressing OK didn't seem to overwrite the script
Therefore, the next time, the dialog was displayed again (File not changed? Flag still set?)

Among all the rest of your comments this sounds legitimate (but it was hard to read as three seemingly-independent bullet points -- they only make sense as one unit).

I'd prefer to have Edit menu item back on the top, maybe second position; especially far away from Uninstall, and with update stuff more to the bottom

Take a look at the latest nightly including work for #2728 .

@Eselce

This comment has been minimized.

Show comment
Hide comment
@Eselce

Eselce Jul 30, 2018

Contributor

Well, as I said, these bullet points were created after clearing my brain, very nightly, unrelated, unfiltered, unsorted, pretty much of a brainstorm in the night. And as it went confusing with that failing update feature, it left only one valid point (the last one), that was not very helpful. Need time for a detailed examination...

To the last item: The 07-27 (really? My previous install date was 07-28!) version is much better. Congratulations!

Just one thing though: As I said, I've changed that script. If I click Update now, the dialog box appears (fine) and I click OK. Although my (edited) script is newer than the source path script, I would really expect to have the script overwritten by the original version with that source path, as I actively request to update that file now...

Contributor

Eselce commented Jul 30, 2018

Well, as I said, these bullet points were created after clearing my brain, very nightly, unrelated, unfiltered, unsorted, pretty much of a brainstorm in the night. And as it went confusing with that failing update feature, it left only one valid point (the last one), that was not very helpful. Need time for a detailed examination...

To the last item: The 07-27 (really? My previous install date was 07-28!) version is much better. Congratulations!

Just one thing though: As I said, I've changed that script. If I click Update now, the dialog box appears (fine) and I click OK. Although my (edited) script is newer than the source path script, I would really expect to have the script overwritten by the original version with that source path, as I actively request to update that file now...

@jlpetz

This comment has been minimized.

Show comment
Hide comment
@jlpetz

jlpetz Jul 30, 2018

Dummy user feedback also. I know this is the initial release so this might sound overly critical, given I'm sure their is more to come. So let me start by saying thank you for adding updates back. As I called out before this is something that helps me greatly.

Feedback

  1. Manually updating a single script worked fine. ie. Navigating to the script -> then "User script options" -> then "Update Now". New version was pulled down as expected and I updated three scripts this way.

  2. There is no indication if a script has been automatic updated unless I am just impatient and need to wait longer for the auto update to run. There is also no indication when the last update check is running/last_run. I'm not sure if auto update happens every time the browsers starts or on a particular time interval/schedule(once a day, etc). It would be good to show this and perhaps make it configurable. I did try restarting the browser, but even after that I was able to manually update an old script(doing 1. above) so I doubt it checks on browser restart(unless it's checking is slow/delayed).

  3. Further to above(2.) it would be good to have a "Update all scripts now" button(ie. Trigger the auto update now on everything). Given you have "update now" on each script you could potentially include the same in the global "Greasemonkey Options" sub menu.

  4. This is a minor one. In the later GM3 release the interface showed the last time the script was updated. I found this handy as often if you started getting a problem you could quickly check that timestamp and correlate it back to a bad user script release/update. Script authors often don't document in the script the release notes/dates, so this makes seeing at a quick glance which scripts had recently changes that could impact you easy. You could probably add this to the nested user script menu near the "Update now" button, but I think this detail and other details/options(like exclude from auto updates) were better displayed in a table like the GM3 Manage scripts interface. So you can see all the scripts at once and sort them by the different details/options to find the one(s) you want. Example, you might have temporarily disabled auto updates a a few scripts due to a regression but don;t recall exactly which ones. Rather than going through the nested menu of every script to check you can just sort the table on "Auto update enabled"

jlpetz commented Jul 30, 2018

Dummy user feedback also. I know this is the initial release so this might sound overly critical, given I'm sure their is more to come. So let me start by saying thank you for adding updates back. As I called out before this is something that helps me greatly.

Feedback

  1. Manually updating a single script worked fine. ie. Navigating to the script -> then "User script options" -> then "Update Now". New version was pulled down as expected and I updated three scripts this way.

  2. There is no indication if a script has been automatic updated unless I am just impatient and need to wait longer for the auto update to run. There is also no indication when the last update check is running/last_run. I'm not sure if auto update happens every time the browsers starts or on a particular time interval/schedule(once a day, etc). It would be good to show this and perhaps make it configurable. I did try restarting the browser, but even after that I was able to manually update an old script(doing 1. above) so I doubt it checks on browser restart(unless it's checking is slow/delayed).

  3. Further to above(2.) it would be good to have a "Update all scripts now" button(ie. Trigger the auto update now on everything). Given you have "update now" on each script you could potentially include the same in the global "Greasemonkey Options" sub menu.

  4. This is a minor one. In the later GM3 release the interface showed the last time the script was updated. I found this handy as often if you started getting a problem you could quickly check that timestamp and correlate it back to a bad user script release/update. Script authors often don't document in the script the release notes/dates, so this makes seeing at a quick glance which scripts had recently changes that could impact you easy. You could probably add this to the nested user script menu near the "Update now" button, but I think this detail and other details/options(like exclude from auto updates) were better displayed in a table like the GM3 Manage scripts interface. So you can see all the scripts at once and sort them by the different details/options to find the one(s) you want. Example, you might have temporarily disabled auto updates a a few scripts due to a regression but don;t recall exactly which ones. Rather than going through the nested menu of every script to check you can just sort the table on "Auto update enabled"

@arantius

This comment has been minimized.

Show comment
Hide comment
@arantius

arantius Jul 31, 2018

Collaborator

Well, as I said, these bullet points were created after clearing my brain, very nightly, unrelated, unfiltered, unsorted, pretty much of a brainstorm in the night...

Fine, but what am I supposed to do with that? Just ignore it? You said it, so I responded.

There is no indication if a script has been automatic updated

I know. We have fewer UI options under WebExtensions. And is this really important? How would you want it to look/appear as it happens?

There is also no indication when the last update check is running/last_run. I'm not sure if auto update happens every time the browsers starts or on a particular time interval/schedule(once a day, etc).

This is intentional. It tries to be intelligent: checking frequently when scripts are likely to have changed, and infrequently when not (based on the history of checks).

it would be good to have a "Update all scripts now" button

Would you mind filing this as its own issue?

In the later GM3 release the interface showed the last time the script was updated. I found this handy as often if you started getting a problem you could quickly check that timestamp and correlate it back to a bad user script release/update.

Good point, will add.

Collaborator

arantius commented Jul 31, 2018

Well, as I said, these bullet points were created after clearing my brain, very nightly, unrelated, unfiltered, unsorted, pretty much of a brainstorm in the night...

Fine, but what am I supposed to do with that? Just ignore it? You said it, so I responded.

There is no indication if a script has been automatic updated

I know. We have fewer UI options under WebExtensions. And is this really important? How would you want it to look/appear as it happens?

There is also no indication when the last update check is running/last_run. I'm not sure if auto update happens every time the browsers starts or on a particular time interval/schedule(once a day, etc).

This is intentional. It tries to be intelligent: checking frequently when scripts are likely to have changed, and infrequently when not (based on the history of checks).

it would be good to have a "Update all scripts now" button

Would you mind filing this as its own issue?

In the later GM3 release the interface showed the last time the script was updated. I found this handy as often if you started getting a problem you could quickly check that timestamp and correlate it back to a bad user script release/update.

Good point, will add.

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 31, 2018

Update install time, when updating.
So that it will be newer than edit time, if necessary.

Refs #2531

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 31, 2018

Tweak auto update window selection.
Allow rapid checks when each finds a new version.  Continue exponentially decaying down towards more infrequent checks from ther.
In addition, do fuzzing last to make a flurry of checks even less likely.  (If we're shut down for a week, then every timer expires.  If several find an update, they'll now each check somewhere in 3 hours +/- 15% -- not all in exactly 3 hours.)

Refs #2531

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 31, 2018

arantius added a commit to arantius/greasemonkey that referenced this issue Jul 31, 2018

@arantius

This comment has been minimized.

Show comment
Hide comment
@arantius

arantius Aug 22, 2018

Collaborator

This seems to have been working well in nightlies for a while.

Collaborator

arantius commented Aug 22, 2018

This seems to have been working well in nightlies for a while.

@arantius arantius closed this Aug 22, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment