Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
silkaj
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
clients
python
silkaj
Commits
00168a79
Commit
00168a79
authored
6 years ago
by
Moul
Committed by
Mael
6 years ago
Browse files
Options
Downloads
Patches
Plain Diff
[mod]
#184
: use `for i in enumerate()`.
parent
652eb059
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
silkaj/money.py
+1
-3
1 addition, 3 deletions
silkaj/money.py
with
1 addition
and
3 deletions
silkaj/money.py
+
1
−
3
View file @
00168a79
...
...
@@ -153,13 +153,12 @@ async def get_sources(pubkey):
last_block_number
=
head_block
[
"
number
"
]
# add pending output
for
pending
in
pendings
:
for
i
,
pending
in
enumerate
(
pendings
)
:
blockstamp
=
pending
[
"
blockstamp
"
]
block_number
=
int
(
blockstamp
.
split
(
"
-
"
)[
0
])
# if it's not an old transaction (bug in mirror node)
if
block_number
>=
last_block_number
-
3
:
identifier
=
pending
[
"
hash
"
]
i
=
0
for
output
in
pending
[
"
outputs
"
]:
outputsplited
=
output
.
split
(
"
:
"
)
if
outputsplited
[
2
]
==
"
SIG(
"
+
pubkey
+
"
)
"
:
...
...
@@ -172,7 +171,6 @@ async def get_sources(pubkey):
)
if
inputgenerated
not
in
listinput
:
listinput
.
append
(
inputgenerated
)
i
+=
1
# remove input already used
for
pending
in
pendings
:
...
...
This diff is collapsed.
Click to expand it.
Moul
@moul
mentioned in issue
#239 (closed)
·
5 years ago
mentioned in issue
#239 (closed)
mentioned in issue #239
Toggle commit list
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment