ElkArte Community

Project Support => Announcements => Topic started by: emanuele on October 21, 2017, 10:32:59 pm

Title: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 21, 2017, 10:32:59 pm
After three years of (albeit inconsistent) work, the ElkArte Community is pleased to announce the release of the stable version of ElkArte 1.1, the first minor update to the ElkArte 1.x line of software.
Talking about a "minor" release sounds a bit diminished, since many things were changed, especially in the code, but still we decided not to increase the major version because anyway the changes are not too architecturally deep.

Some of the most exciting new features present in ElkArte 1.1:

On the coding-side:

But, as usual, the best way to know about ElkArte is to download the software and install it in order to discover all the features, and if you have any doubt feel free to join the forum at elkarte.net and ask!
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: Spuds on October 22, 2017, 12:28:34 am
Yeah !

Now on to 2.0 ... well after I finish addon updates  O:-)
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 22, 2017, 12:34:41 am
xD
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: b4pjoe on October 22, 2017, 12:36:58 am
What be the proper procedure to upgrade my forum from 1.0.10? Replace all files from the zip or can this be installed from package manager?
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 22, 2017, 01:03:25 am
1) backup (you never know)[1]
2) the "replace all files" is the way[2] (then pointing to the forum should bring you to the upgrade procedure, otherwise just go to forum/install/upgrade.php).
3) follow the upgrade instructions and delete the "install" directory (the upgrade script tries to do, but if it fails you have to do it manually).
Actually, the ideal situation is: do a test upgrade on a clone of your forum and verify nothing breaks.
Even better would be to remove any thing except Settings.php and Settings_bak.php and upload the new files.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: Vekseid on October 22, 2017, 02:34:24 am
Well this was awhile in coming. Congrats, everyone!
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: kucing on October 22, 2017, 04:16:46 am
maintenance not disabled after upgrading?

Title: Re: ElkArte 1.1 Final - Release announcement
Post by: kode54 on October 22, 2017, 06:26:11 am
This should be fun for Hydrogen Audio, since I've subtly modified the scripts in various places, and changed the default theme, imported and changed a dark theme, etc. Oh yeah, and addons that we use, too.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: scripple on October 22, 2017, 07:41:24 am
maintenance not disabled after upgrading?
I see it too when I run it through the webpage.  That at least didn't happen when I just ran the upgrade script from the command line.

This seems a not ready for release release to me.  

Now with object obfuscated code via the database.  Whee!

Let's see.  Install_1-1.php says put this into settings. 

        array('modules_display', 'mentions,poll,verification,random'),
        array('modules_post', 'mentions,poll,attachments,verification,random'),
        array('modules_personalmessage', 'labels,verification'),
        array('modules_register', 'verification'),

What actually ended up in settings after the upgrade?
Code: [Select]
+-------------------------+---------------------------------+
| variable                | value                           |
+-------------------------+---------------------------------+
| modules_display         | drafts,poll,random              |
| modules_personalmessage | drafts,verification             |
| modules_post            | drafts,poll,verification,random |
| modules_profile         | drafts                          |
| modules_register        | verification                    |
+-------------------------+---------------------------------+

I guess that's why the attachments context isn't set as I posted in my bug report.  Likely there will be other problems as well from the difference in the two lists.  Upgrade doesn't set everything the code needs.

I can see why enabling attachments doesn't help either.  A quick search finds no calls to enableModules for attachments outside of install/upgrade.

If you're going to make modules optional, you need to test with and without the module.  Really all combinations, but certainly a simple on off for each one.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: siprof on October 22, 2017, 09:41:39 am
maintenance not disabled after upgrading?

Confirmed, maintenance mode was not automatically disabled after upgrading. I must edit Settings.php to disabled maintenance mode (change 2 value into 0 value)

Moreover if you use Cloudflare, you must do purge everything in order to have correct display...
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 22, 2017, 12:32:33 pm
Now with object obfuscated code via the database.  Whee!
What you mean?
The fact the sql file do not contain sql anymore, but the definitions according to the db-abstraction?
Well, that was done because maintain multiple[1]sets of install and multiple sets of upgrades leads to problems and since we already have code that deals with that, better use it instead of waste time and forget about things.

It's actually possible to convert it into a pure sql file, actually, I have already the code somewhere for other reasons, the idea is to write an abstraction that isntead of executing the queries simply writes the string to a file for example.

