WordPress Plugin Activate Link Goes To Old Version – Invalid Plugin Header
-
Hi, I built a plugin for WooCommerce and WordPress. It works fine but I found that when you install it through the plugin directory and you click activate, it gives an error: Invalid Plugin Header.
The activation link also goes to version 1.0.1 where it should go to version 1.0.6 which is the latest version.
After Google a bit I found that the activation link that points to an old version might cause the problem.
Does anyone know how to fix that?
Thanks!
The page I need help with: [log in to see the link]
-
When I download your plugin, I find your history in the .zip file rather than only the current version. I suspect you’ve mis-done something in your SVN.
https://developer.ww.wp.xz.cn/plugins/wordpress-org/how-to-use-subversion/
$ unzip woo-tracking-the-courier-guy.zip Archive: woo-tracking-the-courier-guy.zip creating: woo-tracking-the-courier-guy/ creating: woo-tracking-the-courier-guy/1.0.0/ inflating: woo-tracking-the-courier-guy/1.0.0/readme.txt inflating: woo-tracking-the-courier-guy/1.0.0/woo-tracking-the-courier-guy.php creating: woo-tracking-the-courier-guy/1.0.1/ inflating: woo-tracking-the-courier-guy/1.0.1/readme.txt inflating: woo-tracking-the-courier-guy/1.0.1/woo-tracking-the-courier-guy.php creating: woo-tracking-the-courier-guy/1.0.2/ inflating: woo-tracking-the-courier-guy/1.0.2/readme.txt inflating: woo-tracking-the-courier-guy/1.0.2/woo-tracking-the-courier-guy.php creating: woo-tracking-the-courier-guy/1.0.3/ inflating: woo-tracking-the-courier-guy/1.0.3/readme.txt inflating: woo-tracking-the-courier-guy/1.0.3/woo-tracking-the-courier-guy.php creating: woo-tracking-the-courier-guy/1.0.4/ inflating: woo-tracking-the-courier-guy/1.0.4/readme.txt inflating: woo-tracking-the-courier-guy/1.0.4/woo-tracking-the-courier-guy.php creating: woo-tracking-the-courier-guy/1.0.5/ inflating: woo-tracking-the-courier-guy/1.0.5/readme.txt inflating: woo-tracking-the-courier-guy/1.0.5/woo-tracking-the-courier-guy.php inflating: woo-tracking-the-courier-guy/readme.txt inflating: woo-tracking-the-courier-guy/woo-tracking-the-courier-guy.phpFile svn folder looks like this:
woo-tracking-the-courier-guy >
> assets
> branches
> tags
> trunk
> 1.0.0
> 1.0.1
> 1.0.2
> 1.0.3
> 1.0.4
> 1.0.5
> readme.txt
> woo-tracking-the-courier-guy.phpIs that wrong?
- woo-tracking-the-courier-guy
- assets
- branches
- tags
- trunk
- 1.0.0
- 1.0.1
- 1.0.2
- 1.0.3
- 1.0.4
- 1.0.5
- readme.txt
- woo-tracking-the-courier-guy.php
Hiya,
I had a look, and yes your SVN directories are unfortunately a bit out of whack, to put it nicely đ
You have all your version directories (
1.0.0,1.0.1etc) inside thetrunkdirectory, these should go inside oftags.You’ve also marked
1.0.6as the stable tag, this does not exist which makes us use the entiretrunkdirectory as a fallback.So to fix this, move all your version directories to the proper
tagsparent folder, and then make sure the stable tag intrunk/readme.txtis a folder that exists in thetags/directory.Yeah, your SVN is completely busted. You have multiple versions in /trunk instead of in /tags where they belong.
You need to fix your SVN. If you need help, email plugins at wordpress org for assistance.
Yeah, you’re *really* doing it wrong.
https://plugins.trac.ww.wp.xz.cn/changeset/1781406/woo-tracking-the-courier-guy
Stop doing anything. You’re not fixing it this way.
Email plugins (at) wordpress (dot) org and we’ll explain the problem to you. I’ll even go in and fix it for you. But email us.
-
This reply was modified 8 years, 5 months ago by
Steven Stern (sterndata).
Okay I think I have fixed it.
I just want to confirm,
Should /tags contain all the version directories in there like this:
1.0.0
1.0.1
1.0.2
1.0.3
1.0.4
1.0.5
And the latest version 1.0.6What should the trunk directory look like?
Check your email. I committed a fix for you and emailed you about what I did to clean it up. đ
Your latest commit broke it again, actually. You need to put the /tags/1.0.6 back.
Currently my trunk directory has got readme.txt and woo-tracking-the-courier-guy.php
Is that wrong?
@francdore No, that is correct and what you want to have.
– /trunk contains the raw plugin, latest version, with no subdirectories.
– /tags contains various snapshots of the plugin at points in time. Usually these are in subdirectories named after the version. /tags/1.0.0 and /tags/1.0.1 and so forth.
– The /trunk/readme.txt file has a Stable Tag header line. This points to the current “Stable” version.
— If it says “1.0.6” then /tags/1.0.6 is the stable version
— If it says “trunk” then /trunk is the stable version
— It if says “nonsense” and /tags/nonsense does not exist, then /trunk is the stable version
– The stable version is the one we use to build the ZIP file that users receive.Right now, you have Stable tag set to 1.0.6, but you don’t have a /tags/1.0.6 directory.
Sorry I was trying to fix it on my end as well.
Okay so I did a SVN update and my tags folder has got version 1.0.0 to 1.0.5
My trunk folder has got readme.txt and the php file in there.
Should my tags folder contain a directory 1.0.6 too which is the latest version.
Should my tags folder contain a directory 1.0.6 too which is the latest version.
Yes, if you have “Stable tag: 1.0.6” then there should be a /tags/1.0.6 directory with version 1.0.6 of the plugin in it.
Other than that, you’re looking good now.
Okay so I need to copy the latest stable version into tags/1.0.6/
Yep. Looking good now with this change:
https://plugins.trac.ww.wp.xz.cn/changeset/1781438/woo-tracking-the-courier-guy
Yeah so the last commit I did should fix it.
Thanks for the help! Now I know what it should look like!
The topic ‘WordPress Plugin Activate Link Goes To Old Version – Invalid Plugin Header’ is closed to new replies.