Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Project files deleted when running program in Qt Creator
QtWS25 Last Chance

Project files deleted when running program in Qt Creator

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
9 Posts 3 Posters 2.1k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    SAslund
    wrote on last edited by
    #1

    Hello everyone

    I have a very strange problem. I do not seem to find anyone who has a similar problem.
    For a year now I have developed a program and Qt Creator + Qt has always worked nicely.

    Recently I started to get a problem. Periodically when running my program in Qt Creator all my project files has been deleted. Only the program's exe file remains. I am puzzled as I have nothing in the program that warrents this behaviour. I can only imagine that it is Qt Creator that is doing something but no one else seems to experience this problem.

    I recently upgraded from Qt Creator 4.5.2 to 4.6, I can not recall if the problem came after or before, but I am quite sure it was after.
    I tried to install Qt Creator 4.5.2 seperatly but it did not want to import my project properly due to missing kit setup

    I have not tried to see what happens if I run the application through terminal instead of using Qt Creator.

    Does anyone know what to do when faced with this kind of problem?

    Regards
    Sebastian

    1 Reply Last reply
    1
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by mrjj
      #2

      Hi and welcome to the forums.
      You mean files are removed from the project folder ?
      Your .cpp etc ?
      Or do you mean it removes the stuff from the build folder ?
      It does sound odd.

      Also, can you make it do the "thing" using a plain GUI default project?

      1 Reply Last reply
      0
      • S Offline
        S Offline
        SAslund
        wrote on last edited by
        #3

        Hello mrjj

        Every file is removed. My .cpp, .h, .ui files. My files under release and debug folders. My .pro and .pro.user.
        Even my mercurial .hg folder is removed.
        Everything except for my executable file, .exe

        There are a few folders that are left but their content is gone.

        jsulmJ 1 Reply Last reply
        0
        • S SAslund

          Hello mrjj

          Every file is removed. My .cpp, .h, .ui files. My files under release and debug folders. My .pro and .pro.user.
          Even my mercurial .hg folder is removed.
          Everything except for my executable file, .exe

          There are a few folders that are left but their content is gone.

          jsulmJ Offline
          jsulmJ Offline
          jsulm
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @SAslund One moment: you have source files (*.h, *.cpp) inside release/debug folders? These folders are temporary folders used for building your project. You should NOT store anything there!

          https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          1
          • S Offline
            S Offline
            SAslund
            wrote on last edited by
            #5

            Hello jsulm

            Yea. I can see how that sentence can be misunderstood. Thats what you get from answering late in the evening.

            Don't worry. My source files are stored in my src folder.
            Let me rephrase. Everything is deleted. My source files and build files. Even files that are not part of the Qt project are deleted. My mercurial .hg folder. My documentation folder with the manual. My exe folder with Qt libraries and InnoSetup script.

            It seems very strange. Reminds me of a good old rm -r from Linux.

            mrjjM 1 Reply Last reply
            0
            • S SAslund

              Hello jsulm

              Yea. I can see how that sentence can be misunderstood. Thats what you get from answering late in the evening.

              Don't worry. My source files are stored in my src folder.
              Let me rephrase. Everything is deleted. My source files and build files. Even files that are not part of the Qt project are deleted. My mercurial .hg folder. My documentation folder with the manual. My exe folder with Qt libraries and InnoSetup script.

              It seems very strange. Reminds me of a good old rm -r from Linux.

              mrjjM Offline
              mrjjM Offline
              mrjj
              Lifetime Qt Champion
              wrote on last edited by
              #6

              @SAslund
              Hi
              AS far as i know QCreator do not clean anything up by its own.

              Can you reproduce it with a NEW default GUI project ?

              I suspect you have some extra build commands that cleans.

              1 Reply Last reply
              2
              • S Offline
                S Offline
                SAslund
                wrote on last edited by
                #7

                It is a periodically problem. Monday I was using the program for testing several times without fail. Tuesday suddenly the files got deleted when running the program. Just once though.
                Yesterday I did some debugging on the program and I did not experience any issue.

                As a note. I have only experienced it when I run the program through Qt Creator. It is also my main way of running it.

                I have other projects. I must wait and see if they promt same behaviour.

                mrjjM jsulmJ 2 Replies Last reply
                0
                • S SAslund

                  It is a periodically problem. Monday I was using the program for testing several times without fail. Tuesday suddenly the files got deleted when running the program. Just once though.
                  Yesterday I did some debugging on the program and I did not experience any issue.

                  As a note. I have only experienced it when I run the program through Qt Creator. It is also my main way of running it.

                  I have other projects. I must wait and see if they promt same behaviour.

                  mrjjM Offline
                  mrjjM Offline
                  mrjj
                  Lifetime Qt Champion
                  wrote on last edited by
                  #8

                  @SAslund

                  Ok so its not reproducible with a NEW default GUI project very easy.
                  I have never seen such issue or seen post about it. I have 6 people using Creator
                  8 hours a day and not seen anything like it.
                  So very strange indeed.

                  1 Reply Last reply
                  1
                  • S SAslund

                    It is a periodically problem. Monday I was using the program for testing several times without fail. Tuesday suddenly the files got deleted when running the program. Just once though.
                    Yesterday I did some debugging on the program and I did not experience any issue.

                    As a note. I have only experienced it when I run the program through Qt Creator. It is also my main way of running it.

                    I have other projects. I must wait and see if they promt same behaviour.

                    jsulmJ Offline
                    jsulmJ Offline
                    jsulm
                    Lifetime Qt Champion
                    wrote on last edited by
                    #9

                    @SAslund Could it be your app which deletes the files?

                    https://forum.qt.io/topic/113070/qt-code-of-conduct

                    1 Reply Last reply
                    1

                    • Login

                    • Login or register to search.
                    • First post
                      Last post
                    0
                    • Categories
                    • Recent
                    • Tags
                    • Popular
                    • Users
                    • Groups
                    • Search
                    • Get Qt Extensions
                    • Unsolved