Let's see.  Install_1-1.php says put this into settings. 

        array('modules_display', 'mentions,poll,verification,random'),
        array('modules_post', 'mentions,poll,attachments,verification,random'),
        array('modules_personalmessage', 'labels,verification'),
        array('modules_register', 'verification'),

What actually ended up in settings after the upgrade?
Code: [Select]
+-------------------------+---------------------------------+
| variable                | value                           |
+-------------------------+---------------------------------+
| modules_display         | drafts,poll,random              |
| modules_personalmessage | drafts,verification             |
| modules_post            | drafts,poll,verification,random |
| modules_profile         | drafts                          |
| modules_register        | verification                    |
+-------------------------+---------------------------------+
This should be according to what you have enabled at the time of the upgrade.

I guess that's why the attachments context isn't set as I posted in my bug report.  Likely there will be other problems as well from the difference in the two lists.  Upgrade doesn't set everything the code needs.

I can see why enabling attachments doesn't help either.  A quick search finds no calls to enableModules for attachments outside of install/upgrade.

If you're going to make modules optional, you need to test with and without the module.  Really all combinations, but certainly a simple on off for each one.
Sh**t happens. :(
remember that in theory the abstraction could be set up to work with other dbms as well, and that would mean an install and an upgrade sql script re-written for each of them, while with this soluiton it's just about adding the code for interpreting the convention
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: elk_is_cool on October 22, 2017, 02:21:24 pm
I think I've gotten a little rusty, how do I upgrade?  Download the ElkArte_v1-1-0_install.zip and tell Filezilla just to update all files? 
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 22, 2017, 03:07:06 pm
http://www.elkarte.net/community/index.php?topic=4712.msg34075#msg34075

Yep. :)
Just to be ready: addons for 1.0 may not work with 1.1 and themes for 1.0 will not work in 1.1.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: b4pjoe on October 22, 2017, 03:41:58 pm
1) backup (you never know)[1]
2) the "replace all files" is the way[2] (then pointing to the forum should bring you to the upgrade procedure, otherwise just go to forum/install/upgrade.php).
3) follow the upgrade instructions and delete the "install" directory (the upgrade script tries to do, but if it fails you have to do it manually).

On #2 above....I created the clone of my site and replaced all files. Then when I go to my forum URL it runs install.php instead of upgrade.php. It appears it will do a full new install if I go that route. Should I manually point it to upgrade.php? Doing so does take me to the upgrade page instead of the install page. Should I continue on this way?
Actually, the ideal situation is: do a test upgrade on a clone of your forum and verify nothing breaks.
Even better would be to remove any thing except Settings.php and Settings_bak.php and upload the new files.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 22, 2017, 03:46:01 pm
On #2 above....I created the clone of my site and replaced all files. Then when I go to my forum URL it runs install.php instead of upgrade.php. It appears it will do a full new install if I go that route. Should I manually point it to upgrade.php? Doing so does take me to the upgrade page instead of the install page. Should I continue on this way?
Sorry, probably I didn't explain it crystal clear: with "clone" I mean create a perfectly functioning duplicate with a different database and paths in order to properly test the upgrade before doing it "live". :)
It's always good practice to test before doing the real one, just because if something goes wrong for any reason, you don't even have to care about restoring a backup, you just wipe the clone and investigate the issue. ;)

ETA: sorry, I misread "#2" and thought it was #1... ::)
hmm... that's strange, it should bring you to upgrade.php, if it does not, just replace install.php with upgrade.php in the address bar.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: b4pjoe on October 22, 2017, 03:59:51 pm
On #2 above....I created the clone of my site and replaced all files. Then when I go to my forum URL it runs install.php instead of upgrade.php. It appears it will do a full new install if I go that route. Should I manually point it to upgrade.php? Doing so does take me to the upgrade page instead of the install page. Should I continue on this way?
Sorry, probably I didn't explain it crystal clear: with "clone" I mean create a perfectly functioning duplicate with a different database and paths in order to properly test the upgrade before doing it "live". :)
It's always good practice to test before doing the real one, just because if something goes wrong for any reason, you don't even have to care about restoring a backup, you just wipe the clone and investigate the issue. ;)

ETA: sorry, I misread "#2" and thought it was #1... ::)
hmm... that's strange, it should bring you to upgrade.php, if it does not, just replace install.php with upgrade.php in the address bar.

OK I did that. A complete clone with a different DB. Made sure all paths were updated with repair_settings.php. Uninstalled all addons and reverted back to the default elkarte theme. Then manually pointed to upgrade.php and the upgrade proceeded and completed. Going straight to the forum produced a lot of giant icons all over the front page but clearing the browser cache and reloading the page cleared that up. All looks good now other than as you mentioned....old custom theme also produced giant icons everywhere. Looks like I will have to redo my custom theme.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 22, 2017, 06:06:06 pm
The bigger the easier to see! xD
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: scripple on October 22, 2017, 06:16:10 pm
Now with object obfuscated code via the database.  Whee!
What you mean?
I mean the fact that the modules to call are now stored in the database and between the modules and their abstractions it was many files and in fact all the way back to Load and the install and upgrade scripts to figure out what was failing.  So the new structure has wonderfully obscured what the code does.

This should be according to what you have enabled at the time of the upgrade.
Well this needs a lot of work.  A quick grep for enableModules and disableModules shows only calendar and drafts can be turned on and off post install/upgrade.  So mentions, attachments and anything else is stuck.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: b4pjoe on October 22, 2017, 06:32:43 pm
The bigger the easier to see! xD

They are definitely easy to read! :D
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 22, 2017, 09:59:08 pm
I mean the fact that the modules to call are now stored in the database and between the modules and their abstractions it was many files and in fact all the way back to Load and the install and upgrade scripts to figure out what was failing.  So the new structure has wonderfully obscured what the code does.
Oh in that sense.
Yes, let's call it an experiment.
It's a kind of obfuscation, I agree, but it is a way to avoid having zillions of conditionals everywhere that obfuscate everything else.
At least each "feature" is in "one place" (yes, not yet, not entirely, but it's just a first step) and not spread across multiple controllers/subs/etc.

This should be according to what you have enabled at the time of the upgrade.
Well this needs a lot of work.  A quick grep for enableModules and disableModules shows only calendar and drafts can be turned on and off post install/upgrade.  So mentions, attachments and anything else is stuck.
This just needed me not to forget things. Again sh**t happens. I did a mistake. A huge one indeed[1], but the testing done up until now did not show it. You can argue you just tried an upgrade, well nobody tried that upgrade in that conditions.
The bug will be fixed, the 1.1.1 branch was already there, I created a 1.1.2 milestone and moved all the less-than-vital issues to it.
I think a release next weekend is possible to fix at least these important issues.
It's not the first, and it will not be the last.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: scripple on October 23, 2017, 12:25:43 am
I mean the fact that the modules to call are now stored in the database and between the modules and their abstractions it was many files and in fact all the way back to Load and the install and upgrade scripts to figure out what was failing.  So the new structure has wonderfully obscured what the code does.
Oh in that sense.
Yes, let's call it an experiment.
It's a kind of obfuscation, I agree, but it is a way to avoid having zillions of conditionals everywhere that obfuscate everything else.
At least each "feature" is in "one place" (yes, not yet, not entirely, but it's just a first step) and not spread across multiple controllers/subs/etc.
The same thing could have been accomplished without a "shadow state" in the database.  By shadow state I mean you now have multiple places in the database that store the (hopefully) same information.  And it's critical that they really do all store the same information to prevent breakage (like what's happening here).  That's a big hassle.

You could have the same code split but instead of storing a module string for each controller that uses the module you could have a simple check at the start of each controller.

if modSettings['attachments'] => run/load/envoke attachmentModule
if modSettings['drafts'] => run/load/envoke draftsModule

This model cuts down on these mistakes now and in the future. 

The current model is asking for trouble.  Modify a controller to use a module it didn't previously then forget to modify EVERY place where that setting is possibly enabled or disabled and things are broken.  Add a new place that changes the setting and don't update every controller string and things are broken.

With my model you don't have to remember to update the database for every controller that uses a given module when the setting is enabled or disabled.  You don't even have to know which controllers use which modules.  The database also can never be out of sync as the setting is stored only once.  This really is a good thing for stability.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: kode54 on October 23, 2017, 03:55:14 am
Not sure I need to back up everything, since I keep the full site root in a Git repository, but I'll diff against 1.0.10 stock, then install 1.1, then apply the diff as a patch to see what I can salvage of our extensive random changes.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 23, 2017, 08:34:29 am
You could have the same code split but instead of storing a module string for each controller that uses the module you could have a simple check at the start of each controller.

if modSettings['attachments'] => run/load/envoke attachmentModule
if modSettings['drafts'] => run/load/envoke draftsModule

This model cuts down on these mistakes now and in the future. 
Not really.
You just change the place you have to remember to do things (in addition multiplying it by having to repeat the check for each and every "extension" in each involved controller. And if an addon wants to expand a controller it has to add code to that spot (or you have to add a way for addons to add their code there.
And so on.

Also, since you are criticising the modules approach, I guess it's the same with hooks approach, because they "hide" their activation code into the database the same way.

The current model is asking for trouble.  Modify a controller to use a module it didn't previously then forget to modify EVERY place where that setting is possibly enabled or disabled and things are broken.  Add a new place that changes the setting and don't update every controller string and things are broken.
I'm not sure what you mean here.
If a controller needs a module, the only thing to do is list the controller name in the list of controllers involved for that module. Done.
It's not even necessary to switch it on/off, you can leave it always on and forget about it (that's what I did for some of them.

Modules are basically hooks under steroids. Nothing more.
The point is to make anything that is not strictly "the action" to be run from an addon point of view (so "posting" is the "core", then anything additional (attachments, pools, post approval, notifications, etc.) and for that, hard-code it is not an option.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: scripple on October 23, 2017, 09:26:41 am
Yes I have issues with hooks.  They aren't all they're cracked up to be because utility functions move all the time and the way data is stored/serialized and where it is stored changes with every update.  So even though the hook may exist it doesn't actually work anymore.  Of course you can't find that out until eventually the hook trips the error.  If you really want hooks to be useful you have to commit to a stable ABI/API to go with them.  And carefully document when that changes.

This is all pointless though.  It's your project and clearly you've made up your mind the path of the moment.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: Spuds on October 23, 2017, 04:52:48 pm
Not sure I need to back up everything, since I keep the full site root in a Git repository, but I'll diff against 1.0.10 stock, then install 1.1, then apply the diff as a patch to see what I can salvage of our extensive random changes.
If you think some of those changes should be in the core, please let us know :D
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: vbgamer45 on October 23, 2017, 09:39:01 pm
Congrats on the release! Will check it and work on updating my sites to this new release!
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: TE on October 23, 2017, 11:11:23 pm
You forgot the optional "two factor authentication" in the list of new features  :D
Anyways, great work and a big thank you to all the guys (and girls) involved..
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 23, 2017, 11:50:05 pm
Ouch!
Good point TE!
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: Spuds on October 24, 2017, 12:31:04 am
You forgot the optional "two factor authentication" in the list of new features  :D
Anyways, great work and a big thank you to all the guys (and girls) involved..
I can't believe emanuele forgot to add that  O:-)  Its now been added here and on the release page.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: IchBin on October 24, 2017, 06:25:31 pm
I cannot tell you how cool it is that you guys keep plugging away at this. SMF should be doing a git pull from Elkarte if you ask me. :D

This is awesome. Two-factor is pretty cool. I'll have to check that out!

--Edit--

Ok I checked out two-factor.  Just a couple of things. The scan image would not work for my google authenticator. I had to manually enter the one time pass.  The other thing is the text box that the one time pass is in. Make it longer so the whole pass fits in the box without having to scroll. :)
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: Spuds on October 25, 2017, 05:18:03 pm
Tracked :D ... https://github.com/elkarte/Elkarte/issues/3025
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: TE on October 25, 2017, 05:44:34 pm

Ok I checked out two-factor.  Just a couple of things. The scan image would not work for my google authenticator. I had to manually enter the one time pass.  The other thing is the text box that the one time pass is in. Make it longer so the whole pass fits in the box without having to scroll. :)
Not sure what's causing the image-problem.. IMO there is one possible problem:
your smartphone (or tablet) camera didn't use autofocus for the image..

 Can you test the QR on this page with a generic barcode / qrcode scanner app, please? https://davidshimjs.github.io/qrcodejs/
 It's a sample from the library we used to generate the code.

Title: Re: ElkArte 1.1 Final - Release announcement
Post by: Jorin on October 26, 2017, 05:06:48 pm
Wow, I missed that! And now there are three pages of comments to read!  :o  :D

Congratulations to all involved in this great software!

God, now I have work too (need to translate this thing)!  >:(  ;)
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 26, 2017, 09:23:22 pm
And I still have to fix the translation repos... xD
But maybe now that TE is around... O:-)
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 26, 2017, 11:31:56 pm
The other thing is the text box that the one time pass is in. Make it longer so the whole pass fits in the box without having to scroll. :)
Which box are you talking about?
The one in the login screen, or the one in  the profile page?
On mine, the password takes about half of the width of the box... :o
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: TE on October 26, 2017, 11:45:29 pm
And I still have to fix the translation repos... xD
But maybe now that TE is around... O:-)
what's wrong with the transifex repos? I feel we need a new repo for 1.1?
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 27, 2017, 12:03:46 am
There is already one.
But... maybe it's better to start a new topic in the lang section... tomorrow... too sleepy to write now. :-\
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 29, 2017, 08:10:04 am
Due to unforeseen guests today, I'll not be able to push the release this week... :-\
I'll put a patch together during the week. Sorry.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: Spuds on October 29, 2017, 02:09:06 pm
what release are you referring to? 1.1.1? 

