Simple Machines Community Forum

General Community => Site Comments, Issues and Concerns => Topic started by: alex_qrlogin on October 20, 2017, 09:00:05 AM

Title: problem with submit new mod to site
Post by: alex_qrlogin on October 20, 2017, 09:00:05 AM
Hi All

I'm trying to put a modification and get an error:
An Error Has Occurred!
You must upload a package file containing package-info.xml which contains the package id when submitting a mod to this site

What is it?
package id is <id>alex_qrlogin:qrLogin</id>
Title: Re: problem with submit new mod to site
Post by: Shambles on October 20, 2017, 09:18:16 AM
What else is in your package-info.xml file? Can you paste the contents here?
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 20, 2017, 09:37:21 AM
<?xml version="1.0"?>
<!DOCTYPE package-info SYSTEM "http://www.simplemachines.org/xml/package-info">

<package-info xmlns="http://www.simplemachines.org/xml/package-info" xmlns:smf="http://www.simplemachines.org/">
<id>alex_qrlogin:qrLogin</id>
<name>qrLogin</name>
<type>modification</type>
<version>0.9.1</version>

<install for="2.0 - 2.0.99">
<redirect url="?action=qrlogin;qra=page">qrlogin intalled</redirect>
<readme lang="english">ReadMe.txt</readme>
<readme lang="russian-utf8">ReadMe.ru</readme>
<require-file name="qrlogin.php" destination="$sourcedir" />
<require-file name="qrlogin.template.php" destination="$themedir" />
<require-dir name="qrlogin" destination="$themedir" />
<require-file name="qrlogin.english.php" destination="$languagedir" />
<require-file name="qrlogin.russian-utf8.php" destination="$languagedir" />
<modification type="file">qrlogin.xml</modification>
<code type="inline">
<?php
// Settings
$smcFunc['db_query'](''"INSERT IGNORE INTO {db_prefix}settings VALUES ('qrlogin_del_http', '1')");
$smcFunc['db_query'](''"INSERT IGNORE INTO {db_prefix}settings VALUES ('qrlogin_login_timeout', '3')");
$smcFunc['db_query'](''"INSERT IGNORE INTO {db_prefix}settings VALUES ('qrlogin_timeout', '1')");
$smcFunc['db_query'](''"INSERT IGNORE INTO {db_prefix}settings VALUES ('qrlogin_poll_lifetime', '30')");
$smcFunc['db_query'](''"INSERT IGNORE INTO {db_prefix}settings VALUES ('qrlogin_post_timeout', '5')");
$smcFunc['db_query'](''"INSERT IGNORE INTO {db_prefix}settings VALUES ('qrlogin_qrcode_size', '128')");
// Create the qrLogin Table
$smcFunc['db_query'](''"CREATE TABLE IF NOT EXISTS {db_prefix}qrlogin(
    sid varchar(32) NOT NULL default '',
    uid int unsigned NOT NULL default 0,
    result smallint unsigned NOT NULL default 0,
    PRIMARY KEY  (sid)
)"
);
?>

</code>
</install>

<uninstall for="2.0 - 2.0.99">
<readme lang="english">ReadMe.txt</readme>
<readme lang="russian-utf8">ReadMe.ru</readme>
<remove-file name="$sourcedir/qrlogin.php" />
<remove-file name="$themedir/qrlogin.template.php" />
<remove-dir name="$themedir/qrlogin" />
<remove-file name="$languagedir/qrlogin.english.php" />
<remove-file name="$languagedir/qrlogin.russian-utf8.php" />
<modification type="file" reverse="true">qrlogin.xml</modification>
<code  type="inline">
<?php
// Settings
$smcFunc['db_query'](''"DELETE FROM {db_prefix}settings WHERE variable IN ('qrlogin_del_http', 'qrlogin_login_timeout', 'qrlogin_timeout', 'qrlogin_poll_lifetime', 'qrlogin_post_timeout', 'qrlogin_qrcode_size')");
// Delete the qrLogin Table
$smcFunc['db_query'](''"DROP TABLE  {db_prefix}qrlogin");
?>

