Uploading your own files

Start a project from files you already have, or add files, a folder or an archive to an existing one.

Upload existing code when you create a project, or add it to a project you already have. Both take single files, a whole folder, or one archive.

Start a project from your files

Click New Project, and under Project shape choose Upload your own files. Drag files, a folder or an archive onto the card, or pick them with Files… or Folder…. Once the files are read, the card shows the file count, the total size, and whether the project will run as Python or as JS. Then click Create.

When you create a project from an upload:

  • Your files decide the runtime. A top-level index.html and main.js make a JS project. Otherwise, a top-level main.py makes a Python project. The runtime environment explains the rule. If the upload has neither, the card warns you. You can still create the project and add an entry point later.
  • README.md becomes the write-up. A top-level README.md is not stored as a file. It becomes the project's write-up, the text on the Project Card. It can be up to 65,000 characters. A longer one is refused before anything is created.
  • requirements.txt is added if it is missing. Without one, the project gets the same single Qiskit line a new Python project starts with. Add your own packages to it later. See Libraries.
  • An archive is unpacked. If you upload a single archive, the project is built from the files inside it.

Add files to an existing project

In edit mode, switch the Code tab to the file tree view. The upload area sits at the bottom of the file list. Drop files, a folder or an archive onto it, or click Browse and choose Files… or Folder….

  • Qollab asks before it unpacks an archive. For a single archive, you choose Unpack or Upload as a file.
  • If the project already has files, Qollab asks what to keep. Keep and add leaves the existing files in place. An uploaded file replaces an existing file at the same path, and the dialog lists which ones. Erase first deletes every file in the current version, then uploads. Erasing cannot be undone, so Qollab asks you to confirm.
  • README.md is skipped here. The write-up already has its own row in the file list. Open that row, or the Project Card, and paste the text there.

What gets uploaded

  • Archives: .zip, .tar, .tar.gz (or .tgz), .tar.bz2 (or .tbz2) and .tar.xz (or .txz). They are unpacked in your browser.
  • A single wrapping folder is removed. When everything sits inside one top-level folder, as in a my-project-main/ zip from GitHub, the files land at the top of the project. That puts main.py where the runtime looks for it.
  • Clutter is left out: .git folders, __MACOSX folders, .DS_Store, Thumbs.db, and files whose names start with ._.

Limits

A project holds up to 100 files of up to 2 MB each, and all your projects together can use 200 MB. An upload that would go over any of these is refused as a whole, before anything is written, and the message says what went over. The same goes for paths the project cannot use: a path that is too long, or one where a file and a folder would share a name.

A dataset larger than 2 MB cannot be a project file. Larger datasets explains how to read one from the web instead.

Stay in the loop.

Get the latest tutorials, demos, and project showcases straight to your inbox. No noise, just the good stuff.