mtgjson / mtgjson3

MTGJSON repository for Magic Cards
http://mtgjson.com
Other
548 stars 102 forks source link

compareRelease.js dies with Error: ENOENT: no such file or directory #484

Closed bakert closed 6 years ago

bakert commented 6 years ago
$ node util/compareRelease.js allsets notDDT notIMA

----8<---- snip tons of output of what has changed for many sets ----8<----

10E-x

["10E","2ED","3ED","4ED","5DN","5ED","6ED","7ED","8ED","9ED","AER","AKH","ALA","ALL","APC","ARB","ARC","ARN","ATH","ATQ","AVR","BFZ","BNG","BOK","BRB","BTD","C13","C14","C15","C16","C17","CED","CEI","CHK","CHR","CM1","CMA","CMD","CN2","CNS","CON","CP1","CP2","CP3","CSP","CST","DD2","DD3_DVD","DD3_EVG","DD3_GVL","DD3_JVC","DDC","DDD","DDE","DDF","DDG","DDH","DDI","DDJ","DDK","DDL","DDM","DDN","DDO","DDP","DDQ","DDR","DDS","DGM","DIS","DKA","DKM","DPA","DRB","DRK","DST","DTK","E01","EMA","EMN","EVE","EVG","EXO","EXP","FEM","FRF","FRF_UGIN","FUT","GPT","GTC","H09","HML","HOP","HOU","ICE","INV","ISD","ITP","JOU","JUD","KLD","KTK","LEA","LEB","LEG","LGN","LRW","M10","M11","M12","M13","M14","M15","MBS","MD1","ME2","ME3","ME4","MED","MGB","MIR","MM2","MM3","MMA","MMQ","MOR","MPS","MPS_AKH","MRD","NMS","NPH","ODY","OGW","ONS","ORI","PC2","PCA","PCY","PD2","PD3","PLC","PLS","PO2","POR","PTK","RAV","ROE","RQS","RTR","S00","S99","SCG","SHM","SOI","SOK","SOM","STH","THS","TMP","TOR","TPR","TSB","TSP","UDS","UGL","ULG","UNH","USG","V09","V10","V11","V12","V13","V14","V15","V16","VAN","VIS","VMA","W16","W17","WTH","WWK","XLN","ZEN","p15A","p2HG","pALP","pARL","pCEL","pCMP","pDRC","pELP","pFNM","pGPX","pGRU","pGTW","pHHO","pJGP","pLGM","pLPA","pMEI","pMGD","pMPR","pPOD","pPRE","pPRO","pREL","pSUM","pSUS","pWCQ","pWOR","pWOS","pWPN"]

Error: ENOENT: no such file or directory, open '/Users/bakert/mtgjson/json/10E-x.json'

It would be awesome to get a better error message here or a stack trace.

I have built 10E. I haven't touched 10E-x. If I try to build it I get:

[deepthought mtgjson] node build/buildSet.js 10E-x
Doing sets: 10E-x
Set 10E-x not found!

There is a 10E-x.json in public/json/10E-x.json. My output is in json/ not there, though.

I previously made this change to compareRelease.js to get it to run:

[deepthought mtgjson] git diff `fn compare*`
diff --git a/util/compareRelease.js b/util/compareRelease.js
index dc94585b..59768520 100644
--- a/util/compareRelease.js
+++ b/util/compareRelease.js
@@ -56,7 +56,7 @@ function processSet(code, cb)
                function getJSON()
                {
                        httpUtil.get("http://mtgjson.com/json/" + code + ".json", this.parallel());
-                       fs.readFile(path.join(__dirname, "..", "web", "json", code + ".json"), {encoding : "utf8"}, this.parallel());
+                       fs.readFile(path.join(__dirname, "..", "json", code + ".json"), {encoding : "utf8"}, this.parallel());
                },
                function compare(oldJSONArgs, newJSON)
                {

but that doesn't seem implicated.

bakert commented 6 years ago

changedSets.json is ["10E","2ED","3ED","4ED","5DN","5ED","6ED","7ED","8ED","9ED","AER","AKH","ALA","ALL","APC","ARB","ARC","ARN","ATH","ATQ","AVR","BFZ","BNG","BOK","BRB","BTD","C13","C14","C15","C16","C17","CED","CEI","CHK","CHR","CM1","CMA","CMD","CN2","CNS","CON","CP1","CP2","CP3","CSP","CST","DD2","DD3_DVD","DD3_EVG","DD3_GVL","DD3_JVC","DDC","DDD","DDE","DDF","DDG","DDH","DDI","DDJ","DDK","DDL","DDM","DDN","DDO","DDP","DDQ","DDR","DDS","DGM","DIS","DKA","DKM","DPA","DRB","DRK","DST","DTK","E01","EMA","EMN","EVE","EVG","EXO","EXP","FEM","FRF","FRF_UGIN","FUT","GPT","GTC","H09","HML","HOP","HOU","ICE","INV","ISD","ITP","JOU","JUD","KLD","KTK","LEA","LEB","LEG","LGN","LRW","M10","M11","M12","M13","M14","M15","MBS","MD1","ME2","ME3","ME4","MED","MGB","MIR","MM2","MM3","MMA","MMQ","MOR","MPS","MPS_AKH","MRD","NMS","NPH","ODY","OGW","ONS","ORI","PC2","PCA","PCY","PD2","PD3","PLC","PLS","PO2","POR","PTK","RAV","ROE","RQS","RTR","S00","S99","SCG","SHM","SOI","SOK","SOM","STH","THS","TMP","TOR","TPR","TSB","TSP","UDS","UGL","ULG","UNH","USG","V09","V10","V11","V12","V13","V14","V15","V16","VAN","VIS","VMA","W16","W17","WTH","WWK","XLN","ZEN","p15A","p2HG","pALP","pARL","pCEL","pCMP","pDRC","pELP","pFNM","pGPX","pGRU","pGTW","pHHO","pJGP","pLGM","pLPA","pMEI","pMGD","pMPR","pPOD","pPRE","pPRO","pREL","pSUM","pSUS","pWCQ","pWOR","pWOS","pWPN"]

So I guess it completed?

ZeldaZach commented 6 years ago

Not too relevant for V4, and I never actually knew this was a thing haha