</code>
</uninstall>
</package-info>
Title: Re: problem with submit new mod to site
Post by: Arantor on October 20, 2017, 09:40:51 AM
Can you upload the package here please?
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 20, 2017, 09:42:29 AM
Just was going to ;D
Title: Re: problem with submit new mod to site
Post by: Arantor on October 20, 2017, 09:53:20 AM
Your problem is that you've put it inside a folder. The package-info.xml file really should be in the top level of the zip file rather than in a folder.
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 20, 2017, 10:00:08 AM
You are sure?
In all the packages that I watched just such a structure ...
Can you confuse the presence inside another nested directory qrlogin?

ps - sorry - i understud)
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 20, 2017, 10:09:09 AM
changed archive
the result is the same ((
Title: Re: problem with submit new mod to site
Post by: Arantor on October 20, 2017, 10:25:14 AM
I'm sure that's how it's supposed to be. SMF doesn't always find it correctly if it's placed inside a folder though it tries - which is why we said several years ago it should always be done that way. (I used to be on the review team... 8 years ago. Eek.)

I'm trying to remember if _ is a valid character in the spec for package ids, but I don't remember for sure. Try taking it out.

Also, as a tip for the approvals process as it currently is, queries inline in the installer aren't recommended, database tables should be added with $smcFunc['db_create_table'] and indicated via a <database> tag so the uninstaller can ask the user whether to remove the data or not (and do it automatically without you having to explicitly have an uninstaller for that)

$smcFunc['db_insert'] is also capable of doing insertions for you, though you could take it further and simply check whether things already exist in $modSettings and then just call updateSettings() for the things that don't during the install.
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 20, 2017, 10:34:22 AM
Thank you very much for your advice))
I have the experience of smf - 0))

but the problem is not in the "_"
tried to remove - the result is the same ((
Title: Re: problem with submit new mod to site
Post by: SleePy on October 20, 2017, 12:26:05 PM
You are packing it using the built in Mac OS X zip utility.  I've seen it cause problems with package manager and uncompressing archives.  In addition the built in utility also archives the resource fork data as well which really junks up archives.

You should have better luck with a 3rd party zip (or tar gz) program, or using the command line.

Quote$ unzip -l qrLogin_0.9.1.zip
Archive:  qrLogin_0.9.1.zip
  Length      Date    Time    Name
---------  ---------- -----   ----
     2719  10-20-2017 05:44   package-info.xml
        0  10-20-2017 07:00   __MACOSX/
      212  10-20-2017 05:44   __MACOSX/._package-info.xml
        0  10-20-2017 04:29   qrlogin/
    12224  10-20-2017 04:29   qrlogin/apple-button.svg
        0  10-20-2017 07:00   __MACOSX/qrlogin/
      212  10-20-2017 04:29   __MACOSX/qrlogin/._apple-button.svg
    18797  10-20-2017 04:29   qrlogin/google-button.svg
      212  10-20-2017 04:29   __MACOSX/qrlogin/._google-button.svg
    14097  10-20-2017 04:29   qrlogin/logo.svg
      212  10-20-2017 04:29   __MACOSX/qrlogin/._logo.svg
    33168  10-20-2017 04:29   qrlogin/qrcode.js
      212  10-20-2017 04:29   __MACOSX/qrlogin/._qrcode.js
     3098  10-20-2017 04:29   qrlogin/QRlogin60.png
      212  10-20-2017 04:29   __MACOSX/qrlogin/._QRlogin60.png
      212  10-20-2017 04:29   __MACOSX/._qrlogin
     4346  10-20-2017 04:37   qrlogin.english.php
      212  10-20-2017 04:37   __MACOSX/._qrlogin.english.php
     6819  10-20-2017 04:35   qrlogin.php
      212  10-20-2017 04:35   __MACOSX/._qrlogin.php
     6652  10-20-2017 04:37   qrlogin.russian-utf8.php
      212  10-20-2017 04:37   __MACOSX/._qrlogin.russian-utf8.php
    10601  10-20-2017 04:28   qrlogin.template.php
      212  10-20-2017 04:28   __MACOSX/._qrlogin.template.php
     1219  10-20-2017 04:13   qrlogin.xml
      212  10-20-2017 04:13   __MACOSX/._qrlogin.xml
      908  10-20-2017 05:00   ReadMe.ru
      212  10-20-2017 05:00   __MACOSX/._ReadMe.ru
      545  10-20-2017 04:57   ReadMe.txt
      212  10-20-2017 04:57   __MACOSX/._ReadMe.txt
---------                     -------
   118161                     30 files
Title: Re: problem with submit new mod to site
Post by: Arantor on October 20, 2017, 12:27:34 PM
I did see the _MACOSX folder but didn't remember if there was still a problem with unpacking those or not. I assumed SMF itself could unpack them because I assumed it had been tested first...
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 20, 2017, 12:31:00 PM
ohhhh)))
eternal problem with mac)))
Thank you!
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 20, 2017, 12:38:14 PM
It seems to be removed
And the result does not change ((
Title: Re: problem with submit new mod to site
Post by: Shambles on October 20, 2017, 12:43:08 PM
I downloaded, unzipped then rezipped your package (unchanged) using 7-zip

Try submitting this, just to see.
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 20, 2017, 01:25:26 PM
Yes!!!
Thank you!
Submitted
Title: Re: problem with submit new mod to site
Post by: SleePy on October 20, 2017, 07:48:14 PM
Quote from: Arantor on October 20, 2017, 12:27:34 PM
I did see the _MACOSX folder but didn't remember if there was still a problem with unpacking those or not. I assumed SMF itself could unpack them because I assumed it had been tested first...
SMF will ignore the files because they are not needed to install the mod, but it is in general just ugly stuff.

When I do mine, I run:

$ cd workdir
$ COPYFILE_DISABLE=1 tar -czf ../archive.tar.gz ./package-info.xml ./other.txt ./files.xml ./specified.png

workdir is where the files are and the archive goes into the parent.

It provides a clean archive without any junk.  Mac likes to include all the stuff.  I didn't bother replacing tar with homebrews version, as I think it has the same issue.
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 25, 2017, 02:59:59 AM
Good afternoon
I have two questions:
1 - how long to wait for the "mod" check? a week? month? and how do I know the result?
2 - can I place somewhere not tested "mod" and get feedback and comments from users?
Title: Re: problem with submit new mod to site
Post by: Antes on October 25, 2017, 03:14:48 AM
Quote from: alex_qrlogin on October 25, 2017, 02:59:59 AM
Good afternoon
I have two questions:
1 - how long to wait for the "mod" check? a week? month? and how do I know the result?
2 - can I place somewhere not tested "mod" and get feedback and comments from users?

1) Depends on the que & schedule of the team members.
2) Coding discussion maybe?
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 25, 2017, 03:25:03 AM
Quote from: Antes on October 25, 2017, 03:14:48 AM
1) Depends on the que & schedule of the team members.
This is understandable)) But I would like to understand more accurately
Quote from: Antes on October 25, 2017, 03:14:48 AM
2) Coding discussion maybe?
Maybe or yes? Or is there a special topic?
Title: Re: problem with submit new mod to site
Post by: Illori on October 25, 2017, 05:06:13 AM
there is no better answer to when the mod will be approved. the members of the team are volunteers and when they have time to review the mod they will. most of the time the delay in getting mods approved is from the time it takes the mod author to fix the issues that are found.
Title: Re: problem with submit new mod to site
Post by: Irisado on October 25, 2017, 06:06:01 AM
Regarding question 2, please use the Customisation Development board for that, not Coding Discussion.
Title: Re: problem with submit new mod to site
Post by: Illori on October 25, 2017, 06:15:26 AM
Quote from: Irisado on October 25, 2017, 06:06:01 AM
Regarding question 2, please use the Customisation Development board for that, not Coding Discussion.

that means the op has to apply to be a member of that group to post in that board.
Title: Re: problem with submit new mod to site
Post by: Irisado on October 25, 2017, 06:29:16 AM
Spoiler ;).  I was going to let them see if they could figure out that part :D.
Title: Re: problem with submit new mod to site
Post by: Antes on October 25, 2017, 06:40:27 AM
Quote from: Irisado on October 25, 2017, 06:06:01 AM
Regarding question 2, please use the Customisation Development board for that, not Coding Discussion.

