bugFreeciv - Bugs: bug #21444, Saved action_enabler reqs do not...

 
 
Show feedback again

bug #21444: Saved action_enabler reqs do not use tabular format

Submitted by:  Marko Lindqvist <cazfi>
Submitted on:  Sun 05 Jan 2014 11:30:17 AM UTC  
 
Category: generalSeverity: 3 - Normal
Priority: 5 - NormalStatus: Fixed
Assigned to: Sveinung Kvilhaugsvik <sveinung>Open/Closed: Closed
Release: TRUNK, 2.6Operating System: Any
Planned Release: 3.0.0, 2.6.0Contains string changes: None

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Tue 15 Sep 2015 11:57:09 AM UTC, SVN revision 29894:

section files: allow underscore in table names

Store in the table format even if the entity name contains an underscore
character.

This makes ruledit store the obsolete_by field of buildings and the
actor_reqs and target_reqs fields of action enablers in a much more readable
way.

Reported by Marko Lindqvist

See bug #21444

(Browse SVN revision 29894)

Sveinung Kvilhaugsvik <sveinung>
Project MemberIn charge of this item.
Tue 15 Sep 2015 11:26:02 AM UTC, SVN revision 29893:

section files: allow underscore in table names

Store in the table format even if the entity name contains an underscore
character.

This makes ruledit store the obsolete_by field of buildings and the
actor_reqs and target_reqs fields of action enablers in a much more readable
way.

Reported by Marko Lindqvist

See bug #21444

(Browse SVN revision 29893)

Sveinung Kvilhaugsvik <sveinung>
Project MemberIn charge of this item.
Sun 13 Sep 2015 06:19:13 PM UTC, comment #9:

fixed

(file #25134)

Sveinung Kvilhaugsvik <sveinung>
Project MemberIn charge of this item.
Sun 13 Sep 2015 04:12:11 PM UTC, comment #8:

Is dropping digits as legal characters in that case intentional?
No.

Sveinung Kvilhaugsvik <sveinung>
Project MemberIn charge of this item.
Sun 13 Sep 2015 03:26:43 PM UTC, comment #7:

One of the places where you now use is_legal_table_entry_name() used fc_isalnum(). is_legal_table_entry_name() uses fc_isalpha().

Is dropping digits as legal characters in that case intentional?

Marko Lindqvist <cazfi>
Project Administrator
Sun 13 Sep 2015 03:22:39 PM UTC, comment #6:

I created bug #23874 for the column in separate table issue

Sveinung Kvilhaugsvik <sveinung>
Project MemberIn charge of this item.
Sun 13 Sep 2015 03:17:42 PM UTC, comment #5:

Allow underscore in entity names that ends up in a table.

(file #25132)

Sveinung Kvilhaugsvik <sveinung>
Project MemberIn charge of this item.
Mon 16 Jun 2014 09:31:16 PM UTC, comment #4:

> Why it wants to have "love" column in separate table?


Because the entries are not next to the other ai ones in the secfile.

pepeto <pepeto>
Project Member
Mon 02 Jun 2014 06:42:28 AM UTC, comment #3:

(I meant file #20862 for bug #22111)

pepeto <pepeto>
Project Member
Mon 02 Jun 2014 06:40:58 AM UTC, comment #2:

I have also noticed in file #22111 things like:

pepeto <pepeto>
Project Member
Tue 21 Jan 2014 09:48:41 PM UTC, comment #1:

Another weirdness in secfile saving noticed when updating tileset-demo.sav scenario on S2_5. Why it wants to have "love" column in separate table:

-ai={"love","spam","countdown","war_reason","patience","warn_space","ask_peace"
,"ask_alliance","ask_ceasefire"
-0,4,-1,5,0,0,0,0,0
-0,0,-1,5,0,0,0,0,0
-0,1,-1,5,0,0,0,0,0
-0,2,-1,5,0,0,0,0,0
-0,3,-1,5,0,0,0,0,0
+ai={"love"
+0
+0
+0
+0
+0
+}
+ai={"spam","countdown","war_reason","patience","warn_space","ask_peace","ask_a
lliance","ask_ceasefire"
+4,-1,5,0,0,0,0,0
+0,-1,5,0,0,0,0,0
+1,-1,5,0,0,0,0,0
+2,-1,5,0,0,0,0,0
+3,-1,5,0,0,0,0,0
}

Marko Lindqvist <cazfi>
Project Administrator
Sun 05 Jan 2014 11:30:17 AM UTC, original submission:

For some reason action_enablers saved from freeciv-ruledit do not use tabular format. That's a decision of lower-level secfile saving handling, and should not be concern, but as this is seemingly arbitrary it's suspicious.

[actionenabler_0]
action="Poison City"
actor_reqs0.type="UnitFlag"
actor_reqs0.name="Spy"
actor_reqs0.range="Local"
actor_reqs1.type="DiplRel"
actor_reqs1.name="War"
actor_reqs1.range="Local"
actor_reqs2.type="UnitFlag"
actor_reqs2.name="Diplomat"
actor_reqs2.range="Local"
target_reqs0.type="MinSize"
target_reqs0.name="2"
target_reqs0.range="City"

Marko Lindqvist <cazfi>
Project Administrator

 

(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by sveinung (Updated the item)
  • -unavailable- added by jtn (Updated the item)
  • -unavailable- added by pepeto (Posted a comment)
  • -unavailable- added by cazfi (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Error: not logged in

     

     

    Follow 13 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue 15 Sep 2015 11:57:26 AM UTCsveinungStatusReady For Test=>Fixed
      Open/ClosedOpen=>Closed
    Sun 13 Sep 2015 06:19:13 PM UTCsveinungAttached File-=>Added section-files-allow-underscore-in-table-names-v2.patch, #25134
      StatusIn Progress=>Ready For Test
    Sun 13 Sep 2015 04:12:11 PM UTCsveinungStatusReady For Test=>In Progress
    Sun 13 Sep 2015 03:17:42 PM UTCsveinungAttached File-=>Added section-files-allow-underscore-in-table-names.patch, #25132
      CategoryNone=>general
      StatusNone=>Ready For Test
      Assigned toNone=>sveinung
      Release=>TRUNK, 2.6
      Operating SystemNone=>Any
      Planned Release2.6.0=>3.0.0, 2.6.0
    Tue 15 Jul 2014 08:47:42 PM UTCjtnPlanned Release=>2.6.0
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup