zzz-pokedex.git
14 years agoBalls. Last commit was only data. Here's move flag code.
Eevee [Mon, 14 Sep 2009 15:29:05 +0000 (08:29 -0700)] 
Balls.  Last commit was only data.  Here's move flag code.

14 years agoAdded move flags. Fixed Magic Coat description.
Eevee [Mon, 14 Sep 2009 06:11:52 +0000 (23:11 -0700)] 
Added move flags.  Fixed Magic Coat description.

14 years agoAdded foreign move names. Japanese only so far.
Eevee [Mon, 14 Sep 2009 04:06:15 +0000 (21:06 -0700)] 
Added foreign move names.  Japanese only so far.

Also fixed roomaji conversion to not die spectacularly when given
hiragana.  For some reason I let it know about hiragana soukuon and
youon, but nothing else, so it gets totally confused.

14 years agoFixed up setup.py. Most notably, 'install' now works.
Eevee [Mon, 14 Sep 2009 03:11:05 +0000 (20:11 -0700)] 
Fixed up setup.py.  Most notably, 'install' now works.

The package_data line was still wrong.

Also turned off zip_safe, since it's really not; pokedex setup tries to
write to the install directory!

Finally, bumped the whoosh version; the beta I required has been taken
off pypi, and the bugs in b6 seem to be gone now.

14 years agoWhen loading Pokédex data, commit every 1000 rows.
Eevee [Mon, 14 Sep 2009 03:10:20 +0000 (20:10 -0700)] 
When loading Pokédex data, commit every 1000 rows.

Mostly done to fix RAM usage issues, but seems to have increased speed slightly.

14 years agoFixed use of split() in lookup. Now strips whitespace. #94
Eevee [Mon, 14 Sep 2009 03:09:31 +0000 (20:09 -0700)] 
Fixed use of split() in lookup.  Now strips whitespace.  #94

14 years agoAdded HG/SS overworld sprites.
Eevee [Mon, 14 Sep 2009 02:26:12 +0000 (19:26 -0700)] 
Added HG/SS overworld sprites.

14 years agoRe-ripped Diamond/Pearl level-up moves.
Eevee [Sun, 13 Sep 2009 06:15:57 +0000 (23:15 -0700)] 
Re-ripped Diamond/Pearl level-up moves.

No errors in my old data, but some orders are different from Pt.

14 years agoRe-ripped Platinum moves directly.
Eevee [Sun, 13 Sep 2009 06:02:01 +0000 (23:02 -0700)] 
Re-ripped Platinum moves directly.

This gives the correct ordering to level-up moves that have the same
level.

It also fixes move errors with Wartortle, Blastoise, Persian, Golduck,
Rapidash, Kabutops, Croconaw, Feraligatr, Noctowl, Sharpedo, Piplup's
family, Shinx's family, and Yanmega.  Yikes.

14 years agoRaichuu, not Raichyuu
Eevee [Sat, 12 Sep 2009 21:49:02 +0000 (14:49 -0700)] 
Raichuu, not Raichyuu

14 years agoAdded HG/SS egg and level moves. (Thanks, Arty2)
Eevee [Fri, 11 Sep 2009 06:32:41 +0000 (23:32 -0700)] 
Added HG/SS egg and level moves.  (Thanks, Arty2)

14 years agoFixed some problems with HGSS alt sprites; frame2 were missing and some palettes...
Eevee [Fri, 11 Sep 2009 05:04:19 +0000 (22:04 -0700)] 
Fixed some problems with HGSS alt sprites; frame2 were missing and some palettes were off.

14 years agoHG/SS sprites cleanup.
Eevee [Fri, 11 Sep 2009 02:13:26 +0000 (19:13 -0700)] 
HG/SS sprites cleanup.

Added forms.

Removed blank or duplicated female sprites.

14 years agoHeart Gold and Soul Silver sprites.
Eevee [Thu, 10 Sep 2009 17:32:58 +0000 (10:32 -0700)] 
Heart Gold and Soul Silver sprites.

14 years agoClarified some move target descriptions.
Eevee [Thu, 10 Sep 2009 17:19:32 +0000 (10:19 -0700)] 
Clarified some move target descriptions.

