Lỗi unable to find an ant file to run năm 2024

Leandro de Oliveira 2008-06-27 15:30:28 EDT

Build ID: I20080617-2000 Steps To Reproduce:

  1. Open a Java Class File on Java Editor;
  2. Create a simple Ant Build file on root of the current Java Project;
  3. Rebind Run Ant Build to Ctrl + F10;
  4. Unbind "Show Ruler Context Menu" and "Show View Menu" on Preferences -> General -> Keys;
  5. Type Ctrl + F10 on Java Source Code Editor;
  6. The message "Unable to find an Ant file to run" will popup. More information: Eclipse 3.3 can find the ant file Eclipse 3.4 cant.

Jerome Lanneluc 2008-07-02 07:57:48 EDT

Moving to Platform/Ant

Leandro de Oliveira 2008-07-24 14:23:24 EDT

Is there anyone working on this issue?

Remy Suen 2008-07-24 14:32:34 EDT

I can reproduce this on Linux/gtk+ with I20080716-1200. I don't have a 3.3.x build at the moment to test whether it's a regression or not though.

Bob Miller 2009-01-16 14:07:14 EST

I am running 3.3 and 3.4 side by side. I used the default binding (alt+shift+x, q). It works perfectly in 3.3 and does not work in 3.4.

Darin Wright 2009-01-16 16:56:30 EST

It looks like "Run Ant Build" will "find" a build.xml file when launched from a selection (e.g. a file in the navigator), but not when launched from the editor.

Darin Wright 2009-01-20 12:06:28 EST

Fixed in HEAD.

Darin Wright 2009-01-20 12:07:52 EST

Requesting PMC approval to fix in 3.4.2 since this is a regression from 3.3

Darin Wright 2009-01-20 13:56:56 EST

Released to 3.4.2

Darin Wright 2009-01-20 13:57:23 EST

Please verify, Mike (R).

Michael Rennie 2009-02-02 12:10:02 EST

Moving to Platform/Ant

0

Jörg von Frantzius 2006-04-02 12:03:27 EDT

