1

guys:

I am using eclipse version of 2018-12. My project has a lot of JSON files in test resources folder which have duplicate key problem. Can I set up eclipse to enforce eclipse to ignore these errors?

I tried as said in the following link, but it did not work: eclipse neon - ignore json error

I understand that JSON does not permit duplicate key, but this is the project test resource that I am NOT allowed to change, and eclipse marked too many errors, which distracted me from real bugs.

Thank you in advance.

lxiscas
  • 141
  • 1
  • 2
  • 13
  • are you allowed to create a copy of the test file and edit the copy ? – jonathan Heindl Apr 25 '19 at 21:16
  • also tell whoever tell you youre not allowed that this file is too big and not a practical way to do testing – jonathan Heindl Apr 25 '19 at 21:17
  • These JSON files are used for team to test. Obviously I better not to do anything about it, nor is it efficient to change so many JSON files. If I delete them, my Junit tests may fail. It exceeds my working permit – lxiscas Apr 25 '19 at 21:22
  • just on a sidenote : how are you gonna work with a json that has duplicate keys ? – jonathan Heindl Apr 25 '19 at 21:34
  • I noticed that these JSON have complete duplicate rows for some reason. if I had not changed my eclipse version I wold never noticed it. These JSON files belong to some Junit test which I did not touch them before. I noticed that in old version of eclipse the error showed in the JSON file, but eclipse did not mark the whole project error in the project explorer. That is what I want. – lxiscas Apr 25 '19 at 21:39
  • oh thats a bit different you can exclude files from the compiling process – jonathan Heindl Apr 25 '19 at 21:40
  • are you using the Problems view from eclipse ? – jonathan Heindl Apr 25 '19 at 21:49
  • bacause for that you can set up filters : In the problem view there is a little arrow pointing downwards in the top right corner if you click on it you cna set up filters to your liking in the correesponing dropdown item you can create new confiuration and tick for example the On selected elements and its children scope then add in the select button edit the folder to include everything except that file ( – jonathan Heindl Apr 25 '19 at 21:55

0 Answers0