14 years agoMade short_effect also an rST column, so effect chance works.
Eevee [Thu, 10 Sep 2009 17:19:03 +0000 (10:19 -0700)] 
Made short_effect also an rST column, so effect chance works.

Added support for types in move effects.

14 years agoAdded __singlename__ property to tables that have corresponding dex pages.
Eevee [Thu, 10 Sep 2009 17:17:59 +0000 (10:17 -0700)] 
Added __singlename__ property to tables that have corresponding dex pages.

14 years agoRewrote every single move effect. #55
Eevee [Thu, 10 Sep 2009 17:17:14 +0000 (10:17 -0700)] 
Rewrote every single move effect.  #55

14 years agosetup.py needs a list for package_data, not a string
Eevee [Thu, 3 Sep 2009 06:42:46 +0000 (23:42 -0700)] 
setup.py needs a list for package_data, not a string

14 years agoAdded D/P font as a bunch of PNGs.
Eevee [Wed, 2 Sep 2009 03:18:02 +0000 (20:18 -0700)] 
Added D/P font as a bunch of PNGs.

14 years agoAdded semi-magical reST parsing for move effects.
Eevee [Tue, 1 Sep 2009 04:37:29 +0000 (21:37 -0700)] 
Added semi-magical reST parsing for move effects.

14 years agoMoved damage classes to a separate table. #76
Eevee [Thu, 27 Aug 2009 05:30:07 +0000 (22:30 -0700)] 
Moved damage classes to a separate table.  #76

14 years agoAdded alt Shaymin/Giratina/Rotom moves for Platinum. #5
Eevee [Wed, 26 Aug 2009 06:16:17 +0000 (23:16 -0700)] 
Added alt Shaymin/Giratina/Rotom moves for Platinum.  #5

14 years agoFix crash when stdin has no encoding.
Eevee [Tue, 25 Aug 2009 15:07:54 +0000 (08:07 -0700)] 
Fix crash when stdin has no encoding.

14 years agoAdded random lookup. #57
Eevee [Tue, 25 Aug 2009 05:59:39 +0000 (22:59 -0700)] 
Added random lookup.  #57

14 years agoWildcard lookup! #89
Eevee [Tue, 25 Aug 2009 05:04:55 +0000 (22:04 -0700)] 
Wildcard lookup!  #89

Test suite no longer reloads the entire database.  Takes too long.

Factored out some magic numbers in lookup().

14 years agoSome minor lookup refactoring.
Eevee [Tue, 25 Aug 2009 04:50:19 +0000 (21:50 -0700)] 
Some minor lookup refactoring.

Wrote a little add() function to clean up the duplication of
add_document().

Delete the index directory if it exists and we're being forced to
recreate it.

14 years agoRevert "Renamed de-accented item names in the db."
Eevee [Tue, 25 Aug 2009 04:27:21 +0000 (21:27 -0700)] 
Revert "Renamed de-accented item names in the db."

Somehow that worked..  backwards, and removed the accents.

This reverts commit 204a43b3b15946a64b971966706fba713065b7ea.

14 years agoFilled in missing Pokédex flavor text, even when duplicated.
Eevee [Mon, 24 Aug 2009 07:22:15 +0000 (00:22 -0700)] 
Filled in missing Pokédex flavor text, even when duplicated.

14 years agoRemoved +x from Crystal sprites.
Eevee [Mon, 24 Aug 2009 07:00:40 +0000 (00:00 -0700)] 
Removed +x from Crystal sprites.

14 years agoRenamed de-accented item names in the db.
Eevee [Mon, 24 Aug 2009 05:07:28 +0000 (22:07 -0700)] 
Renamed de-accented item names in the db.

14 years agoAdded whoosh and sqlite files to .gitignore.
Eevee [Mon, 24 Aug 2009 03:46:21 +0000 (20:46 -0700)] 
Added whoosh and sqlite files to .gitignore.

14 years agoAdded lookup tests. #15
Eevee [Mon, 24 Aug 2009 03:43:39 +0000 (20:43 -0700)] 
Added lookup tests.  #15

14 years agoRestored accents on Poke * items.
Eevee [Mon, 24 Aug 2009 02:18:17 +0000 (19:18 -0700)] 
Restored accents on Poke * items.

