crossroads / snapa

MIT License
1 stars 0 forks source link

Errno::ENAMETOOLONG happens when every country in the world is selected via query string #1

Closed steveyken closed 11 years ago

steveyken commented 11 years ago

Errno::ENAMETOOLONG (File name too long - /tmp/snapa/c=DZA,AGO,BEN,BWA,BFA,BDI,CMR,....the list is very long!

Need to get array of c values, sort them, then hash and use that to generate tmp filename

warp commented 11 years ago

yeah I did think about hashing the params I guess I will :)

On 13 September 2013 04:02, Steve Kenworthy notifications@github.comwrote:

Errno::ENAMETOOLONG (File name too long - /tmp/snapa/c=DZA,AGO,BEN,BWA,BFA,BDI,CMR,....the list is very long!

Need to get array of c values, sort them, then hash and use that to generate tmp filename

— Reply to this email directly or view it on GitHubhttps://github.com/crossroads/snapa/issues/1 .

steveyken commented 11 years ago

latest version creates a hash that is still too long... what about MD5 sum?

Use this for testing:

/snapa/map.png?c=DZA,AGO,BEN,BWA,BFA,BDI,CMR,SPI,CPV,CAF,TCD,COM,COG,COD,CIV,DJI,GNQ,ERI,GAB,GMB,GHA,GIN,GNB,KEN,LSO,MDG,MWI,MLI,MRT,MUS,MYT,MOZ,NAM,NER,NGA,REU,RWA,SHN,STP,SEN,SYC,SLE,SOM,ZAF,SDN,SWZ,TGO,UGA,TZA,ESH,ZMB,ZWE,AIA,ATG,ARG,ABW,BHS,BRB,BLZ,BMU,BOL,BRA,CAN,CYM,CHL,COL,CRI,CUB,DMA,DOM,HSI,ECU,SLV,FLK,GUF,ECG,GRL,GRD,GLP,GTM,GUY,HTI,HND,JAM,MTQ,MEX,MSR,NIC,PAN,PRY,PER,PRI,KNA,LCA,SPM,VCT,SUR,TTO,TCA,USA,URY,VEN,VIR,AFG,ARM,AZE,BGD,BTN,BVT,KHM,CXR,CCK,CYP,PRK,ATF,GEO,HKG,IND,JPN,KAZ,KGZ,LAO,MAC,MYS,MDV,MNG,MMR,NPL,PSE,PHL,KOR,SGP,LKA,TWN,TJK,THA,TLS,TUR,TKM,UZB,VNM,YEM,ALA,ALB,AND,AUT,AZR,BLR,BEL,BIH,BGR,GG,HRV,CZE,DNK,EST,FRO,FIN,FRA,GIB,GRC,VAT,HUN,ISL,IRL,IM,ITA,LVA,LIE,LTU,LUX,MI,MLT,MCO,MTN,NLD,NOR,POL,PRT,MDA,ROU,RUS,SMR,SCG,SVK,SVN,ESP,SJM,SWE,CHE,MKD,UKR,GBR,BHR,EGY,IRN,IRQ,ISR,JOR,KWT,LBN,LBR,LBY,MAR,OMN,QAT,SAU,SYR,TUN,ARE,ASM,AUS,COK,FJI,PYF,GUM,HMD,KIR,FSM,NRU,NCL,NZL,NIU,NFK,MNP,PLW,PCN,WSM,SLB,TKL,TON,TUV,VUT,WLF