That board is not for preview but coding discussion (more like alpha/wip type of stuff)... Only people with proper permission can download in that section, so Coding Discussion is much more fitting considering OP wants to do an Early access / Beta whatever you call it :P
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 25, 2017, 07:05:01 AM
Thank you for your discussion))
I will place in coding discussion, especially in another topic I have no rights))
And administrators can always move if they decide)
Title: Re: problem with submit new mod to site
Post by: Irisado on October 25, 2017, 07:16:16 AM
Quote from: Antes on October 25, 2017, 06:40:27 AM
That board is not for preview but coding discussion (more like alpha/wip type of stuff)... Only people with proper permission can download in that section, so Coding Discussion is much more fitting considering OP wants to do an Early access / Beta whatever you call it :P

I would say that it's better to only have those with proper permissions downloading the mod, rather than just about anybody, but it's not up to me.
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 29, 2017, 09:04:00 AM
Good day, is it normal that for 10 days the validation did not start?
Title: Re: problem with submit new mod to site
Post by: Irisado on October 29, 2017, 09:22:00 AM
Reviewing mods submitted to the mod site will sometimes take a significant amount of time, as it depends on the number of mods waiting in the queue and the availability of team personnel.  Please also remember that all team members are volunteers.
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 29, 2017, 11:21:53 AM
I'm aware of all this))) Is there somewhere in the queue list? estimated time?
Title: Re: problem with submit new mod to site
Post by: Irisado on October 29, 2017, 11:30:44 AM
A member of the Customisation Team will notify you once your mod has been reviewed.  The Team does not provide estimates as to when mod reviews may be completed by.
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 29, 2017, 11:52:46 AM
everywhere the same story)) we are volunteers, be patient)))
Title: Re: problem with submit new mod to site
Post by: LiroyvH on October 29, 2017, 12:58:00 PM
That's because we *are* volunteers, with limited amount of time. :) Patience is required sometimes.
I'm sure someone will look at your mod as soon as possible. One time it will be approved/you get a response within a day, sometimes it may take a lot longer. It all depends on how much time people have available for the review proces and how many more submissions are pending.

Really all we can do is indeed to ask you to please be patient. :)
Someone will look at it asap.
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 29, 2017, 01:24:41 PM
thanks)) I hope this will be))
Title: Re: problem with submit new mod to site
Post by: Antes on October 30, 2017, 05:24:24 AM
Quote from: alex_qrlogin on October 29, 2017, 01:24:41 PM
thanks)) I hope this will be))

At this stage Customization team has 2 members, one is Theme creator and does not approve mods so this leaves the whole queue with one person. Also when certain mods goes into real life (such as using your phone) it requires some more testing than usual. It is unfortunate and bit frustrating I understand but there is nothing much you/we can do.
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 30, 2017, 05:46:06 AM
My mod is small))
In my check should not take more than one hour))
Well, I'll be patient))
Title: Re: problem with submit new mod to site
Post by: Arantor on October 30, 2017, 08:24:25 AM
I strongly disagree on how long or not it would take to review a plugin. Simpler plugins than this might take an hour. If I were reviewing it, I'd give it at least 3 hours, mostly because it tackles security related matters.
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 30, 2017, 09:13:55 AM
maybe)) although less than 10 functions and less than 500 lines of code))
In php style:

    // remove queue from db
    $smcFunc['db_query']('', '
        DELETE FROM {db_prefix}qrlogin
        WHERE sid = {string:sid}',
        array(
            'sid' => $sid,
        )
    );

this is 8 lines)))
Title: Re: problem with submit new mod to site
Post by: Arantor on October 30, 2017, 09:23:28 AM
It doesn't matter how many lines it is, security stuff takes longer to review to verify it isn't a risk.

Btw, when I do plugin reviews at work, I allocate a minimum of 8 hours, even for 500 lines of code.
Title: Re: problem with submit new mod to site
Post by: alex_qrlogin on October 30, 2017, 09:35:50 AM
I proceeded in the assessment from the fact that the tester knows the security risks of the forum. And that there will be no problems with understanding the functionality of the plugin.
although I have a sad experience when the tester did not install plugin to website and program to the phone ((( in this mode, the months for "tests"