14 years agoAdded support for type: prefix and forme lookup. #15
Eevee [Sun, 23 Aug 2009 23:27:13 +0000 (16:27 -0700)] 
Added support for type: prefix and forme lookup.  #15

14 years agoFix whoosh version so Nidoran search works.
Eevee [Sun, 23 Aug 2009 04:50:33 +0000 (21:50 -0700)] 
Fix whoosh version so Nidoran search works.

14 years agoReturn correctly-cased foreign names from lookup. #15
Eevee [Sun, 23 Aug 2009 03:49:07 +0000 (20:49 -0700)] 
Return correctly-cased foreign names from lookup.  #15

14 years agoFinally weight lookup results by language. #15
Eevee [Sun, 23 Aug 2009 02:44:57 +0000 (19:44 -0700)] 
Finally weight lookup results by language.  #15

14 years agoFlesh out lookup by number. #15
Eevee [Sun, 23 Aug 2009 01:56:02 +0000 (18:56 -0700)] 
Flesh out lookup by number.  #15

Note that, unlike SVN veekun, entering "133" will return ANYTHING with an id of 133.

14 years agoAdded support for lookup by other language name. #15
Eevee [Sat, 22 Aug 2009 08:13:34 +0000 (01:13 -0700)] 
Added support for lookup by other language name.  #15

English fuzzy matches are preferred, followed by Roomaji and then
everything else.

The return tuple from lookup() now has a `name` parameter for the actual
name that was matched.

14 years agoAdded lookup support for foreign language names. #15
Eevee [Fri, 21 Aug 2009 07:30:01 +0000 (00:30 -0700)] 
Added lookup support for foreign language names.  #15

Changed lookup()'s return value to be a list of named tuples so the
caller can know which language each result is in.

14 years agoopen_index was returning an index instead of a SpellChecker. #15
Eevee [Fri, 21 Aug 2009 04:07:06 +0000 (21:07 -0700)] 
open_index was returning an index instead of a SpellChecker.  #15

14 years agoAllow lookup() callers to pass in their own whoosh indices.
Eevee [Fri, 21 Aug 2009 00:36:31 +0000 (17:36 -0700)] 
Allow lookup() callers to pass in their own whoosh indices.

14 years agoFixed some weirdness using version_group as a one-to-many.
Eevee [Wed, 19 Aug 2009 06:49:49 +0000 (23:49 -0700)] 
Fixed some weirdness using version_group as a one-to-many.

14 years agoRemoved whoosh hacks; 0.3 obviates them. #15
Eevee [Wed, 19 Aug 2009 06:48:17 +0000 (23:48 -0700)] 
Removed whoosh hacks; 0.3 obviates them.  #15

14 years agoAdded setup command and made lookup work sanely. #15
Eevee [Wed, 19 Aug 2009 06:42:59 +0000 (23:42 -0700)] 
Added setup command and made lookup work sanely.  #15

The setup command loads the default data into a default location, then
creates a whoosh index in a default location.

get_index is now open_index and can be made to explicitly recreate the
index.  It also actually opens the index if it already existed, even
across processes, now that FileStorage is working.

The lookup command takes no switches for aiming at a different database;
it only uses the default data stores.

14 years agoAdded --quiet switch to dump/load.
Eevee [Wed, 19 Aug 2009 01:36:45 +0000 (18:36 -0700)] 
Added --quiet switch to dump/load.

14 years agoVastly improved the pokedex import/export UI.
Eevee [Wed, 19 Aug 2009 01:02:53 +0000 (18:02 -0700)] 
Vastly improved the pokedex import/export UI.

csvimport is now load; csvexport is now dump.

Both take an optional -e switch to specify an engine, but will happily
use a default SQLite database in the pokedex package directory.

Additionally, the CSV directory is now controlled by the optional -d
switch, and defaults to Doing The Right Thing.

So `pokedex load` now does exactly what you'd expect: loads the data
from the right files into a consistently-located database.

14 years agoFixed whoosh index creation to work with 0.2.x. #15
Eevee [Mon, 17 Aug 2009 04:03:49 +0000 (21:03 -0700)] 
Fixed whoosh index creation to work with 0.2.x.  #15

14 years agoSprite form fixes for Unown and Castform. #73
Eevee [Sat, 15 Aug 2009 08:06:06 +0000 (01:06 -0700)] 
Sprite form fixes for Unown and Castform.  #73

