04: FINDing your Way Around

This is a temporary forum setup for the purpose of discussing the EMC standards
Locked
LifeIsPain
Registered User
Posts: 5
Joined: Wed Jun 18, 2003 3:47 pm

Re: 04: FINDing your Way Around

Post by LifeIsPain »

I gave my specific example with $bobman. The line was commented out (to remove the feature) and then some other MOD comes allong and wants to edit this line. As the line has been given comments, if it skipped the line because it started with //, it would not find the correct line.

Gah, I am getting too frustrated trying to get you to understand this (and you may be frustrated with me) so I shall leave it at that for some other person to pick up on.
User avatar
-=ET=-
Registered User
Posts: 214
Joined: Mon May 26, 2003 1:35 pm
Location: France

Re: 04: FINDing your Way Around

Post by -=ET=- »

Code: Select all

When you will have done this, come back and tell me if having the original code won't have been of some help, and won't have been safer ).
No pb I'll tell you as I've precisely experiment EM to upgrade my personal (futur) board from the 2.0.5 to the 2.0.6 phpBB release.
http://www.golfexpert.net/forums" target="_blank

First, my board in the 2.0.5 phpBB release had about 20 MODs (not all very important, but about 20 not less).

And in the new 2.0.6 release, my board is now FULLY modded by EM (except very small details only because the last EM release can't handle them yet; but this will be the case with the Beta1 and there will have NO issue anymore for me/my board)!

My 20 MODs (ALL the MODs) have then been installed by EM with NO conflict (if do not take in account those which just need the Beat1 to have no issue)!

So, yes, IMO and I've done everything for that, a forum can be fully modded by EM and that's a real pleasure (safe and fast).
I can't imagine now going back to manual installations; I loose too many time in the past with that.

So, how I've done?

I did NOT upgrade the phpBB code as I don't really like these eternal upgrades of every things. There are always things forgotten and that not clean for me!

So, to ensure that all MODs put together will not have any problem...
#1 I've build on a localhost a new 2.0.6 board with my styles and languages (on a localhost)
#2 I've installed EM
#3 I've fully modded the board with EM (but test it after each MOD installed) with the same MODs as on my production board.

Then after correction of issues or verifying that everything goes fine...
#1 I've rebuild on a localhost a clean new 2.0.6 board with my languages and my style installed (on a localhost)
#2 I've upgrade my production database to the 2.0.6 structure (even if in the 2.0.5->2.0.6 case quite nothing is done)
#3 I've replaced ALL the 2.0.5 production files by my new 2.0.6 ones (with no MOD).
#4 I've installed EM
#5 I've fully modded the board (but test it after each MOD installed) with the same MODs as on my 2.0.5 release, without perform the SQL queries.

And It works with no issue until now! :D

Ok, so now I know what you're saying: this was possible because EM was not yet installed.
OK but that would have been the same if EM has already been installed, simply I should had delete the EM table first.

I know that it's not a current conventional way of doing but that a new personal experimentation as:
#1 I prefer rebuild a clean board than upgrading old files when we talked about new phpBB releases (clean phpBB, clean EM installation, clean MOD installation).
#2 Old way of doing will not necessarily be the best ones in the future as EM let admins to safely and fully rebuild/remod a forum in a VERY short time.

So... that was my experimentation and as you can see I have ''personally'' no use for this code line comments and my board will always be clean and quickly rebuild after each new phpBB release :wink:

P.S.: but I fully respect that you prefer to have this comments. I've no doubt that in very precise (but rare) cases it may have a little utility... but not for me ;)
Eternal newbie
Ptirhiik
Registered User
Posts: 144
Joined: Sun Apr 06, 2003 12:29 pm

Re: 04: FINDing your Way Around

Post by Ptirhiik »

[quote]I've fully modded the board with EM (but test it after each MOD installed) with the same MODs as on my production board[/quote]

This is preciasly my point you had the mods template available. Now try do the same without the mods templates. It is just not possible. Think quite all users are in this case, and won't want to upgrade their mod to the last version if they haven't already done (which is a very common status of a board it is working, so you don't upgrade it no more till a real need). You have also to consider that modifications are done on the fly by webmaster, to adapt their board to their specificities, and this doesn't result into a mod description. A very little board are a fresh install with validated mods only, none with EMC mods, comparing to the number of boards installed.

Keeping the reflexion in your way, you are getting to the conclusion a board have to be entirely done with easymod only, from a vanilia set. See a sooner post about this.


> LifeIsPain I have considered the sample you give with the $bowman .= add, and I think I have state this can drives the board silently in a very dangerous state if you let a mod being installed on this state, which could result in a lost of data without a chance to fix them (worst case of all). At end, the mod haven't to be installed without an human decision with all the elements in hand, and will probably have to require the both author analysis on the issue.
User avatar
-=ET=-
Registered User
Posts: 214
Joined: Mon May 26, 2003 1:35 pm
Location: France

Re: 04: FINDing your Way Around

Post by -=ET=- »

[quote=\"Ptirhiik\"]Keeping the reflexion in your way, you are getting to the conclusion a board have to be entirely done with easymod only, from a vanilia set. See a sooner post about this.
[/quote]
No, I simply explain you as you ask me why I do not need these comments :wink:

Read my P.S. too.

But, I think that even if that was just an experimentation (and I didn't say anything else), MOD (even very little ones) installed by EM will soon become a large majority in the pbpBB world as soon as EM will become in a final/stable stage.
I'm quite sure that EM will become the default phpBB installer in the future (even if it's too early to say it will officially), and every thing will be think differently in the future :?
Ptirhiik
Registered User
Posts: 144
Joined: Sun Apr 06, 2003 12:29 pm

Re: 04: FINDing your Way Around

Post by Ptirhiik »

That's why it has to handle all existing sources, whatever the state they are, and all this discussion is about it : limiting the risks of screwing all because an issue already identified and not occasional.
Nuttzy99
Registered User
Posts: 927
Joined: Fri Aug 03, 2001 7:09 am
Contact:

Re: 04: FINDing your Way Around

Post by Nuttzy99 »

This topic has become quite an unexpected distraction for me. I only have limited time to work on EM, I don't want to write docs anyway, and I'd much rather be coding. Unfortunately I've not been writing any docs b/c this 8 page long topic will not die. I think it was good to have this discussion and get the perspectives of others. I think much of it has helped remind me why I made the original decisions I did when designing EM. It also shows me other things that need to be documented. I want Authors to have maximum freedom so therefore I want there to be a good reason for any restriction or standard I'm proposing and these reasons should be documented.

I'm going to now reply to Ptirhiik's post as I promised. Then it is time for me to forget area51 exists and get back to writing more docs.

(note all quotes are Ptirhiik's)

[quote:]As there is no need to touch the original code, it remains unchanged, and then the final state is a commented line, and a new line non commented similar, later in the code.[/quote:]
FYI, I completely follow you to this point that the original commented line is being left *as is* and that it is necessary to add a duplicate line later in the code.

[quote:]Then another mod comes, and have to modify this added part. It will issue to the first commented line if you doesn't consider the line is commented[/quote:]
This is where your arguement completely falls apart. What you are suggesting cannot be considered anything other than MODing a MOD. You are saying you need to modify the line that was added by a previous MOD instllation and therefore it 100% cannot be considered anything else. And therefore since this a MOD addon, the Author of the addon must take every precaution in making sure conflicts are avoided. The addon author will be aware of the commented duplicate line and write their MOD script to avoid it.

[quote:]Not a big deal you gonna say, just add the previous line to the find. Result you have artificialy raised up the required stuff for find rather than decreasing it, and you are not sure at end you won't get to the line expected (as this can be repeated).[/quote:]
First of all I've held my tounge the few other times when you've complained about adding a few extra lines to FINDs. Coming from you, an author that includes a 1000 \"muted\" lines in his MOD script, it is laughable to think that you are concerned about adding a couple more lines to improve FIND. :roll: As for the block of lines \"repeating\", not only is this unlikely, it is also fixed by including more lines until you have a unique block. But you have to remember that in your example we are dealing with a MOD addon and the author is aware of that commented original line and will deal with it accordingly. To me, your example is very easily overcome.

(if you need to set the record straight on anything I've said here, I will read your reply)

[quote:]I can't set the comments I want to appear in the scripts (whatever they are), and that of course can't be accepted from my programmer's point of view.[/quote:]
Just noting that I've already replied to this portion of your post and set the record straight.

Also, I've quickly read the other posts. The idea of doing anything different for lines starting with // won't work. Sometimes you need to modify lines starting with // and I'm saying you don't need to include the // in the FIND. Also this is no help for things that may be inside of /* */. I will be coming up with a way for Authors to signal to EM that certain lines should not be processed (OL or EM or MOD or something like that).

Lastly, thank you all for participating in this discussion. I will definitely be mining this topic for more info that needs to appear in the FIND discussion. I really want the docs to be able to answer the questions of Authors when the time comes. This has been a great exercise and the documentation will benefit greatly from it (but I'm wring the other sections before getting back to this one!!)

So bye for now as I go away and write those docs! I will be checking back here though and at most will only reply to Ptirhiik if he has a directly reply to this post.

Thanks,
-Nuttzy cool
Ptirhiik
Registered User
Posts: 144
Joined: Sun Apr 06, 2003 12:29 pm

Re: 04: FINDing your Way Around

Post by Ptirhiik »

Really, I can go further on this : perhaps I am just not understandable because of the language. From then, I will let users (and sadly support guys) handling the silent issues that will come along, as they will be. I have really try to point to you very precise case, but not isolated, considering a script in any state it would be, and not what it should be as it won't, proposed the minor adjustement than can prevent most of this issues (although I have stated too it won't cover all this issues type), well, I really don't know how to explain more and to underline accuratly more what it is. Easymod won't be reliable on a board which had been modified - even very slightly - at hand, won't accept existing comments, and at least, although it is a very promising tool, it will remain the installation of mods an hasard game, perhaps more hasardous in certain case than a noob at hand installation. I think deception is just the word :(.

Well, just go on to the rest of the docs, this has already taken a too large place regarding the rest, and when the time to simulate on concrete examples (so on boards in any state) all cases to adjust the requirements of all will comes, you will fall in the issue, and reconsider the discussion. I am not closing the door, I simply note this as a known unsolved high risk on installation and functional disfonctionement on the result.
Nuttzy99
Registered User
Posts: 927
Joined: Fri Aug 03, 2001 7:09 am
Contact:

Re: 04: FINDing your Way Around

Post by Nuttzy99 »

\"Ptirhiik\" wrote:I think deception is just the word (
Ok, we'll check back on March 6, 2004 (6 months) and see which prediction is correct. Your prediction of creating a hazard, or mine that EM will be flawlessly installing MODs in all but the most rare of cases :P
and when the time to simulate on concrete examples (so on boards in [u19762]any[/u19762] state) all cases to adjust the requirements of all will comes, you will fall in the issue, and reconsider the discussion.
You know, you never did address MY concrete examples. At this point, I really don't want you to either. But if you look at the issues that I've raised vs. the ones that you have, I'm sure most people will agree that the correct choices have been here.
I am not closing the door, I simply note this as a known unsolved high risk on installation and functional disfonctionement on the result.
And if you do prove me wrong then I'll be counting on you to help me fix the problem. You are definitely one of the most valued assests I have in EM development! I look forward to working with you on other things down the road ;)

Thanks again for the great discussion. Ptirhiik, you are definitely not a \"yes man\" and a person that will ask tough questions like you do definitely makes things better for everyone :mrgreen:

-Nuttzy :cool:
Ptirhiik
Registered User
Posts: 144
Joined: Sun Apr 06, 2003 12:29 pm

Re: 04: FINDing your Way Around

Post by Ptirhiik »

[quote:]You know, you never did address MY concrete examples.[/quote:]I did, and so was able to reduce to the requirement to the check of commented line, rather than staying on the need to keep the find its actual signification (although I'm still persuaded there is no need to have two commands to perform the same find process, but I can go with this).

Appointement taken, but you will sooner see the issue appearing (I have already had it many times, on topic calendar ie, that force me to modify the code in a functional way - not the mod receipie - in order to suit what easymod was able to do, so issuing to a code that wasn't the one I wanted).

The first result is already on board having commented line (which is a very good way to proceed when you modify a line outside of a mod description, and a way I found many many times while doing support), mods installed but not working in the best case, inserting wrong data to the database in worst.
spooky2280
Registered User
Posts: 4
Joined: Mon Nov 15, 2004 3:15 am
Contact:

Re: 04: FINDing your Way Around

Post by spooky2280 »

Does Easy MOD support a kind of "if else"?

I want to add an onload event to the body tag. I need to first check if there is already an onload event and do an IN-LINE AFTER, ADD :

Let's say the tempate already has a preload() function fired by an onload event in the body tag...

#
#-----[ FIND ]------------------------------------------
#
<body
#
#-----[ IN-LINE FIND ]------------------------------------------
#
onload="
#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#
my_function();


result:
<body onload="my_function(); preload()"


But if there is no onload event in the body tag, I need to add one:

#
#-----[ FIND ]------------------------------------------
#
<body
#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#
onload="my_function()"


Any suggestion? And is FIND case-sensitive? Will I find "onLoad"?
Locked