[Eclipse 3.2 M6] This is [Bug

128552](https://bugs.eclipse.org/bugs/show%5Fbug.cgi?id=128552), but I can't find a way of reopening it.

When I select an target in the Ant Outline View and chose "Run As.." - "Ant Build", all I get is a dialog saying "Unable to find ant file to run". The file includes other ant files, and the problem happens both with targets defined in the file itself and targets defined in one of the included files. There are no related errors in the Error Log.

Darin Swanson 2006-04-02 13:18:30 EDT

So I still need to find out what is different about your setup or the Ant buildfile as I cannot reproduce the problem. This is for all Ant buildfiles in all projects or locations or just one particular buildfile?

Jörg von Frantzius 2006-04-03 09:18:41 EDT

It does work for some build files, e.g. Eclipse-generated ones. Please see [bug

134497](https://bugs.eclipse.org/bugs/show%5Fbug.cgi?id=134497) for an example build.xml where no target can be invoked from the Ant Outline View.

Darin Swanson 2006-04-03 11:26:28 EDT

Worksforme on 3.2M6: Selected the default target From the Ant view> Run As>Ant Build Build output: Buildfile: C:\Darins\workspaces\0218\Ant Testing\134497.xml [taskdef] Could not load definitions from resource clovertasks. It could not be found. default:

 [echo] ===================================================================
 [echo] Welcome to JPOX build.
 [echo] ===================================================================
[taskdef] Could not load definitions from resource clovertasks. It could not be found. BUILD FAILED C:\Darins\workspaces\0218\Ant Testing\134497.xml:101: The following error occurred while executing this line: Target `${build.setting.default.target}' does not exist in this project. Total time: 1 second

Jörg von Frantzius 2006-04-03 13:13:53 EDT

When I use a fresh workspace with only that project imported, it works for me as well.

Etienne Lacombe 2006-04-05 12:28:37 EDT

I get this same error. For me, it is only some Ant files that won't run - two out of 5 right now. These are all manually written ant files dating of before I started using Eclipse. All works through command line. On one project where this happen, I tried creating a new ant file using the eclipse -> export to ant feature. Even that eclipse generated ant file would not run. None of those ant files include other files. I tried yesterday using 3.2M6 but this is still an issue.

Etienne Lacombe 2006-04-05 12:30:24 EDT

Additional note: I can run the file through the external tools but not from the Ant View.

Jörg von Frantzius 2006-04-05 12:35:05 EDT

(In reply to [comment

6](https://bugs.eclipse.org/bugs/show%5Fbug.cgi?id=134416

c6))
Additional note: I can run the file through the external tools but not from the

Ant View. Did you try using a fresh workspace? That made it work again for me.

Etienne Lacombe 2006-04-07 15:05:33 EDT

It works with a fresh workspace... This should be fixed so it does not corrupt! It's a bit anoying to have to resetup your workspace. Otherwise, I can now use the Ant view again. Thanks. (In reply to [comment

7](https://bugs.eclipse.org/bugs/show%5Fbug.cgi?id=134416

c7))
(In reply to [comment

6](https://bugs.eclipse.org/bugs/show%5Fbug.cgi?id=134416

c6))
Additional note: I can run the file through the external tools but not from the

Ant View.

Did you try using a fresh workspace? That made it work again for me.

Darin Swanson 2006-04-07 15:25:27 EDT

I would love to fix this problem but I have not been able to reproduce and I do not have a technical reason for the failure to investigate.

Ben Tatham 2006-05-16 10:56:01 EDT

So I still need to find out what is different about your setup or the Ant buildfile as I cannot reproduce the problem. This is for all Ant buildfiles in all projects or locations or just one particular buildfile?

0

Jörg von Frantzius 2006-06-01 10:56:17 EDT

So I still need to find out what is different about your setup or the Ant buildfile as I cannot reproduce the problem. This is for all Ant buildfiles in all projects or locations or just one particular buildfile?

1

Richard Cook 2006-08-02 17:20:29 EDT

So I still need to find out what is different about your setup or the Ant buildfile as I cannot reproduce the problem. This is for all Ant buildfiles in all projects or locations or just one particular buildfile?

2

So I still need to find out what is different about your setup or the Ant buildfile as I cannot reproduce the problem. This is for all Ant buildfiles in all projects or locations or just one particular buildfile?

3

So I still need to find out what is different about your setup or the Ant buildfile as I cannot reproduce the problem. This is for all Ant buildfiles in all projects or locations or just one particular buildfile?

4

cedric wider 2006-08-28 02:54:51 EDT

So I still need to find out what is different about your setup or the Ant buildfile as I cannot reproduce the problem. This is for all Ant buildfiles in all projects or locations or just one particular buildfile?

5

So I still need to find out what is different about your setup or the Ant buildfile as I cannot reproduce the problem. This is for all Ant buildfiles in all projects or locations or just one particular buildfile?

6

So I still need to find out what is different about your setup or the Ant buildfile as I cannot reproduce the problem. This is for all Ant buildfiles in all projects or locations or just one particular buildfile?

7

Mark Cowley 2006-12-19 10:21:09 EST

So I still need to find out what is different about your setup or the Ant buildfile as I cannot reproduce the problem. This is for all Ant buildfiles in all projects or locations or just one particular buildfile?

8

Jean-Marie White 2007-01-13 23:47:56 EST

So I still need to find out what is different about your setup or the Ant buildfile as I cannot reproduce the problem. This is for all Ant buildfiles in all projects or locations or just one particular buildfile?

9

Szanto Peter 2007-04-20 10:24:44 EDT

It does work for some build files, e.g. Eclipse-generated ones. Please see [bug

134497](https://bugs.eclipse.org/bugs/show%5Fbug.cgi?id=134497) for an example build.xml where no target can be invoked from the Ant Outline View.

0

Mark Cowley 2007-04-20 11:45:32 EDT

It does work for some build files, e.g. Eclipse-generated ones. Please see [bug

134497](https://bugs.eclipse.org/bugs/show%5Fbug.cgi?id=134497) for an example build.xml where no target can be invoked from the Ant Outline View.

1

It does work for some build files, e.g. Eclipse-generated ones. Please see [bug

134497](https://bugs.eclipse.org/bugs/show%5Fbug.cgi?id=134497) for an example build.xml where no target can be invoked from the Ant Outline View.

2

Stephen Solka 2007-05-04 11:48:22 EDT

It does work for some build files, e.g. Eclipse-generated ones. Please see [bug

134497](https://bugs.eclipse.org/bugs/show%5Fbug.cgi?id=134497) for an example build.xml where no target can be invoked from the Ant Outline View.

3

Barry Ku 2007-06-11 20:55:24 EDT

It does work for some build files, e.g. Eclipse-generated ones. Please see [bug

134497](https://bugs.eclipse.org/bugs/show%5Fbug.cgi?id=134497) for an example build.xml where no target can be invoked from the Ant Outline View.

4

Lars Vogel 2019-11-14 03:31:22 EST

It does work for some build files, e.g. Eclipse-generated ones. Please see [bug

134497](https://bugs.eclipse.org/bugs/show%5Fbug.cgi?id=134497) for an example build.xml where no target can be invoked from the Ant Outline View.

5