Oh lumpy beds and cheap hooch are good guest deterrents, just saying :D
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: emanuele on October 29, 2017, 04:00:04 pm
Yep.
And... well, not exactly good, just guests. xD
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: Spuds on October 29, 2017, 10:32:44 pm
Not good guests you say? ... then break out a bottle of Maestri Cantinieri’ and drive them off :D
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: Spuds on October 30, 2017, 03:10:46 pm
Not sure what's causing the image-problem.. IMO there is one possible problem:
your smartphone (or tablet) camera didn't use autofocus for the image..

 Can you test the QR on this page with a generic barcode / qrcode scanner app, please? https://davidshimjs.github.io/qrcodejs/
 It's a sample from the library we used to generate the code.
A suggestion on github from @kode54
"Figured out why it's not working, using only my eyes. It appears to be using a really small size (80x80) and isn't rendering the image to an even integer multiple of the grid size of the QR code. It would probably help to render it to 100x100 or even 128x128."

Although all 3 sizes worked for me I don't see any issue with increasing it to 128X for the next release.

ETA: Yes I'll move this to a new topic in a bit !
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: live627 on October 31, 2017, 04:20:36 am
Would camera quality be an issue here?
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: TE on October 31, 2017, 07:29:08 am
yes, I think so, the camera needs at least a working autofocus, that's why I can't scan the image with my tablet at all.. the other problem could be the source, not sure which sreen resolution isthe device IchBin used to display the image...
Title: SPLIT: Bbc integration issues
Post by: emanuele on November 05, 2017, 08:57:40 am
Bug report moved to Bug Reports (https://www.elkarte.net/community/index.php?board=2.0) - https://www.elkarte.net/community/index.php?topic=4748.0
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: jakedp on November 27, 2017, 04:53:46 pm
http://www.elkarte.net/community/index.php?topic=4712.msg34075#msg34075

Yep. :)
Just to be ready: addons for 1.0 may not work with 1.1 and themes for 1.0 will not work in 1.1.

