Comments (10)
Well for starters none of the code isn't really meant to be hosted in any bot besides the main one. Anyways this is probably happening because you didn't pass correct arguments to the command.
from bobdotbot.
well first of all it seems that the number you are providing on the f string is None
and the query is attempting to add another column which already exists
from bobdotbot.
Well for starters none of the code isn't really meant to be hosted in any bot besides the main one. Anyways this is probably happening because you didn't pass correct arguments to the command.
actually the argument is filled but the database result is null
which explains why the column name is itemNone
and it seems they are hosting on the bot itself they just mean selfhost which means hosting locally
from bobdotbot.
So, I am passing in the wrong arguments?
from bobdotbot.
So, I am passing in the wrong arguments?
no you did not but the database query returned None
in rows[-1][0]
thats the issue
the rows itself is not empty but the index [-1][0]
returned None
from bobdotbot.
That means rows[-1][0] doesn't exist. But how is that possible?
from bobdotbot.
That means rows[-1][0] doesn't exist. But how is that possible?
its possible because the column value can be null
from bobdotbot.
Right, so in aiosqlite when you do rows = await cursor.fetchall() isn't the first index (i.e. [-1]) the last from the right. Which is the latest. In that the first index would be the ID of the item. Is this a bug with aiosqlite? Or are the indexes wrong?
from bobdotbot.
Right, so in aiosqlite when you do rows = await cursor.fetchall() isn't the first index (i.e. [-1]) the last from the right. Which is the latest. In that the first index would be the ID of the item. Is this a bug with aiosqlite? Or are the indexes wrong?
as i said the column value is null
try and print rows before indexing them
rows = await cursor.fetchall()
print(rows)
numbers = rows[-1][0]
from bobdotbot.
k I fixed this, thanks @ReyterYT
from bobdotbot.
Related Issues (11)
- Code fix HOT 1
- Reddit command HOT 1
- use f strings. HOT 24
- Give command when? HOT 7
- Default embed
- ;emoji; emoji list
- Music HOT 1
- Music
- Blocking stuff HOT 3
- Public repo
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bobdotbot.