Extension talk:Push

From MediaWiki.org
Jump to: navigation, search

Is there a way to set up Push so that a user does not have to authenticate to use it? I am looking at the settings file and uncommented [*][push] and put that in the LocalSetting but it did not seem to have a effect.

Start a new discussion

Contents

Thread titleRepliesLast modified
Broadening File Support115:43, 4 March 2012
Error message - File push failed: The images parameter must be set117:42, 4 October 2011
Authentication question1012:27, 25 September 2011
Setting property/value via push process?515:38, 4 August 2011
push and logbook111:50, 9 July 2011
Upload files directly, not per URI116:05, 17 February 2011
Maintain target systems such like Special:Interwiki120:03, 18 December 2010
Issues with user-defined name-space320:01, 18 December 2010
Using SMW to select pages and then push via a template109:57, 14 December 2010

Broadening File Support

Hello, I've set up the Push extension with multiple wikis and I've been using it to update content from our master wiki. I notice in the javascript that the push function iterates over all the images included on the source page. Is there support for files other than images or is there a place in the extension to add more file extensions? I have .swf flash files embedded on the source page that do not get pushed to the target. Is there a way to push this file type? Thanks in advance!

Jhunter13 (talk)18:03, 2 March 2012

Most of the code would work perfectly fine with other file types, so it's not that hard to add, but it needs some additional logic, rather then simply adding some file extensions. The JS obtaining the images should obtain all files, but this needs some other API call. In fact I'm not fully sure you can get that info via the core MW API, so you might need to write your own module.

So this is not possible right now, but if someone where to throw some hours of dev time again it, it could definitely be added.

Jeroen De Dauw (talk)15:43, 4 March 2012
 

Error message - File push failed: The images parameter must be set

Hi there! I have installed this extension but I cannot seem to be able to get it to work... When trying to push a page, I get the following error: File push failed: The images parameter must be set. Any ideas? Help will be greatly appreciated!

Lenalg01:41, 4 October 2011

This is something I broke in the latest release apparently. I've fixed it now and created a new release. Upgrading your code should rid you of this issue :)

Jeroen De Dauw17:42, 4 October 2011
 

Authentication question

In your well written instructions, you document that your extension will not work from a MW.16 install:

"If you are running wikis on localhost, pushing from a MW 1.16 install will not work, due to an issue in Cookie::validateCookieDomain. It can be fixed by replacing this method by it's MW 1.17 equivalent."

Being something of a novice, could you outline (step by step) the procedure necessary for replacing the MW1.16 with its MW1.17 equivalent?

Thank you

64.79.137.14403:33, 17 September 2011

I should have been more clear and stated that what I would like are instructions for changing this process, not upgrading the entire MW itself (since my host does not yet support (or allow) MW 1.17.

Thanks

64.79.137.14404:53, 18 September 2011

This issue will only affect you when pushing from a local wiki, so you probably don't have to worry about it when you have a wiki at some host.

Jeroen De Dauw13:31, 18 September 2011

Jeroen,

Thanks for getting back to me...

What I prefer to do is work offline (on the local wiki) and then push the changes to the live. However, I did test from the live to the local and it just sits there saying it is pushing but nothing happens. Which I figured was probably due to a firewall setting on the local wiki side. I even looked into just updating both to v1.17 but the host for my live wiki does not support that version (yet).

So if there is a simple way to duplicate the 1.17 cookie in the 1.16 wiki I would appreciate a walk through... if not I understand and will just have to wait until my host decides to support 1.17.

Thanks,

Frank

64.79.137.14419:49, 18 September 2011

Get this file, and replace includes/HttpFunctions.php with it in your 1.16 install. Upgrading both to 1.17 might not work. There is some issue with pushing to 1.18 and later, which might also be on 1.17.

Jeroen De Dauw21:53, 18 September 2011

Jeroen,

Actually I had already tried that... still not working.

Error message is as follows:

"Could not obtain an edit token on the target wiki."

I have triple checked the URL for the live site, the login and password are working just fine, am able to edit/create document with no problem.

Any thoughts?

Frank

64.79.137.14404:48, 19 September 2011
 
 
 
 
 

Setting property/value via push process?

Is it possible that the push process can set a pair of properties and values, so information can be stored when and by whom the page was pushed?

MWJames09:49, 14 December 2010

Push currently does not allow for any modification of the source or additions to it. I can see the usefulness of this, and will probably add some hook at some point allowing other extensions to do just this. I don't have any plans on implementing such functionality myself though, as it's not needed by the client that's paying me to create Push.

Jeroen De Dauw09:54, 14 December 2010

I did add 2 simple hooks to allow easily adding such behaviour from outside of the extension. See here.

Jeroen De Dauw16:07, 19 December 2010

Why not a hook PushAPIAfterPush as well, to be able to modify something in the target wiki after import?

Danwe20:53, 10 July 2011

Indeed. I added 2 such hooks, see the hook docs and the commit.

Jeroen De Dauw17:04, 11 July 2011
 

Released version 1.1 with these hooks just now :)