Could you be more specific? Although that is pretty specific I want to clarify before I have a heart attack. I have a custom forked theme of Silence. Does this mean I have to spend hours and hours figuring out how to convert it before I upgrade?
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: Spuds on November 27, 2017, 06:15:23 pm
I'm going to update Silence in the next couple of days, after that I will be able to help answer this question with some details.

Today if you were to do a DIFF on a 1.1 index.css and a 1.0, you may crap your pants, BUT the changes are not that substantial.  We did a lot of restructuring to move colors, borders, shadows, etc to the variant definition where they belonged.  Going forward this will be a major help for themes.  1.0 had started this but there were still colors and structure in both the base and variant files, 1.1 cleaned this up a bunch.  That's good but it makes looking at a Diff almost useless.

For sure you will need the new like stats and icon sections of the 1.1 index CSS, these are all the declarations just before the media query section, so you could just copy and paste those line from the 1.1 CSS as a start.  I'm sure there are several other key things that need to be added/updated and as I find them I'll add them to a new 1.1 Silence.   Then my hope is you could do a diff on Silence 1.0 and Silence 1.1 and see the primary changes that need to be made.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: IchBin on December 08, 2017, 04:21:44 am
The other thing is the text box that the one time pass is in. Make it longer so the whole pass fits in the box without having to scroll. :)
Which box are you talking about?
The one in the login screen, or the one in  the profile page?

Sorry, I got side tracked for a month apparently. :)  The one on the profile page. Image attached.
Title: Re: ElkArte 1.1 Final - Release announcement
Post by: Jorin on January 26, 2018, 07:21:31 am
@Spuds Sounds great, though this may lead to problems with my custom CSS file. I changed and optimized a lot with this file. Hope it works!