Skip to content

Commit 7894d9f

Browse files
Merge branch 'next-staging' into next
2 parents cc83452 + 56b309f commit 7894d9f

File tree

4 files changed

+35
-5
lines changed

4 files changed

+35
-5
lines changed

.github/ISSUE_TEMPLATE/bug_report.md

+15-4
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,18 @@
11
---
22
name: Bug report
33
about: Create a report to help us improve
4-
title: "[BUG]"
4+
title: '[BUG]'
55
labels: ''
66
assignees: jakobrosenberg
7+
---
8+
9+
**IMPORTANT**
10+
11+
If possible, please consider creating the issue from within Pymakr. This will create a new issue template with relevant context information.
12+
13+
To do so, click the device's context menu (`...`) -> `Debug` -> `Show Device Summary` -> `Create an issue on Github`
14+
15+
If you prefer to use this form instead, you can delete the IMPORTANT section.
716

817
---
918

@@ -12,6 +21,7 @@ A clear and concise description of what the bug is.
1221

1322
**To Reproduce**
1423
Steps to reproduce the behavior:
24+
1525
1. Go to '...'
1626
2. Click on '....'
1727
3. Scroll down to '....'
@@ -24,9 +34,10 @@ A clear and concise description of what you expected to happen.
2434
If applicable, add screenshots to help explain your problem.
2535

2636
**Desktop (please complete the following information):**
27-
- OS: [e.g. Win 11 X64]
28-
- Device [e.g. Expansionboard v3.1]
29-
- Pymakr [e.g. v2.12.3]
37+
38+
- OS: [e.g. Win 11 X64]
39+
- Device [e.g. Expansionboard v3.1]
40+
- Pymakr [e.g. v2.12.3]
3041

3142
**Additional context**
3243
Add any other context about the problem here.

FAQ.md

+8
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,14 @@ There are a few ways to recover an unresponsive device.
2626

2727
Node shouldn't be required, but there have been reports of issues being solved after installing Node.
2828

29+
### What is Pymakr - Preview
30+
31+
Pymakr Preview is the prerelease branch of Pymakr. Features and bugfixes that pass integration tests, but could require further feedback, are released to Pymakr Preview first. If there are no issues or proposals, Pymakr Preview will then be merged into Pymakr.
32+
33+
### Can I change my version of Pymakr
34+
35+
Yes, to install a specific version, go to the extensions tab, click the cogwheel next to `Pymakr` and select `Install Another Version`.
36+
2937
### I have an issue that's not described here
3038

3139
Please open an issue on our [Github repo](https://github.com/pycom/pymakr-vsc). We usually respond within 24 hours.

src/providers/TextDocumentProvider.js

+11
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ const vscode = require("vscode");
33
const { timestamp } = require("../utils/createLogger");
44
const { arraysToMarkdownTable, adapterHistoryTable } = require("../utils/formatters");
55
const { serializeKeyValuePairs } = require("../utils/misc");
6+
const os = require("os");
67

78
/**
89
* @typedef {Object} subProvider
@@ -55,12 +56,22 @@ class TextDocumentProvider {
5556
const configTable = arraysToMarkdownTable([["Config", ""], ...Object.entries(config || {})]);
5657
const deviceTable = arraysToMarkdownTable([["Device", ""], ...Object.entries(device.raw || {})]);
5758
const systemTable = arraysToMarkdownTable([["System", ""], ...Object.entries(device.info || {})]);
59+
const hostTable = arraysToMarkdownTable([
60+
["Host", ""],
61+
...Object.entries({
62+
OS: process.platform + " - " + os.arch(),
63+
Pymakr: vscode.extensions.getExtension("Pycom.pymakr")?.packageJSON.version,
64+
"Pymakr-Preview": vscode.extensions.getExtension("Pycom.pymakr-preview")?.packageJSON.version,
65+
VSCode: vscode.version,
66+
}),
67+
]);
5868

5969
const historyTable = arraysToMarkdownTable(adapterHistoryTable(device));
6070
const body = [
6171
configTable,
6272
deviceTable,
6373
systemTable,
74+
hostTable,
6475
`## Device History at ${timestamp(new Date())}`,
6576
historyTable,
6677
].join("\r\n\r\n");

src/utils/formatters.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
const { timestamp } = require("./createLogger");
1111

1212
const sanitize = (str) =>
13-
(typeof str === "string" ? str : JSON.stringify(str, null, 2))
13+
(typeof str === "string" ? str : typeof str === "undefined" ? "undefined" : JSON.stringify(str, null, 2))
1414
.replace(/\|/gm, "|")
1515
.replace(/\r?\n/gm, "<br />")
1616
.replace(/"username": ".+?"/, '"username": "&#42;&#42;&#42;"')

0 commit comments

Comments
 (0)