Win a copy of TDD for a Shopping Website LiveProject this week in the Testing forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

Warning: SomeClassName.java modified in the future. -- what's this error?

 
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I'm getting an error "Warning: SomeClassName.java modified in the future".

Not every file is giving me this error, only certain files do. I can't figure out what's wrong with them, there's nothing weird or extraordinary in those files that produce this error though.

Any idea what is it?

Thank you for your help.
 
Marshal
Posts: 75644
354
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sounds like a warning from the OS; you have got timekeeping problems and the last modified time on some of your files is shown as being later than "now."

I don't think that is a specific Java problem, but an operating system problem.
 
Ls chin
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Campbell,

Thanks for your reply. I think it's an OS problem too because this afternoon I downloaded a stopwatch applet and after that NetBeans have been giving me this error.

I feel better, now that I know my java files are okay!

Thanks again. :-)
 
Bartender
Posts: 2856
10
Firefox Browser Fedora Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am familiar with that warning in Netbeans.
It is usually displayed when you execute code without recompiling.
 
Ranch Hand
Posts: 40
Eclipse IDE Tomcat Server Java
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Ls chin wrote:Hi,

I'm getting an error "Warning: SomeClassName.java modified in the future".

Not every file is giving me this error, only certain files do. I can't figure out what's wrong with them, there's nothing weird or extraordinary in those files that produce this error though.

Any idea what is it?

Thank you for your help.




This is because, The time of the system is not current on which you are running the build file. There are some classes in directories that get modified later the date your system is showing currently.....your system time is not up to date...or you modified the file with future date....check your system time when you are running the build file...

Regards
Yogesh Tyagi
 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

This is because, The time of the system is not current on which you are running the build file. There are some classes in directories that get modified later the date your system is showing currently.....your system time is not up to date...or you modified the file with future date....check your system time when you are running the build file..





True because this error occurred when i made today yesterday !!
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I got that same "modified in the future" warning because my clock on my old motherboard is unstable and keeps getting the date and time wrong.
NetBeans warns of this when it sees the date/times on files don't make sense.
 
Sheriff
Posts: 22645
124
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You may want to replace the little battery on your motherboard. That often solves BIOS time issues.
 
Saloon Keeper
Posts: 13848
312
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It's still weird that the compiler does this. Is there a good reason for it?
 
Campbell Ritchie
Marshal
Posts: 75644
354
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
And welcome to the Ranch
 
"To do good, you actually have to do something." -- Yvon Chouinard
free, earth-friendly heat - a kickstarter for putting coin in your pocket while saving the earth
https://coderanch.com/t/751654/free-earth-friendly-heat-kickstarter
reply
    Bookmark Topic Watch Topic
  • New Topic