Forum Discussion

nastester's avatar
nastester
Regular Contributor
2 years ago

Handling error with TFVC client

From time to time when attempting to check in changes via the TFVC client, I get an error stating that the client could not find several files (usually .png's) and thus no files are checked in.

I'm not sure what really causes this but in order to check in I have to manually uncheck the files it mentions that it can't find and then attempt to check in again.

As you can imagine, this is quite tedious and frustrating and I must be missing something. 

Has anyone encountered this? Is there a workaround? 

  • Do you want to save the .png files or are they just getting carried along when you do the check in?  Usually there's a way to skip files of a certain type if you don't care about them.

  • rraghvani's avatar
    rraghvani
    Champion Level 3

    The same happens to me as well while using TFS. Usually, when you add new files to TestComplete, it automatically gets added to the repository. However, if a file gets deleted or renamed from TestComplete, the changes are not reflected in TFS. So when you perform a check-in, TFS is looking for files that no longer exist. 

     

    Note, that the .png files are automatically generated by TestComplete for each UI control when recording or playback, and these are something you don't want to store in the repository, as there can be thousands of pictures.

     

    The only solution to resolve this, is undo pending changes, then add the project to the repository. Or undo pending changes on NameMapping\Images folder, if you don't require the images.

    • nastester's avatar
      nastester
      Regular Contributor

      rraghvani 

      Think this is what I am looking for. There's no real reason to store the screenshots right?  Can I just exclude them from check in by default? 
      I imagine I can do a gitignore or something? 

  • rraghvani's avatar
    rraghvani
    Champion Level 3

    It can be excluded from TFS, using .tfignore file. For example,

    ######################################
    # Ignore .cpp files in the ProjA sub-folder and all its subfolders
    ProjA\*.cpp
    # Ignore .txt files in this folder 
    \*.txt
    # Ignore .xml files in this folder and all its sub-folders
    *.xml
    # Ignore all files in the Temp sub-folder
    \Temp
    # Do not ignore .dll files in this folder nor in any of its sub-folders
    !*.dll
    • nastester's avatar
      nastester
      Regular Contributor

      rraghvani 

       

      I added *.png's to my tfignore file but it seems screenshots/images are still being included in check in's.

      Am I missing something? 


      # Ignore logs
      Log\

      # Ignore local settings files
      *.tcLS
      *.tcCfgExtender

      # Ignore backup files
      *.bak

      # Ignore all screenshots
      *.png