D/P still had Unown ? and ! forms under their old lame names.
R/S was outright missing Unown ?/! and all the Castform forms.

14 years agoAdded static Emerald sprites. #73
Eevee [Sat, 15 Aug 2009 07:58:17 +0000 (00:58 -0700)] 
Added static Emerald sprites.  #73

14 years agoAdded FR/LG back sprites. #73
Eevee [Fri, 14 Aug 2009 15:30:34 +0000 (08:30 -0700)] 
Added FR/LG back sprites.  #73

14 years agoAdded RBY and Blue sprites. #73
Eevee [Fri, 14 Aug 2009 06:14:56 +0000 (23:14 -0700)] 
Added RBY and Blue sprites.  #73

14 years agoAdded GSC sprites. #73
Eevee [Fri, 14 Aug 2009 06:04:12 +0000 (23:04 -0700)] 
Added GSC sprites.  #73

14 years agoAdded R/S and FR/LG sprites. #73
Eevee [Fri, 14 Aug 2009 05:52:27 +0000 (22:52 -0700)] 
Added R/S and FR/LG sprites.  #73

14 years agoFixed romanization of herakurosu and herugaa.
Eevee [Fri, 14 Aug 2009 00:40:47 +0000 (17:40 -0700)] 
Fixed romanization of herakurosu and herugaa.

The "he" characters were erroneously hiragana instead of katakana.

14 years agoAdded generation_id to moves.
Eevee [Thu, 13 Aug 2009 00:24:35 +0000 (17:24 -0700)] 
Added generation_id to moves.

14 years agoAdded Surfing Pikachu and Volt Tackle Pichu. #14
Eevee [Mon, 10 Aug 2009 06:08:04 +0000 (23:08 -0700)] 
Added Surfing Pikachu and Volt Tackle Pichu.  #14

14 years agoAdded machines table.
Eevee [Mon, 10 Aug 2009 06:07:23 +0000 (23:07 -0700)] 
Added machines table.

14 years agoUpdated generation icons to be hopefully more clear.
Eevee [Mon, 10 Aug 2009 04:33:54 +0000 (21:33 -0700)] 
Updated generation icons to be hopefully more clear.

They now use roman numerals for the generation number rather than version letters.

14 years agoAdded a cropped egg icon for the move table.
Eevee [Thu, 6 Aug 2009 16:41:09 +0000 (09:41 -0700)] 
Added a cropped egg icon for the move table.

14 years agoEgg moves are passed down by the father, not the mother.
Eevee [Tue, 4 Aug 2009 20:11:53 +0000 (16:11 -0400)] 
Egg moves are passed down by the father, not the mother.

14 years agoAdded Move.effect and VersionGroup.generation relations.
Eevee [Tue, 4 Aug 2009 02:59:39 +0000 (22:59 -0400)] 
Added Move.effect and VersionGroup.generation relations.

14 years agoImproved CSV import speed by several orders of magnitude.
Eevee [Fri, 31 Jul 2009 07:03:02 +0000 (00:03 -0700)] 
Improved CSV import speed by several orders of magnitude.

14 years agoAdded growth rate formulas in LaTeX format.
Eevee [Wed, 29 Jul 2009 05:45:55 +0000 (22:45 -0700)] 
Added growth rate formulas in LaTeX format.

14 years agoMake help message readable for people without a UTF-8 terminal.
Eevee [Wed, 29 Jul 2009 01:31:06 +0000 (18:31 -0700)] 
Make help message readable for people without a UTF-8 terminal.

14 years agopokemon_moves table no longer tries to have an autoinc column.
Eevee [Tue, 28 Jul 2009 18:22:57 +0000 (11:22 -0700)] 
pokemon_moves table no longer tries to have an autoinc column.

14 years agoChanged exception syntax to work with Python 2.5.
Eevee [Tue, 28 Jul 2009 15:25:11 +0000 (08:25 -0700)] 
Changed exception syntax to work with Python 2.5.

14 years agoAdded Move.type relation.
Eevee [Tue, 28 Jul 2009 02:09:11 +0000 (19:09 -0700)] 
Added Move.type relation.

14 years agoLookup search lowercases the term again; whoops. #15
Eevee [Tue, 28 Jul 2009 01:45:43 +0000 (18:45 -0700)] 
Lookup search lowercases the term again; whoops.  #15