Jeroen De Dauw15:38, 4 August 2011
 
 
 
 

push and logbook

Its a very nice and useful extension and we use it inside a wiki farm.

but helpful would be a information about pushed articles, like a push log history. a log file would be enough for the first steps.

93.194.239.10220:54, 9 March 2011

Interesting idea. Where would the push log be stored, and what info would each entry in the log contain?

In any case, can you fund the development of such a feature?

Jeroen De Dauw05:34, 10 March 2011
 

Upload files directly, not per URI

Is it possible to upload images directly, and not per URI? Latter variant doesn't work when pushing from a local wiki that's not accessible from the internet...

91.0.132.9808:48, 17 February 2011

Thanks for reporting this; I did some tests and you seem to be right. Will attempt to fix soonish.

Jeroen De Dauw16:05, 17 February 2011
 

Maintain target systems such like Special:Interwiki

Would it be possible that the push interface can use target systems from what is maintained in Special:Interwiki? If not so, maybe something like Special:Interwiki could be used as template in how to maintain target systems within MediaWiki, meaning system data can be maintained without changing the LocalSettings file.

MWJames19:23, 18 December 2010

I don't think using the interwiki links for this is a good idea, as you'll end up with some 20-ish push targets on most wikis, while you probably only care about one or a few. An interface to manage targets would be neat, but is not needed by my employer at this point.

Jeroen De Dauw20:03, 18 December 2010
 

Issues with user-defined name-space

Pushing within the main name-space works fine but in an user-defined name-space (such as define("NS_GLOSSARY", 160)) pushing does not work. An both system the name-space are created the same way and use the same name-space number.--MWJames 13:47, 18 December 2010 (UTC)

MWJames13:47, 18 December 2010

Can you provide some more info on what's going wrong?

Jeroen De Dauw14:46, 18 December 2010

While in the main name-space the creation and update of articles(pages) works fine but as stated earlier as soon if we create a new page or update an article in an user-defined name-space and try to push this to the other system, it does not create the article nor update it in the case it already exists. As the matter of fact their are no error message or failure messages at all to verify what went wrong.

Test scenarios

  1. Update an article that exists in both systems in the main name-space and push it through = it works fine.
  2. Create a new article in name-space "NS_GLOSSARY", try to push it = the article is not created in the target system.
  3. Create a new page in the main name-space, push it through = it works.

Conclusion for some reason, the pushing in name-space NS_GLOSSARY does not work as in cases where articles are stored in NS_MAIN. We also have tested other user-defined name-spaces with similar results.

NS_GLOSSARY is maintained such as

define("NS_GLOSSARY", 160);
define("NS_GLOSSARY_TALK", 161);
$wgExtraNamespaces[NS_GLOSSARY] = "Glossary";
$wgExtraNamespaces[NS_GLOSSARY_TALK] = "Glossary_talk";
$wgNamespaceProtection[NS_GLOSSARY] = array( 'editglossary' ); 
$wgNamespacesWithSubpages[NS_GLOSSARY] = true;            
$wgGroupPermissions['sysop']['editglossary'] = true;      

System environment: MediaWiki 1.17alpha (r78559), PHP 5.2.13 (apache2handler), MySQL 5.1.44-community, Push (Version 0.6 alpha) (r78559). Just in case $egPushLoginUsers and $egPushLoginPasswords have been maintained on both systems.

Hope this helps (maybe some debug message could be helpful...)

MWJames19:09, 18 December 2010

I replicated this namespace setup, and am not having any problems Pushing content. Nor do I see why it would fail using a custom namespace. What version of Push are you using?

Jeroen De Dauw20:01, 18 December 2010
 
 
 

Using SMW to select pages and then push via a template

Is there a way to process pages via a #ask statement and push those via a template? Meaning is there a way to call an API/tag function within the template that allows to push a page without interference of an user?

{{#ask:[[Modification date::>...]] [[Modification date::<...]] 
|?Modification date |format=template 
|template=Push pages |offset=0 }}
Process pages in template Push pages via some thing like {{#push ?? }}
MWJames09:48, 14 December 2010

Currently push actions can only be initiated via the tab interface and Special:Push. I think it'd be neat to have a "save and push" button when editing pages, but again, my client does not require this. Push does not have any integration with SMW; however, it would be cool if you cool select pages using SMW queries on Special:Push, similar to what DSMW does.

Jeroen De Dauw09:57, 14 December 2010
 
Personal tools
Namespaces

Variants
Actions
Navigation
Support
Download
Development
Communication
Print/export
Toolbox