You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: data_importer_service.rb
    path of file: ./repos/wreeto_official/app/services
    
    the code of the file until where you have to start completion: class DataImporterService
  require 'open3'
  
  attr_reader :fullpath

  def initialize(user, zip_file)
    @user = user
    @zip_file = zip_file
  end

  def run
    create_dir
    import_zip
    validate!
    persist_data
  rescue => e
    raise StandardError, "#{e.message}"
  end

  def zip_path
    "#{@fullpath}/#{zip_filename}"
  end

  private

  def categories
    @categories ||= @user.categories
  end

  def notes
    @notes ||= @user.notes
  end

  def create_dir
    securehash = SecureRandom.hex(4)
    @fullpath = "/tmp/wreeto_import_#{securehash}"
    Dir.mkdir @fullpath
  end
    
  def validate! 
    Dir.chdir @fullpath do 
      dir_names = find_directories
      dir_names.each do |dir| 
        category = find_or_create_category(dir)
        Dir.chdir dir do 
          filenames = find_files
          filenames.each do |filename|
            title = Pathname(filename).sub_ext('').to_s.humanize
            raise StandardError, "#{filename} is not a text file" if File.file?(filename) && is_not_a_note?("#{@fullpath}/#{dir}/#{filename}")
          end
          subdir_names = find_directories
          subdir_names.each do |subdir| 
            Dir.chdir subdir do 
              subcategory = categories.find_by(title: subdir.humanize)
              subcategory = @categories.create!(title: subdir.humanize, parent: category) if subcategory.nil?
              sub_filenames = find_files
              sub_filenames.each do |sub_filename|
                title = Pathname(sub_filename).sub_ext('').to_s.humanize
                raise StandardError, "#{sub_filename} is not a text file" if File.file?(sub_filename) && is_not_a_note?("#{@fullpath}/#{dir}/#{subdir}/#{sub_filename}")
              end
            end
          end
        end
      end
    end
    true
  end