14 years agoMerge branch 'master' of git@veekun.com:pokedex into HEAD
Eevee [Mon, 27 Jul 2009 07:09:18 +0000 (00:09 -0700)] 
Merge branch 'master' of git@veekun.com:pokedex into HEAD

14 years agoAdded moves, types, items, and abilities to lookup index. #15
Eevee [Mon, 27 Jul 2009 06:18:11 +0000 (23:18 -0700)] 
Added moves, types, items, and abilities to lookup index.  #15

14 years agoAdded Pokémon movesets. #14
Eevee [Mon, 27 Jul 2009 06:03:10 +0000 (23:03 -0700)] 
Added Pokémon movesets.  #14

Has an 'order' column stubbed out for ordering moves learned at the same time.

14 years agoFixed csvexport to write in primary key order.
Eevee [Mon, 27 Jul 2009 05:19:27 +0000 (22:19 -0700)] 
Fixed csvexport to write in primary key order.

Good news: This no longer relies on InnoDB's default row order.

Bad news: InnoDB in MySQL 5.0 has a bug where it will sort rows
physically according to a secondary index, if there's a composite
primary key and a single-column index and the phase of the moon is
right.  So a couple tables have been, once again, reordered -- but
correctly this time.

Good news: This bug will no longer fuck me up!

14 years agoRemoved the need for a spelling column in the lookup index. #15
Eevee [Sun, 26 Jul 2009 07:37:37 +0000 (00:37 -0700)] 
Removed the need for a spelling column in the lookup index.  #15

Whoosh's spelling module unfortunately ignores any "words" that don't
look like words, even though the algorithm words fine with arbitrary
input.

I had to clone some code from whoosh.spelling, but avoiding the
isalpha() check solved a bunch of problems.  Now the index happily
compares against anything I feed into it.

14 years agoReordered pokemon_items.csv in correct primary key order. #10
Eevee [Sun, 26 Jul 2009 03:30:22 +0000 (20:30 -0700)] 
Reordered pokemon_items.csv in correct primary key order.  #10

14 years agoAdded icons and database rows for HG/SS. #32
Eevee [Sun, 26 Jul 2009 00:27:27 +0000 (17:27 -0700)] 
Added icons and database rows for HG/SS.  #32

14 years agoMigrated a roomaji library over from spline-pokedex.
Eevee [Sun, 26 Jul 2009 00:21:39 +0000 (17:21 -0700)] 
Migrated a roomaji library over from spline-pokedex.

Now includes support for small kana and youon, which were causing raw
kana output and crashes, respectively.

14 years agoMigrated a roomaji library over from spline-pokedex.
Eevee [Sun, 26 Jul 2009 00:21:39 +0000 (17:21 -0700)] 
Migrated a roomaji library over from spline-pokedex.

14 years agoAdded command_ prefix to CLI commands to fix import problems.
Eevee [Sat, 25 Jul 2009 09:43:30 +0000 (02:43 -0700)] 
Added command_ prefix to CLI commands to fix import problems.

14 years agoPokédex lookup now uses a whoosh index and spell-checker. #15
Eevee [Sat, 25 Jul 2009 08:28:33 +0000 (01:28 -0700)] 
Pokédex lookup now uses a whoosh index and spell-checker.  #15

14 years agoAdded a README and licensed under MIT.
Eevee [Thu, 23 Jul 2009 07:04:47 +0000 (00:04 -0700)] 
Added a README and licensed under MIT.

14 years agoStubbed in a simple lookup command. #15
Eevee [Thu, 23 Jul 2009 06:44:06 +0000 (23:44 -0700)] 
Stubbed in a simple lookup command.  #15

14 years agoFixed bad/confusing grammar in Aftermath's description.
Eevee [Wed, 22 Jul 2009 06:05:44 +0000 (23:05 -0700)] 
Fixed bad/confusing grammar in Aftermath's description.

14 years agoStubbing out a lookup function. #15
Eevee [Tue, 21 Jul 2009 07:12:25 +0000 (00:12 -0700)] 
Stubbing out a lookup function.  #15

14 years agoVery simple items table and wild held item data. #10
Eevee [Sat, 18 Jul 2009 06:33:36 +0000 (23:33 -0700)] 
Very simple items table and wild held item data.  #10

