Skip to content

Commit

Permalink
added domains
Browse files Browse the repository at this point in the history
  • Loading branch information
dmalan committed Dec 21, 2023
1 parent 7fda5a6 commit 123218b
Showing 1 changed file with 20 additions and 5 deletions.
25 changes: 20 additions & 5 deletions cs50.dev.md
Expand Up @@ -125,17 +125,32 @@ When you log into Visual Studio Code for CS50, your codespace is configured with

If you try to access a repository that's owned by an [organization](https://docs.github.com/en/organizations/collaborating-with-groups-in-organizations/about-organizations) that has not granted access to Visual Studio Code for CS50, though, `git` might err with "Repository not found." (And `gh` might err with "Could not resolve to a Repository.") To grant (or request) access for that organization, visit [github.com/settings/connections/applications/d1a90a524497a69391fa](https://github.com/settings/connections/applications/d1a90a524497a69391fa). Alternatively, you can configure your codespace to use [SSH](/github/#ssh) or a [personal access token](/github/#personal-access-token) instead, both of which would have access to any repositories to which your GitHub account has access, whether or not owned by an organization.

## FAQs
## Domains

### How to Monitor Global Variables in Debug Session
Visual Studio Code for CS50 is built atop [GitHub Codespaces](https://github.com/features/codespaces), which requires that you can access these domains:

In debug50's `RUN AND DEBUG` pane, there's a section labeled `WATCH`. You can add expressions to this section, and the debugger will show you the values of these expressions as you step through the program. The expressions can include global variables and array names.
* `*.github.com`
* `*.api.github.com`
* `*.azureedge.net`
* `*.github.dev`
* `*.msecnd.net`
* `*.visualstudio.com`
* `*.vscode-webview.net`
* `*.windows.net`

Take `plurality` problem set for example. If the arrow to the left of the `WATCH` heading is pointing to the right `>`, click it to expand the section. Then click the plus sign in the section heading to insert a new expression to be watched.
If on a corporate or school network that blocks any of the above, you might need to ask your IT department if they can "allowlist" all of the above.

## Troubleshooting

### How to monitor global variables in debugger

In debug50's **RUN AND DEBUG** pane, there's a section labeled **WATCH**. You can add expressions to this section, and the debugger will show you the values of these expressions as you step through the program. The expressions can include global variables and array names.

Consider the `plurality` problem, for example. If the arrow to the left of the **WATCH** heading is pointing to the right **>**, click it to expand the section. Then click the plus sign in the section heading to insert a new expression to be watched.

For example, you could type this: `candidates[0]@candidate_count`. Though this is not a legal expression in C, the `@` operator is specially treated by the debugger. This particular watch expression means `display candidate_count elements of the candidates array, starting with the first (i.e., the element at index 0)`.

When the debugger stops at a breakpoint, it will show you the value of the expressions it's watching. In this example, the array elements are structs, so you may need to expand them using their individual `>` buttons.
When the debugger stops at a breakpoint, it will show you the value of the expressions it's watching. In this example, the array elements are structs, so you may need to expand them using their individual **>** buttons.

### I can't type anything in the terminal

Expand Down

0 comments on commit 123218b

Please sign in to comment.