Skip to content

Commit 17a4f49

Browse files
fix: first mile code snippet revisions for write data and execute query page (#4232)
1 parent bbab3bb commit 17a4f49

File tree

4 files changed

+6
-28
lines changed

4 files changed

+6
-28
lines changed

src/homepageExperience/components/steps/ExecuteAggregateQuery.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export const ExecuteAggregateQuery = (props: ExecuteAggregateQueryProps) => {
2828

2929
const codeSnippet = `query_api = client.query_api()
3030
31-
query = "from(bucket: \\"${bucket}\\") |> range(start: -10m) |> filter(fn: (r) => r._measurement == "measurement1") |> mean()"
31+
query = 'from(bucket: "${bucket}") |> range(start: -10m) |> filter(fn: (r) => r._measurement == "measurement1") |> mean()'
3232
tables = query_api.query(query, org="${org.name}")
3333
3434
for table in tables:

src/homepageExperience/components/steps/ExecuteQuery.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,12 @@ export const ExecuteQuery = (props: ExecuteQueryProps) => {
2020
const {bucket} = props
2121
const query = `query_api = client.query_api()
2222
23-
query = "from(bucket: \\"${bucket}\\") |> range(start: -10m) |> filter(fn: (r) => r._measurement == "measurement1")"
23+
query = 'from(bucket: "${bucket}") |> range(start: -10m) |> filter(fn: (r) => r._measurement == "measurement1")'
2424
tables = query_api.query(query, org="${org.name}")
2525
2626
for table in tables:
27-
for record in table.records:
28-
print(record)`
27+
for record in table.records:
28+
print(record)`
2929

3030
return (
3131
<>

src/homepageExperience/components/steps/Overview.tsx

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
11
import React, {PureComponent} from 'react'
2-
import {event} from 'src/cloud/utils/reporting'
32

43
export class Overview extends PureComponent {
5-
private logDocsOpened = () => {
6-
event('firstMile.pythonWizard.overview.docs.opened')
7-
}
84
render() {
95
return (
106
<div>
@@ -17,25 +13,7 @@ export class Overview extends PureComponent {
1713
and write and execute some basic queries.
1814
</p>
1915

20-
<p>
21-
If you ever stray away from this set up process, worry not! You can
22-
always refer to the “Help & Support” item in the side navigation
23-
menu to return here.
24-
</p>
25-
2616
<p>Without further ado, let’s get started.</p>
27-
28-
<p style={{marginTop: '150px'}}>
29-
Want to just look at code? Check out the code snippets involved in
30-
this guide on{' '}
31-
<a
32-
href="https://github.com/influxdata/ui"
33-
onClick={this.logDocsOpened}
34-
>
35-
Github
36-
</a>
37-
.
38-
</p>
3917
</article>
4018
</div>
4119
)

src/homepageExperience/components/steps/WriteData.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@ for value in range(5):
6161
.tag("tagname1", "tagvalue1")
6262
.field("field1", value)
6363
)
64-
write_api.write(bucket=bucket, org="${org.name}", record=point)
65-
time.sleep(1) # separate points by 1 second`
64+
write_api.write(bucket=bucket, org="${org.name}", record=point)
65+
time.sleep(1) # separate points by 1 second`
6666

6767
return (
6868
<>

0 commit comments

Comments
 (0)