14 years agoRecolored the cropped Kecleon purple. :3
Eevee [Wed, 15 Jul 2009 05:13:11 +0000 (22:13 -0700)] 
Recolored the cropped Kecleon purple.  :3

14 years agoReplaced cropped sizes with cropped Pokémon for #13.
Eevee [Wed, 15 Jul 2009 05:05:36 +0000 (22:05 -0700)] 
Replaced cropped sizes with cropped Pokémon for #13.

14 years agoMerge branch 'master' of git@veekun.com:pokedex
Eevee [Mon, 6 Jul 2009 00:16:29 +0000 (17:16 -0700)] 
Merge branch 'master' of git@veekun.com:pokedex

14 years agoAdded cropped shape images. #13
Eevee [Mon, 6 Jul 2009 00:15:24 +0000 (17:15 -0700)] 
Added cropped shape images.  #13

These were already supposed to be included, but somehow never got
committed.  Whoops.

14 years agoFixed a slew of foriegn key import problems. #29
Eevee [Sat, 4 Jul 2009 03:12:13 +0000 (23:12 -0400)] 
Fixed a slew of foriegn key import problems.  #29

Curse's type_id was 0, which is bogus; this has been fixed by creating a
real ????? type.
Fourth-gen moves all had zero as a contest effect id, which was also
bogus.
Pokémon 494 and 495 were junk and have been scrapped entirely.
pokemon_form_groups's description column was too short.

pokedex's connect() now takes kwargs passed to sessionmaker().

A more major change: some tables, like pokemon, are self-referential and
contain rows that refer to rows later in the table (for example, Pikachu
evolves from Pichu, which has a higher id).  At the moment such a row is
loaded, the foreign key is thus bogus.  I solved this by turning on
autocommit and wrapping add() in a try block, then attempting to readd
every failed row again after the rest of the table is finished.  Slows
the import down a bit, but makes it work perfectly with foreign key
checks on.

14 years agoAdded Platinum Sinnoh dex numbers. #24
Eevee [Sat, 27 Jun 2009 04:27:35 +0000 (21:27 -0700)] 
Added Platinum Sinnoh dex numbers.  #24

14 years agoAdded remaining Pokémon form data. #5
Eevee [Sun, 21 Jun 2009 05:32:37 +0000 (22:32 -0700)] 
Added remaining Pokémon form data.  #5

Types, abilities, egg groups, and stats for Shaymin, Giratina, and Rotom forms.
Updated height and weight for Shaymin and Giratina forms.
Added Giratina's form descriptions and updated Shaymin's to mention link
battles and freezing.

14 years agoAdded some Pokémon methods to hide form weirdness. #5
Eevee [Tue, 16 Jun 2009 03:48:27 +0000 (20:48 -0700)] 
Added some Pokémon methods to hide form weirdness.  #5

14 years agoAdded Platinum forms. #5
Eevee [Tue, 16 Jun 2009 03:48:02 +0000 (20:48 -0700)] 
Added Platinum forms.  #5

14 years agoAdded icons for Platinum formes. #5
Eevee [Tue, 16 Jun 2009 02:04:32 +0000 (19:04 -0700)] 
Added icons for Platinum formes.  #5

Also renamed some older formes to bring them into line with the new
(and actually correct) naming convention.

14 years agoAdded alternate Forme sprites for Platinum. #5
Eevee [Tue, 9 Jun 2009 05:51:36 +0000 (22:51 -0700)] 
Added alternate Forme sprites for Platinum.  #5

This includes the back sprites I was missing, as well as a
reorganization of the sprites away from type names and towards form
names.

14 years agoAdded other languages' Pokémon names.
Eevee [Sun, 7 Jun 2009 08:36:17 +0000 (01:36 -0700)] 
Added other languages' Pokémon names.

15 years agoChanged generation icons to RB/GS/etc.
Eevee [Fri, 29 May 2009 04:18:45 +0000 (21:18 -0700)] 
Changed generation icons to RB/GS/etc.

15 years agoFixed csvimport to load in table dependency order.
Eevee [Fri, 29 May 2009 04:16:18 +0000 (21:16 -0700)] 
Fixed csvimport to load in table dependency order.